4

Makefile.distrib

  1. #
  2.       COMPONENT = @COMPONENT@
  3.         VERSION = @VERSION@
  4.  
  5.       INC_FILES = @INC_FILES@
  6.       SRC_FILES = @SRC_FILES@
  7.       LIB_FILES = @LIB_FILES@
  8.  
  9.           OWNER = 0
  10.           GROUP = 0
  11.            MODE = 444
  12.           XMODE = 755
  13.  
  14.     INSTALL_DIR = /usr/local
  15.         INC_DIR = $(INSTALL_DIR)/include/$(COMPONENT)
  16.         LIB_DIR = $(INSTALL_DIR)/lib
  17.        ALL_DIRS = $(INSTALL_DIR)/include $(INC_DIR) $(LIB_DIR)
  18.  
  19.        TAR_FILE = $(COMPONENT)-$(VERSION).tar
  20.  
  21.         INSTALL = @INSTALL@
  22.  
  23. .SILENT:
  24.  
  25. install:    install.dir install.inc install.lib
  26.  
  27. install.dir:
  28.     echo [Installing $(COMPONENT) $(VERSION) in $(INSTALL_DIR)]
  29.     for n in $(ALL_DIRS); do if [ ! -d $$n ]; then mkdir $$n; chown $(OWNER) $$n; chgrp $(GROUP) $$n; chmod $(XMODE) $$n; fi; done
  30.  
  31. install.inc:
  32.     for n in $(INC_FILES); do echo $$n; done
  33.     $(INSTALL) -c -m $(MODE) -o $(OWNER) -g $(GROUP) $(INC_FILES) $(INC_DIR)
  34.  
  35. install.lib:
  36.     for n in $(LIB_FILES); do echo $$n; done
  37.     $(INSTALL) -c -m $(MODE) -o $(OWNER) -g $(GROUP) $(LIB_FILES) $(LIB_DIR)
  38.  
  39. distrib:
  40.     echo [Building $(TAR_FILE).gz]
  41.     (wd=`pwd`; dir=`basename $$wd`; cd ..; tar -chf - $$dir|gzip >$(TAR_FILE).gz)

Comments

Your comment:
[p] [b] [i] [u] [s] [quote] [pre] [br] [code] [url] [email] strip help 2000

Enter a maximum of 2000 characters.
Improve the presentation of your text with the following formatting tags:
[p]paragraph[/p], [b]bold[/b], [i]italics[/i], [u]underline[/u], [s]strike[/s], [quote]citation[/quote], [pre]as is[/pre], [br]line break,
[url]http://www.izend.org[/url], [url=http://www.izend.org]site[/url], [email]izend@izend.org[/email], [email=izend@izend.org]izend[/email],
[code]command[/code], [code=language]source code in c, java, php, html, javascript, xml, css, sql, bash, dos, make, etc.[/code].