Changeset 220


Ignore:
Timestamp:
01/16/12 16:45:53 (13 years ago)
Author:
Kris Deugau
Message:

/trunk

Fix s.l.o.w "make install" - apparently there's a ~0.1s startup cost for
/usr/bin/install, so "for i in <list>; install $i <destdir>/path/$i" can
be significantly slower than "mkdir -p <path>; install <list> <destdir>/path"
for more than a handful of files.

Also make some mostly cosmetic fixes in Makefile variable expansion so we
don't accidentally end up with quotes embedded in some of the pathnames.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Makefile

    r219 r220  
    1919mandir = ${prefix}/man
    2020
    21 INSTALL = /usr/bin/install -c
     21INSTALL = /usr/bin/install
    2222INSTALL_PROGRAM = ${INSTALL}
    2323INSTALL_SCRIPT = ${INSTALL}
     
    3434
    3535# also set the leaf directories we'll be putting things in
    36 PKG_LEAF = "dnsdb"
    37 CFG_LEAF = "dnsdb"
     36PKG_LEAF = dnsdb
     37CFG_LEAF = dnsdb
    3838
    3939# tweak the final leaf directories we install to if PARA_VERSIONS is set
    4040ifeq "$(PARA_VERSIONS)" "1"
    41 PKG_LEAF = "dnsdb-$(VERSION)"
    42 CFG_LEAF = "dnsdb/$(VERSION)"
     41PKG_LEAF = dnsdb-$(VERSION)
     42CFG_LEAF = dnsdb/$(VERSION)
    4343endif
    4444
     
    9898
    9999install:
    100         @for i in $(IMAGES) $(TEMPLATES); do \
    101                 $(INSTALL_DATA) -D $$i $(DESTDIR)${datadir}/$(PKG_LEAF)/$$i ; \
    102         done
     100        @mkdir -p $(DESTDIR)${datadir}/$(PKG_LEAF)/images
     101        @$(INSTALL_DATA) $(IMAGES) $(DESTDIR)${datadir}/$(PKG_LEAF)/images
     102        @mkdir -p $(DESTDIR)${datadir}/$(PKG_LEAF)/templates
     103        @$(INSTALL_DATA) $(TEMPLATES) $(DESTDIR)${datadir}/$(PKG_LEAF)/templates
    103104        @# munge in necessary 'use lib ...' bits so scripts can find libs and config...
    104105        @# datadir is correct;  no arch-specific files
Note: See TracChangeset for help on using the changeset viewer.