File:  [Local Repository] / imach / src / Makefile
Revision 1.30: download - view: text, annotated - select for diffs
Fri Apr 30 09:00:45 2010 UTC (14 years, 6 months ago) by brouard
Branches: MAIN
CVS tags: HEAD
*** empty log message ***

    1: VERSION=0.98m
    2: COPYRIGHT=Copyright (C)  2002-2010 INED-EUROREVES-Institut de longevite
    3: IMACHSETUPVERSION=1
    4: 
    5: # make _windowsonlinux=1 imachcygopt.exe
    6: # make _windowsonlinux=1 imachcyg-setup (touch setup.iss.in)
    7: 
    8: # make _linux=1 imachopt
    9: # make _linux=1 imach
   10: 
   11: # make _macosx=1 imach
   12: # make _macosx=1 imachdmg
   13: 
   14: #        Windows
   15: # make _windows=1 imachcyg
   16: # make _windows=1 imachcyg-setup (touch setup.iss.in)
   17: # make _windows=1 imachcyg-noreg-setup
   18: # sortie dans Output/setup.exe
   19: # ln -s /cygdrive/c/Program\ Files/Inno\ Setup\ 4/Compil32.exe /usr/local/bin/Compil32
   20: ##SETUPCOMP=  "C:\Program Files\Inno Setup 3\Compil32.exe"
   21: 
   22: #CC= gcc -v
   23: CC=$(GCC)
   24: GCC= gcc
   25: 
   26: ifdef _macosx
   27: # Mac OS/X version
   28: LFLAGS= -O3 -lm -DUNIX
   29: CFLAGS= -O3 -DUNIX
   30: UNIX2DOS= echo "Unix2dos " 
   31: # Don'know how to launch imach098.pmsp in batch to create package file imach098Panther.pkg
   32: # ./createdmg.sh imach imach098panther ./imach098Panther
   33: # ./createdmg.sh imach imach098leopard ./imach098Leopard
   34: # and directory ./imach098Panther contains package file imach098Panther.pkg
   35: #./create-dmg --window-size 500 300 --background ~/Projects/eclipse-osx-repackager/build/background.gif --icon-size 96 --volname "Hyper Foo" --icon "Applications" 380 205 --icon "Eclipse OS X Repackager" 110 205 test2.dmg /Users/andreyvit/Projects/eclipse-osx-repackager/temp/Eclipse\ OS\ X\ Repackager\ r10/
   36: # ./create-dmg --volname "IMaCh 0.98j" imach098j.dmg imach098Leopard
   37: endif
   38: 
   39: ifdef _windows
   40: CC=c:\MinGW\bin\Mingw32-gcc
   41: 
   42: # Windows cygwin version
   43: LFLAGS= -g -mno-cygwin
   44: CFLAGS= -g -mno-cygwin
   45: LFLAGSOPT= -O3 -mno-cygwin
   46: CFLAGSOPT= -O3 -mno-cygwin
   47: UNIX2DOS= unix2dos
   48: CP= copy
   49: #SETUPCOMP= Compil32 
   50: ##SETUPCOMP=start /wait "C:\Program\ Files\\Compil32.exe"
   51: # cygwin SETUPCOMP=  "C:\Program Files\Inno Setup 4\Compil32.exe"
   52: SETUPCOMP= "C:////Program Files////Inno Setup 4////Compil32.exe"
   53: endif
   54: 
   55: ifdef _windowsonlinux
   56: GCC=/usr/bin/i586-pc-mingw32-gcc
   57: LFLAGS= -g
   58: CFLAGS= -g
   59: LFLAGSOPT= -O3 -lm
   60: CFLAGSOPT= -O3
   61: CP= cp
   62: UNIX2DOS= unix2dos
   63: SETUPCOMP= wine "C:////Program Files////Inno Setup 4////Compil32.exe"
   64: endif
   65: 
   66: ifdef _linux
   67: #CFLAGS= -g -DUNIX -DDEBUGHESS
   68: CFLAGS= -g -DUNIX
   69: LFLAGS= -g -lm 
   70: IGSL= -I/usr/include/gsl
   71: LGSL= -lgsl -lgslcblas
   72: CFLAGSOPT= -O3 -DUNIX
   73: LFLAGSOPT= -O3 -lm
   74: UNIX2DOS= unix2dos
   75: SETUPCOMP= wine "C:////Program Files////Inno Setup 4////Compil32.exe"
   76: endif
   77: 
   78: SED= sed
   79: PACKAGE=imach
   80: PROGRAM=IMaCh
   81: 
   82: 
   83: 
   84: TMPSETUPSCRIPT=setup.iss
   85: TMPNOREGSETUPSCRIPT=noreg-setup.iss
   86: TMPSCRIPTIN=setup.iss.in
   87: APPLICATION=IMaCh
   88: APPNAME=$(APPLICATION)-$(VERSION)
   89: GNUPLOTVERSION=4.0
   90: LICENSE=Copying
   91: TMPSETUPEXE=imach-$(VERSION)-$(IMACHSETUPVERSION)-setup.exe
   92: LICENSEFILE=$(LICENSE)
   93: INFOBEFOREFILE=README.txt
   94: 
   95: $(TMPSETUPSCRIPT): $(TMPSCRIPTIN)
   96: 	$(SED) -e "s/@APPNAME@/$(APPNAME)/g; \
   97: 		s/@NOTINNOREG@//g; \
   98: 		s/@NOREG@//g; \
   99: 		s/@IMACHSETUPVERSION@/$(IMACHSETUPVERSION)/g; \
  100: 		s/@VERSION@/$(VERSION)/g; \
  101: 		s/@GNUPLOTVERSION@/$(GNUPLOTVERSION)/g; \
  102: 		s/@INFOBEFOREFILE@/$(INFOBEFOREFILE)/g; \
  103: 		s/@LICENSEFILE@/$(LICENSEFILE)/g; \
  104: 		s/@PACKAGE@/$(PACKAGE)/g; \
  105: 		s/@DICTLANG@/$(DICTLANG)/g; \
  106: 	   	s/@VERMAJOR@/$(VERMAJOR)/g; \
  107: 		s/@COPYRIGHT@/$(COPYRIGHT)/g;" \
  108: 		$(TMPSCRIPTIN) > $(TMPSETUPSCRIPT)
  109: 
  110: $(TMPNOREGSETUPSCRIPT): $(TMPSCRIPTIN)
  111: 	$(SED) -e "s/@APPNAME@/$(APPNAME)/g; \
  112: 		s/@NOTINNOREG@/\\;/g; \
  113: 		s/@NOREG@/noreg-/g; \
  114: 		s/@IMACHSETUPVERSION@/$(IMACHSETUPVERSION)/g; \
  115: 		s/@VERSION@/$(VERSION)/g; \
  116: 		s/@GNUPLOTVERSION@/$(GNUPLOTVERSION)/g; \
  117: 		s/@INFOBEFOREFILE@/$(INFOBEFOREFILE)/g; \
  118: 		s/@LICENSEFILE@/$(LICENSEFILE)/g; \
  119: 		s/@PACKAGE@/$(PACKAGE)/g; \
  120: 		s/@DICTLANG@/$(DICTLANG)/g; \
  121: 	   	s/@VERMAJOR@/$(VERMAJOR)/g; \
  122: 		s/@COPYRIGHT@/$(COPYRIGHT)/g;" \
  123: 		$(TMPSCRIPTIN) > $(TMPNOREGSETUPSCRIPT)
  124: #	$(UNIX2DOS) $(TMPNOREGSETUPSCRIPT)
  125: 
  126: $(TMPSETUPEXE): $(TMPSETUPSCRIPT)
  127: 	$(SETUPCOMP) /cc $(TMPSETUPSCRIPT)
  128: 
  129: $(TMPNOREGSETUPEXE): $(TMPNOREGSETUPSCRIPT)
  130: 	$(SETUPCOMP) /cc $(TMPNOREGSETUPSCRIPT)
  131: 
  132: PARAM=mypar1
  133: 
  134: imachcyg-setup: imachcygopt.exe setup.iss
  135: 	$(CP) imachcygopt.exe imach.exe
  136: 	$(SETUPCOMP) /cc $(TMPSETUPSCRIPT)
  137: 
  138: # imachcyg-noreg-setup : imachcygopt imachcygopt.o setup.iss.in noreg-setup.iss $(TMPNOREGSETUPEXE)
  139: imachcyg-noreg-setup: imachcygopt.exe noreg-setup.iss
  140: 	$(CP) imachcygopt.exe imach.exe
  141: 	$(SETUPCOMP) /cc $(TMPNOREGSETUPSCRIPT)
  142: 
  143: simach : simach.o 
  144: 	$(CC) $(LFLAGS) $(LGSL) -o simach simach.o
  145: simach.o : simach.c 
  146: 	$(CC) $(CFLAGS) -DGSL -c simach.c
  147: 
  148: imach : imach.o 
  149: 	$(CC) $(LFLAGS) -o imach imach.o
  150: imach.o : imach.c 
  151: 	$(CC) $(CFLAGS) -DPOWELL -c imach.c
  152: 
  153: 
  154: imachsimplified : imachsimplified.o 
  155: 	$(CC)  $(LFLAGSOPT) -o imachsimplified imachsimplified.o
  156: imachsimplified.o : imachsimplified.c 
  157: 	$(CC) $(CFLAGSOPT) -DPOWELL -c imachsimplified.c
  158: 
  159: imachgsl : imachgsl.o 
  160: 	$(CC) $(LFLAGS) $(LGSL) -o imachgsl imach.o
  161: imachgsl.o : imach.c 
  162: 	$(CC) $(CFLAGS) -DGSL $(IGSL) -c imach.c
  163: 
  164: imachopt : imachopt.o 
  165: 	$(CC) $(LFLAGSOPT) -o imachopt imachopt.o
  166: 	ln -f imachopt imach
  167: imachopt.o : imach.c 
  168: 	$(CC) $(CFLAGSOPT) -DPOWELL -o imachopt.o -c imach.c
  169: 
  170: imachdmg : imachopt.o create-dmg
  171: 	$(CC) $(LFLAGSOPT) -o imach imachopt.o
  172: 	cp imach imach098Leopard/bin
  173: 	./create-dmg --volname "IMaCh $(VERSION)" imach$(VERSION).dmg imach098Leopard
  174: 
  175: 
  176: imachcyg : imachcyg.o  strsep.o
  177: 	$(CC) $(LFLAGS) -o imach imachcyg.o strsep.o
  178: imachcyg.o : imach.c 
  179: 	$(CC) $(CFLAGS)  -c -o imachcyg.o imach.c
  180: imachcygopt.exe : imachcygopt.o  strsep.o
  181: 	$(CC) $(LFLAGSOPT) -o imachcygopt.exe imachcygopt.o strsep.o
  182: imachcygopt.o : imach.c 
  183: 	$(CC) $(CFLAGSOPT) -c -o imachcygopt.o imach.c
  184: strsep.o : strsep.c 
  185: 	$(CC) $(CFLAGSOPT) -c -o strsep.o strsep.c
  186: 
  187: imachw32.o : imach.c
  188: 	i386-mingw32-gcc -c imach.c -o imachw32.o
  189: imach.exe : imachw32.o 
  190: 	i386-mingw32-gcc  -mwindows -o imach.exe -lm imachw32.o
  191: 	i386-mingw32-strip imach.exe
  192: 
  193: 
  194: $(PARAM).htm: imach $(PARAM).imach data1.txt
  195: 	./imach $(PARAM).imach
  196: 
  197: clean: 
  198: 	rm or$(PARAM).txt er$(PARAM).txt pijr$(PARAM).txt plr$(PARAM).txt \
  199: 	r$(PARAM).txt tr$(PARAM).txt vpl$(PARAM).txt pr$(PARAM).txt \
  200: 	vr$(PARAM).txt *.gif imach.exe imach.o
  201: 
  202: 

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>