Changeset 5247008


Ignore:
Timestamp:
01/11/2023 02:19:04 PM (16 months ago)
Author:
Pierre Labastie <pierre.labastie@…>
Branches:
11.3, 12.0, 12.1, kea, ken/TL2024, ken/inkscape-core-mods, ken/tuningfonts, lazarus, lxqt, plabs/newcss, plabs/python-mods, python3.11, qt5new, rahul/power-profiles-daemon, renodr/vulkan-addition, trunk, xry111/llvm18, xry111/xf86-video-removal
Children:
bcd84ba4
Parents:
a04cf4b
Message:

Makefile: refactor "version" target

Makefile's use files for their dependency calculations. Since
git-version.sh generates files (version.ent and conditional.ent)
use version.ent to see whether git-version.sh has been run.

The only target that should depend on version.ent is then
$(BLFS_FULL) since all other targets depend (directly or indirectly
on this one).

version.ent itself depends on any change made to xml files, xsl files,
packages.ent, general.ent. We could add more (Makefile, gnome.ent, some
scripts), but let's see whether we really want it.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Makefile

    ra04cf4b r5247008  
    103103
    104104html: $(BASEDIR)/index.html
    105 $(BASEDIR)/index.html: $(RENDERTMP)/$(BLFSHTML) version
     105$(BASEDIR)/index.html: $(RENDERTMP)/$(BLFSHTML)
    106106        @echo "Generating chunked XHTML files..."
    107107        $(Q)xsltproc --nonet                                    \
     
    137137
    138138nochunks: $(BASEDIR)/$(NOCHUNKS_OUTPUT)
    139 $(BASEDIR)/$(NOCHUNKS_OUTPUT): $(RENDERTMP)/$(BLFSHTML) version
     139$(BASEDIR)/$(NOCHUNKS_OUTPUT): $(RENDERTMP)/$(BLFSHTML)
    140140        @echo "Generating non-chunked XHTML file..."
    141141        $(Q)xsltproc --nonet                                \
     
    160160
    161161validate: $(RENDERTMP)/$(BLFSFULL)
    162 $(RENDERTMP)/$(BLFSFULL): general.ent packages.ent $(ALLXML) $(ALLXSL) version
     162$(RENDERTMP)/$(BLFSFULL): version.ent
    163163        $(Q)[ -d $(RENDERTMP) ] || mkdir -p $(RENDERTMP)
    164164
     
    179179
    180180profile-html: $(RENDERTMP)/$(BLFSHTML)
    181 $(RENDERTMP)/$(BLFSHTML): $(RENDERTMP)/$(BLFSFULL) version
     181$(RENDERTMP)/$(BLFSHTML): $(RENDERTMP)/$(BLFSFULL)
    182182        @echo "Generating profiled XML for XHTML..."
    183183        $(Q)xsltproc --nonet                              \
     
    192192          blfs-patches.sh > blfs-patch-list
    193193
    194 blfs-patches.sh: $(RENDERTMP)/$(BLFSFULL) version
     194blfs-patches.sh: $(RENDERTMP)/$(BLFSFULL)
    195195        @echo "Generating blfs patch script..."
    196196        $(Q)xsltproc --nonet                     \
     
    200200
    201201wget-list: $(BASEDIR)/wget-list
    202 $(BASEDIR)/wget-list: $(RENDERTMP)/$(BLFSFULL) version
     202$(BASEDIR)/wget-list: $(RENDERTMP)/$(BLFSFULL)
    203203        @echo "Generating wget list for $(REV) at $(BASEDIR)/wget-list ..."
    204204        $(Q)mkdir -p $(BASEDIR)
     
    209209
    210210test-links: $(BASEDIR)/test-links
    211 $(BASEDIR)/test-links: $(RENDERTMP)/$(BLFSFULL) version
     211$(BASEDIR)/test-links: $(RENDERTMP)/$(BLFSFULL)
    212212        @echo "Generating test-links file..."
    213213        $(Q)mkdir -p $(BASEDIR)
     
    261261
    262262dump-commands: $(DUMPDIR)
    263 $(DUMPDIR): $(RENDERTMP)/$(BLFSFULL) version
     263$(DUMPDIR): $(RENDERTMP)/$(BLFSFULL)
    264264        @echo "Dumping book commands..."
    265265        $(Q)xsltproc --output $(DUMPDIR)/          \
     
    270270.PHONY: blfs all world html nochunks tmpdir clean  \
    271271   validate profile-html blfs-patch-list wget-list test-links \
    272    dump-commands  bootscripts systemd-units version
    273 
    274 version:
     272   dump-commands  bootscripts systemd-units
     273
     274version.ent: general.ent packages.ent $(ALLXML) $(ALLXSL)
    275275        $(Q)./git-version.sh $(REV)
    276276
Note: See TracChangeset for help on using the changeset viewer.