Opened 3 years ago

Last modified 2 months ago

#2909 new defect

bad dependency expression results in rule firing on subsequent make, and make install

Reported by: gdt Owned by: strk
Priority: low Milestone: PostGIS 2.2.7
Component: build/upgrade/install Version: 2.1.x
Keywords: Cc: gdt

Description

In several makefiles, e.g extensions/postgis/Makefile.in, there is a rule:

sql_minor_upgrade: sql_bits/extension_upgrade_minor.sql
        for OLD_VERSION in $(UPGRADEABLE_VERSIONS_MINOR); do \
          cat $< > sql/$(EXTENSION)--$$OLD_VERSION--$(EXTVERSION).sql; \
        done

which results in the following being executed on a subsequent make, and on make install, because no file sql_minor_upgrade is created.

---- Making all in postgis
gmake[3]: Entering directory '/u0/n0/gdt/NetBSD-current/pkgsrc/wip/postgresql-postgis2/work/postgis-2.1.3/extensions/postgis'
for OLD_VERSION in 2.0.0 2.0.1 2.0.2 2.0.3 2.0.4 2.0.5; do \
          cat sql_bits/extension_upgrade_minor.sql > sql/postgis--$OLD_VERSION--2.1.3.sql; \
done
for OLD_VERSION in 2.1.0rc1 2.1.0rc2 2.1.0rc3 2.1.0 2.1.1 2.1.2; do \
          cat sql_bits/extension_upgrade_patch.sql > sql/postgis--$OLD_VERSION--2.1.3.sql; \
done
gmake[3]: Leaving directory '/u0/n0/gdt/NetBSD-current/pkgsrc/wip/postgresql-postgis2/work/postgis-2.1.3/extensions/postgis'

To fix, probably the phony target should be created by the rule body, so that it doesn't get reexecuted.

Attachments (1)

patch-extensions_postgis_Makefile.in (661 bytes) - added by gdt 3 years ago.
patch for discussion (works, but only fixes one subdir)

Download all attachments as: .zip

Change History (7)

comment:1 Changed 3 years ago by gdt

Version: trunk2.1.x

Sorry, this was observed on 2.1.3, not trunk.

Changed 3 years ago by gdt

patch for discussion (works, but only fixes one subdir)

comment:2 Changed 2 years ago by gdt

I am still seeing this in 2.1.8.

comment:3 Changed 20 months ago by dbaston

Milestone: PostGIS 2.1.9

comment:4 Changed 2 months ago by pramsey

Milestone: PostGIS 2.1.9PostGIS 2.2.6

comment:5 Changed 2 months ago by robe

Cc: gdt added

gdt is this still an issue for you in 2.4? I don't think I've every run into issue.

comment:6 Changed 2 months ago by pramsey

Milestone: PostGIS 2.2.6PostGIS 2.2.7
Note: See TracTickets for help on using tickets.