Changes between Version 5 and Version 8 of Ticket #21524

07/20/17 15:25:56 (3 years ago)

Here's my proposed solution to this (I updated the ticket to mention AC_CONFIG_FILE since that's what this uses).

This adds a build/make/ template that is used to generated build/make/Makefile in config.status. The configure script now just collects values for some variables that are inserted into the Makefile template. I tried to keep as much actual Makefile syntax out of the output variables as possible, sticking mostly to just lists of package names that are operated over. Most of the rules for building packages are generated by the Makefile itself in $(eval ...) loops. The end result I think is actually cleaner and easier to understand.

If any of this should be controversial, it may be the use of some more advanced GNU make constructs, the portability of which I'm not sure. This was tested with GNU make 3.81 (about 11 years old), and 4.2.1 (very recent). That said, it's using some relatively advanced GNU make features that may not be available in other makes. I think it's still better, but if need be more of the Makefile generation could be pushed back into configure, but still provided via output variables, instead of writing directly to a file.

Increased the priority since I have other build system work that would likely depend on this, and also because it makes some non-trivial performance improvements, especially on Cygwin.

New commits:

b034b3aFix minor bug in the conway_polynomials dependencies; it should just list the bare package name
f88d3cbUse AC_CONFIG_FILES + AC_OUTPUT to generate build/make/Makefile
db428a3Further rewrite of to do away with the multiple


  • Ticket #21524

    • Property Authors changed from to Erik Bray
    • Property Summary changed from write build/make/Makefile within an AC_CONFIG_COMMANDS, not during main configure to write build/make/Makefile within an AC_CONFIG_FILE, not during main configure
    • Property Priority changed from minor to major
    • Property Branch changed from to u/embray/build/makefile-in
    • Property Milestone changed from sage-7.4 to sage-8.1
    • Property Commit changed from to db428a360b0b8b0322744186c3a690bb38386574
  • Ticket #21524 – Description

    v5 v8  
    1 `build/make/Makefile` should be written within an AC_CONFIG_COMMANDS procedure, not at configure time.
     1`build/make/Makefile` should be written within an AC_CONFIG_FILE template, not at configure time.
    33Marking this as dependent on #21479 just because that ticket changes the same part of ``.