Changeset 317 for trunk/Makefile


Ignore:
Timestamp:
08/06/09 06:28:35 (3 years ago)
Author:
marc
Message:

Improved makefile to work with prefixes, fixed errors, improved manpag and readme, and fix a configuration error

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Makefile

    r315 r317  
    66FIND ?= find 
    77 
    8 PREFIX = /usr 
     8PREFIX = /usr/local 
    99# When debian builds it, it passes its own DESTDIR 
    1010DESTDIR = $(PREFIX) 
     
    2929        mv config.py config.py.old 
    3030        mv itaka.py itaka.py.old 
    31         sed -e "s|/usr/share/itaka/images/|$(REPLACEIMAGESDIR)|g" config.py.old > config.py 
    32         sed -e "s|/usr/share/locale/|$(REPLACELOCALEDIR)|g" itaka.py.old > itaka.py 
    33         mv config.py.old config.py 
    34         mv itaka.py.old itaka.py 
     31        sed "s|/usr/local/share/itaka/images/|$(REPLACEIMAGESDIR)|g" config.py.old > config.py 
     32        sed "s|/usr/share/locale/|$(REPLACELOCALEDIR)|g" itaka.py.old > itaka.py 
    3533         
    3634        $(INSTALL) -m 755 -d $(BINDIR) $(DATADIR) $(LIBDIR) $(IMAGESDIR) $(APPLICATIONSDIR) $(ICONDIR) $(MANDIR) 
     
    5250        $(INSTALL) -m 644 share/itaka.1.gz $(MANDIR) 
    5351        if test -f $(BINDIR)/itaka; then rm $(BINDIR)/itaka; fi  
     52 
     53        # Create our binary directory for the symlink 
     54        if test ! -d $(BINDIR); then mkdir $(BINDIR); fi 
    5455        ln -sf  $(LIBDIR)/itaka.py $(BINDIR)/itaka 
    55         echo $( ls $(BINDIR)/itaka ) 
     56 
     57        #echo $( ls $(BINDIR)/itaka ) 
    5658        chmod +x $(BINDIR)/itaka 
    5759         
     
    6466        done 
    6567 
     68        # Clean up 
     69        mv config.py.old config.py 
     70        mv itaka.py.old itaka.py 
     71 
    6672uninstall: 
    6773        rm -r $(BINDIR)/itaka $(DATADIR) $(LIBDIR) $(ICONDIR)/itaka.png $(APPLICATIONSDIR)/itaka.desktop $(MANDIR)/itaka.1.gz 
    6874 
    6975clean: 
    70         find . -type f  \( -regex '.+\.py[co]' -o -name 'itaka.1.gz' \) -exec rm {} \; 
     76        find . -type f  \( -regex '.+\.py[co]' -o -name 'itaka.1.gz' \) -exec rm -f {} \; 
    7177        rm locale/*/LC_MESSAGES/*.mo 
    7278 
Note: See TracChangeset for help on using the changeset viewer.