# # Installation path targets. # # Provide a target rule for every path component provided in Variables.gnu. # # This cannot be sourced directly into the local Rules.gnu because we cannot # mask out targets whose rules were defined elsewhere. This isn't typically # a problem since on most installations the paths already exist (e.g. # /usr/local/include). # PREFIXES := $(DESTDIR)$(prefix) $(DESTDIR)$(exec_prefix) PREFIXED_PATHS := $(DESTDIR)$(bindir) $(DESTDIR)$(sbindir) $(DESTDIR)$(libexecdir) $(DESTDIR)$(datadir) $(DESTDIR)$(sysconfdir) $(DESTDIR)$(sharedstatedir) $(DESTDIR)$(localstatedir) $(DESTDIR)$(includedir) $(DESTDIR)$(libdir) $(DESTDIR)$(localedir) $(DESTDIR)$(mandir) $(DESTDIR)$(infodir) # Only include unique paths, otherwise make(1) warns about duplicate targets. # # $(PREFIXES) are our order-only prerequisites, so we don't need to update # ourselves if the timestamp on them is newer than the target. # $(shell echo $(PREFIXES) $(PREFIXED_PATHS) | xargs -n1 | sort | uniq): $(MKDIR) -p $@