Opened 3 years ago

Closed 3 years ago

#25851 closed enhancement (duplicate)

Add -C option and DESTDIR to make

Reported by: gh-ChukwuemezieChristopherAneke Owned by:
Priority: major Milestone: sage-duplicate/invalid/wontfix
Component: build Keywords: make, make install, DESTDIR, make -C
Cc: Merged in:
Authors: Reviewers:
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Status badges

Description (last modified by gh-ChukwuemezieChristopherAneke)

I have compiled dozens of programs but sagemaths compilation is not user friendly. It needs extra features to make compilation easier. Three suggestions i want to make are:

  1. Add -C option to make

for example:

cd ~/sage/build

make -C ~/sage/src

This allows a user to build out of tree from a dedicated build directory which they can create themselves. This way one does not have to worry about how the developers have configured make clean and make distclean which varies between Makefile's. A quick rm -rf build and one can start re-compiling if something goes wrong.

  1. Add DESTDIR option

I like to convert my source code installs into RPM packages before installing it. This requires me to use the DESTDIR option to set up a staging directory for the installation. I tried this with sagemath and it seemed to split the installtion between this staging area and the --prefix

  1. Add make install

I understand the decision to have make do both building and installing as it allows users to do both in one command (and its easier for developers). However this makes compiling rigid and causes problems when a user needs to customize their installation. For example, if one wishes to convert the source code directory to an RPM or DEB package.

These three suggestions can enhance the user experience.

Change History (4)

comment:1 Changed 3 years ago by gh-ChukwuemezieChristopherAneke

  • Description modified (diff)

comment:2 Changed 3 years ago by jhpalmieri

This looks like a duplicate of several other tickets. See #21479 (./configure --prefix=...), #21469 (enable VPATH builds), #21495 (make install), #21566. What parts of this ticket are not covered by those?

comment:3 Changed 3 years ago by gh-ChukwuemezieChristopherAneke

  • Description modified (diff)

comment:4 Changed 3 years ago by embray

  • Milestone changed from sage-feature to sage-duplicate/invalid/wontfix
  • Resolution set to duplicate
  • Status changed from new to closed

Thanks for your interest in helping to improve Sage's build/install experience. These are all well-known issues and most of them either have good reasons for them, or are actively being worked on (including work I'm doing, e.g. in #24024). I am also working in several directions to increase the number of dependencies Sage can inherit from the system rather than building its own (see e.g. #24919--a very important enhancement that desperately needs review).

You seem well-versed in build/packaging issues, so if you'd like to help out I can definitely point you in the right direction for contributing to ongoing work :)

Note: See TracTickets for help on using tickets.