Annotation of imach/src/Makefile, revision 1.63

1.63    ! brouard     1: #Version has to be set in ../CMakeLists.txt too.
        !             2: VERSION=0.98q5
        !             3: # DRIVEG is for VirtualBox Windows 64bit 
        !             4: DRIVEG=g:
        !             5: #DIRG is the corresponding build directory for Virtual Windows
        !             6: DIRG=\imach\cvs\imach\build
1.57      brouard     7: COPYRIGHT=Copyright (C)  2002-2015 INED-EUROREVES-Institut de longevite-Japan Society for the Promotion of Science (Grant-in-Aid for Scientific Research 25293121) - Intel Software 2015
1.62      brouard     8: IMACHSETUPVERSION=icl
1.60      brouard     9: # This is for Windows only
1.57      brouard    10: #IMACHSETUPVERSION=mvc
1.21      brouard    11: 
1.40      brouard    12: #       Linux
1.21      brouard    13: # make _linux=1 imachopt
                     14: # make _linux=1 imach
1.62      brouard    15: # cpack -D CPACK_RPM_PACKAGE_DEBUG=1 -D CPACK_RPM_SPEC_INSTALL_POST="/bin/true" -G RPM
1.40      brouard    16: # make _linux32onosx=1 imachopt
                     17: # make _linux64onosx=1 imachopt
                     18: 
1.42      brouard    19: #       OS/X
1.61      brouard    20: # make _macosx=1 imachdmg
1.48      brouard    21: # make _intel64onosx=1 imachopt
1.49      brouard    22: # make _intel32onosx=1 imachopt
                     23: # make _intelUNBonosx=1 imachdmg # Not implemented (not useful)
1.27      brouard    24: # make _macosx=1 imach
1.49      brouard    25: # make _macosx=1 imachopt
1.32      brouard    26: #  valgrind  --dsymutil=yes --leak-check=full --show-leak-kinds=all --track-origins=yes ~/Documents/imachcvs/imach/src/imach-1.129cvsmac radlc-1.129.imach
1.21      brouard    27: 
                     28: #        Windows
1.62      brouard    29: # make _windowsonosx=1 imachICL-setup (touch setup.iss.in) #binary should have been compiled on Windows with Intel
1.45      brouard    30: # make _windowsonosx=1 imachMVC-setup (touch setup.iss.in) #binary should have been compiled on Windows with cl
1.51      brouard    31: # make _windowsonosx=1 imachMVC-noreg-setup
1.42      brouard    32: #
1.44      brouard    33: #        Windows cross-compiled mw64
                     34: # make _mw64onsox=1 imachcyg-setup
                     35: #
1.21      brouard    36: # make _windows=1 imachcyg
1.23      lievre     37: # make _windows=1 imachcyg-setup (touch setup.iss.in)
                     38: # make _windows=1 imachcyg-noreg-setup
1.31      brouard    39: #
                     40: # make _windowsonlinux=1 imachcyg-setup (touch setup.iss.in)
                     41: # make _windowsonlinux=1 imachcyg-noreg-setup
                     42: #
1.42      brouard    43: # make _windowscl=1 imachclopt
1.40      brouard    44: 
1.31      brouard    45: #
1.21      brouard    46: # sortie dans Output/setup.exe
                     47: # ln -s /cygdrive/c/Program\ Files/Inno\ Setup\ 4/Compil32.exe /usr/local/bin/Compil32
                     48: ##SETUPCOMP=  "C:\Program Files\Inno Setup 3\Compil32.exe"
1.36      brouard    49: #TESTFILE=$$HOME/Documents/Recherches/REVES/SAITO/Tokyo2014/adlc-test-mac/adecode-1.142c.imach
1.45      brouard    50: #TESTFILE=$(HOME)/Documents/Recherches/REVES/carol/carol-june2014/educadlmwt24.imach
1.55      brouard    51: #TESTFILE=$(HOME)/Documents/Recherches/REVES/Biaspar/biaspar-wopowell.imach
1.58      brouard    52: #TESTFILE=$(HOME)/Documents/Recherches/REVES/Biaspar/rbiaspar-098p.imach
                     53: TESTFILE=$(HOME)/Documents/Recherches/REVES/Aaron/brouard/results/COVARAITE_94/rmypar24pis1cov1-age.imach
1.34      brouard    54: #TESTFILE=$(HOME)/Documents/Recherches/REVES/SAITO/Tokyo2014/adlc-test-mac/adecode-1.142c.imach
1.35      brouard    55: #TESTFILE=$(HOME)/Documents/Recherches/REVES/SAITO/Tokyo2014/adlc_test_magei4/radlc_often.imach
1.21      brouard    56: #CC= gcc -v
1.28      brouard    57: CC=$(GCC)
                     58: GCC= gcc
1.21      brouard    59: 
                     60: ifdef _macosx
                     61: # Mac OS/X version
1.45      brouard    62: LFLAGS= -g -lm 
1.58      brouard    63: #CFLAGS= -g -DDEBUG 
                     64: CFLAGS= -g 
1.45      brouard    65: LFLAGSOPT= -O3 -lm 
1.55      brouard    66: CFLAGSOPT= -O3 
1.58      brouard    67: CP= cp
1.54      brouard    68: CROSSCOMPILATION= -DCROSS=0
1.21      brouard    69: UNIX2DOS= echo "Unix2dos " 
1.34      brouard    70: DSYMUTIL= dsymutil
1.42      brouard    71: STRIP= strip
                     72: BINVERSION=OSX
1.21      brouard    73: # Don'know how to launch imach098.pmsp in batch to create package file imach098Panther.pkg
                     74: # ./createdmg.sh imach imach098panther ./imach098Panther
1.27      brouard    75: # ./createdmg.sh imach imach098leopard ./imach098Leopard
1.21      brouard    76: # and directory ./imach098Panther contains package file imach098Panther.pkg
1.27      brouard    77: #./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/
                     78: # ./create-dmg --volname "IMaCh 0.98j" imach098j.dmg imach098Leopard
1.21      brouard    79: endif
                     80: 
                     81: ifdef _windows
1.29      brouard    82: CC=c:\MinGW\bin\Mingw32-gcc
                     83: 
1.21      brouard    84: # Windows cygwin version
                     85: LFLAGS= -g -mno-cygwin
                     86: CFLAGS= -g -mno-cygwin
                     87: LFLAGSOPT= -O3 -mno-cygwin
                     88: CFLAGSOPT= -O3 -mno-cygwin
                     89: UNIX2DOS= unix2dos
1.30      brouard    90: CP= copy
1.42      brouard    91: BINVERSION=CYGWIN
1.29      brouard    92: #SETUPCOMP= Compil32 
1.21      brouard    93: ##SETUPCOMP=start /wait "C:\Program\ Files\\Compil32.exe"
1.29      brouard    94: # cygwin SETUPCOMP=  "C:\Program Files\Inno Setup 4\Compil32.exe"
                     95: SETUPCOMP= "C:////Program Files////Inno Setup 4////Compil32.exe"
1.21      brouard    96: endif
                     97: 
1.28      brouard    98: ifdef _windowsonlinux
                     99: GCC=/usr/bin/i586-pc-mingw32-gcc
                    100: LFLAGS= -g
                    101: CFLAGS= -g
1.30      brouard   102: LFLAGSOPT= -O3 -lm
1.28      brouard   103: CFLAGSOPT= -O3
1.55      brouard   104: CROSSCOMPILATION= -DCROSS=1
1.30      brouard   105: CP= cp
1.28      brouard   106: UNIX2DOS= unix2dos
                    107: SETUPCOMP= wine "C:////Program Files////Inno Setup 4////Compil32.exe"
1.42      brouard   108: BINVERSION=WINDOWSonLINUX
1.28      brouard   109: endif
                    110: 
1.31      brouard   111: ifdef _windowsonosx
1.40      brouard   112: #GCC=/usr/local/i386-mingw32-4.3.0/bin/i386-mingw32-gcc
1.31      brouard   113: #GCC=/usr/local/cross-tools/bin/i686-w64-mingw32-gcc
1.38      brouard   114: GCC=/usr/local/gcc-4.8.0-qt-4.8.4-for-mingw32/win32-gcc/bin/i586-mingw32-gcc-4.8.0
1.40      brouard   115: STRIP=/usr/local/gcc-4.8.0-qt-4.8.4-for-mingw32/win32-gcc/bin/i586-mingw32-strip
                    116: LFLAGS= -g
                    117: CFLAGS= -g
                    118: LFLAGSOPT= -O3 -s
                    119: CFLAGSOPT= -O3
1.55      brouard   120: CROSSCOMPILATION= -DCROSS=1
1.40      brouard   121: UNIX2DOS= unix2dos
                    122: SETUPCOMP= ~/bin/InnoSetup5Playonmac
                    123: CP= cp
1.42      brouard   124: BINVERSION=WIN32onOSX
                    125: endif
                    126: 
1.44      brouard   127: ifdef _mw64onosx
                    128: GCC=/usr/local/mingw-w64-bin_i686-darwin_20130622/bin/x86_64-w64-mingw32-gcc-4.9.0
                    129: STRIP=/usr/local/mingw-w64-bin_i686-darwin_20130622/bin/x86_64-w64-mingw32-strip
                    130: LFLAGS= -g
                    131: CFLAGS= -g
                    132: LFLAGSOPT= -O3 -lm -s
                    133: CFLAGSOPT= -O3
1.55      brouard   134: CROSSCOMPILATION= -DCROSS=1
1.44      brouard   135: UNIX2DOS= unix2dos
                    136: SETUPCOMP= ~/bin/InnoSetup5Playonmac
                    137: CP= cp
                    138: BINVERSION=w64-mingw32-x86-64-bin
                    139: endif
                    140: 
1.42      brouard   141: ifdef _windowscl
                    142: rem "C:\Program Files\Microsoft Visual Studio 10.0\VC\bin\vcvas32.bat"
1.40      brouard   143: endif
                    144: 
1.48      brouard   145: # make _intel64onosx=1 imachopt
                    146: #source /opt/intel/bin/iccvars.sh intel64
                    147: ifdef _intel64onosx
                    148: GCC=/opt/intel/bin/icc
                    149: CFLAGS= -m64 -g -std=c99
1.49      brouard   150: LFLAGS= -g -m64
1.52      brouard   151: #CFLAGSOPT= -O3 -m64 -g -std=c99 -no-prec-div idem
                    152: #CFLAGSOPT= -O3 -m64 -g -std=c99 -xSSSE3_ATOM 402
1.49      brouard   153: CFLAGSOPT= -O3 -m64 -g -std=c99
1.52      brouard   154: CROSSCOMPILATION= -DCROSS=0
1.48      brouard   155: IGNORE :=$(shell bash -c "source /opt/intel/bin/iccvars.sh intel64; env | sed 's/=/:=/' | sed 's/^/export /' > makeenv")
                    156: include makeenv
                    157: #lipo -create -arch i386 HelloWorld_32 -arch x86_64 HelloWorld_64 -output HelloWorld
1.49      brouard   158: LFLAGSOPT= -O3 -m64
1.48      brouard   159: UNIX2DOS= unix2dos
                    160: SETUPCOMP= ~/bin/InnoSetup5Playonmac
                    161: CP= cp
                    162: BINVERSION=osx-intel-x86-64-bin
1.49      brouard   163: #imach_64$(VERSION)
                    164: #
                    165: endif
                    166: 
                    167: ifdef _intel32onosx
                    168: GCC=/opt/intel/bin/icc
                    169: CFLAGS= -m32 -g -std=c99
                    170: LFLAGS= -g -m32
                    171: CFLAGSOPT= -O3 -m32 -g -std=c99
1.52      brouard   172: CROSSCOMPILATION= -DCROSS=0
1.49      brouard   173: IGNORE :=$(shell bash -c "source /opt/intel/bin/iccvars.sh ia32; env | sed 's/=/:=/' | sed 's/^/export /' > makeenv")
                    174: include makeenv
                    175: #lipo -create -arch i386 HelloWorld_32 -arch x86_64 HelloWorld_64 -output HelloWorld
                    176: #lipo -create -arch i386 imach_32$(VERSION) -arch x86_64 imach_64$(VERSION) -output imach$(VERSION)
                    177: LFLAGSOPT= -O3 -m32
                    178: UNIX2DOS= unix2dos
                    179: SETUPCOMP= ~/bin/InnoSetup5Playonmac
                    180: CP= cp
                    181: BINVERSION=osx-intel-ia32-bin
1.48      brouard   182: endif
                    183: 
1.40      brouard   184: ifdef _linux64onosx
1.51      brouard   185: GCC=/usr/localold/gcc-4.8.1-for-linux64/bin/x86_64-pc-linux-gcc
                    186: STRIP=/usr/localold/gcc-4.8.1-for-linux64/bin/x86_64-pc-linux-strip
1.40      brouard   187: LFLAGS= -g
                    188: CFLAGS= -g
1.51      brouard   189: CROSSCOMPILATION= -DCROSS=1
1.40      brouard   190: LFLAGSOPT= -O3 -lm -s
                    191: CFLAGSOPT= -O3
1.51      brouard   192: TAR= /sw/bin/gnutar
1.40      brouard   193: UNIX2DOS= unix2dos
                    194: SETUPCOMP= ~/bin/InnoSetup5Playonmac
                    195: CP= cp
1.42      brouard   196: BINVERSION=linux-x86-64-bin
1.40      brouard   197: endif
                    198: 
                    199: ifdef _linux32onosx
                    200: #GCC=/usr/local/i386-mingw32-4.3.0/bin/i386-mingw32-gcc
                    201: #GCC=/usr/local/cross-tools/bin/i686-w64-mingw32-gcc
1.51      brouard   202: GCC=/usr/localold/gcc-4.8.1-for-linux32/bin/i586-pc-linux-gcc
                    203: STRIP=/usr/localold/gcc-4.8.1-for-linux32/bin/i586-pc-linux-strip
1.31      brouard   204: LFLAGS= -g
                    205: CFLAGS= -g
1.40      brouard   206: LFLAGSOPT= -O3 -s -lm
1.31      brouard   207: CFLAGSOPT= -O3
1.55      brouard   208: CROSSCOMPILATION= -DCROSS=1
1.51      brouard   209: TAR= /sw/bin/gnutar
1.31      brouard   210: UNIX2DOS= unix2dos
                    211: SETUPCOMP= ~/bin/InnoSetup5Playonmac
1.32      brouard   212: CP= cp
1.42      brouard   213: BINVERSION=linux-i586-bin
1.31      brouard   214: endif
                    215: 
1.21      brouard   216: ifdef _linux
1.26      brouard   217: #CFLAGS= -g -DUNIX -DDEBUGHESS
1.56      brouard   218: #CFLAGS= -g -DDEBUG -DFIXMNBRAK
1.58      brouard   219: #CFLAGS= -g -DDEBUG 
                    220: CFLAGS= -g
1.42      brouard   221: LFLAGS= -g -lm
1.30      brouard   222: IGSL= -I/usr/include/gsl
1.25      brouard   223: LGSL= -lgsl -lgslcblas
1.46      brouard   224: INLOPT= -I/usr/local/include
                    225: LNLOPT= -lm -L/usr/local/lib -lnlopt
1.47      brouard   226: CFLAGSOPT= -O3 -g
                    227: LFLAGSOPT= -O3 -g -lm
1.55      brouard   228: CROSSCOMPILATION= -DCROSS=0
1.21      brouard   229: UNIX2DOS= unix2dos
                    230: SETUPCOMP= wine "C:////Program Files////Inno Setup 4////Compil32.exe"
1.42      brouard   231: BINVERSION=LINUXnative
1.50      brouard   232: CP= cp
1.21      brouard   233: endif
                    234: 
                    235: SED= sed
                    236: PACKAGE=imach
                    237: PROGRAM=IMaCh
                    238: 
                    239: 
                    240: TMPSETUPSCRIPT=setup.iss
                    241: TMPNOREGSETUPSCRIPT=noreg-setup.iss
                    242: TMPSCRIPTIN=setup.iss.in
                    243: APPLICATION=IMaCh
                    244: APPNAME=$(APPLICATION)-$(VERSION)
1.57      brouard   245: APPCOMPILATIONMODE=$(IMACHSETUPVERSION)
                    246: GNUPLOTVERSION=4.6
1.21      brouard   247: LICENSE=Copying
                    248: TMPSETUPEXE=imach-$(VERSION)-$(IMACHSETUPVERSION)-setup.exe
1.31      brouard   249: TMPNOREGSETUPEXE=imach-$(VERSION)-$(IMACHSETUPVERSION)-noreg-setup.exe
1.21      brouard   250: LICENSEFILE=$(LICENSE)
                    251: INFOBEFOREFILE=README.txt
                    252: 
1.31      brouard   253: setup.iss: setup.iss.in
1.21      brouard   254:        $(SED) -e "s/@APPNAME@/$(APPNAME)/g; \
                    255:                s/@NOTINNOREG@//g; \
                    256:                s/@NOREG@//g; \
                    257:                s/@IMACHSETUPVERSION@/$(IMACHSETUPVERSION)/g; \
1.57      brouard   258:                s/@APPCOMPILATIONMODE@/$(APPCOMPILATIONMODE)/g; \
1.21      brouard   259:                s/@VERSION@/$(VERSION)/g; \
                    260:                s/@GNUPLOTVERSION@/$(GNUPLOTVERSION)/g; \
                    261:                s/@INFOBEFOREFILE@/$(INFOBEFOREFILE)/g; \
                    262:                s/@LICENSEFILE@/$(LICENSEFILE)/g; \
                    263:                s/@PACKAGE@/$(PACKAGE)/g; \
                    264:                s/@DICTLANG@/$(DICTLANG)/g; \
                    265:                s/@VERMAJOR@/$(VERMAJOR)/g; \
                    266:                s/@COPYRIGHT@/$(COPYRIGHT)/g;" \
1.31      brouard   267:                setup.iss.in > setup.iss
1.21      brouard   268: 
                    269: $(TMPNOREGSETUPSCRIPT): $(TMPSCRIPTIN)
                    270:        $(SED) -e "s/@APPNAME@/$(APPNAME)/g; \
                    271:                s/@NOTINNOREG@/\\;/g; \
                    272:                s/@NOREG@/noreg-/g; \
                    273:                s/@IMACHSETUPVERSION@/$(IMACHSETUPVERSION)/g; \
                    274:                s/@VERSION@/$(VERSION)/g; \
                    275:                s/@GNUPLOTVERSION@/$(GNUPLOTVERSION)/g; \
                    276:                s/@INFOBEFOREFILE@/$(INFOBEFOREFILE)/g; \
                    277:                s/@LICENSEFILE@/$(LICENSEFILE)/g; \
                    278:                s/@PACKAGE@/$(PACKAGE)/g; \
                    279:                s/@DICTLANG@/$(DICTLANG)/g; \
                    280:                s/@VERMAJOR@/$(VERMAJOR)/g; \
                    281:                s/@COPYRIGHT@/$(COPYRIGHT)/g;" \
                    282:                $(TMPSCRIPTIN) > $(TMPNOREGSETUPSCRIPT)
1.29      brouard   283: #      $(UNIX2DOS) $(TMPNOREGSETUPSCRIPT)
1.21      brouard   284: 
                    285: $(TMPSETUPEXE): $(TMPSETUPSCRIPT)
                    286:        $(SETUPCOMP) /cc $(TMPSETUPSCRIPT)
                    287: 
1.59      brouard   288: #$(TMPNOREGSETUPEXE): $(TMPNOREGSETUPSCRIPT)
                    289: #      $(SETUPCOMP) /cc $(TMPNOREGSETUPSCRIPT)
1.21      brouard   290: 
                    291: PARAM=mypar1
                    292: 
                    293: imachcyg-setup: imachcygopt.exe setup.iss
1.38      brouard   294:        touch setup.iss.in
1.30      brouard   295:        $(CP) imachcygopt.exe imach.exe
1.42      brouard   296:        $(CP) imachcygopt.exe imach$(VERSION)-$(BINVERSION).exe
1.31      brouard   297:        $(SETUPCOMP) /cc setup.iss
                    298:        cp Output/$(TMPSETUPEXE) imachcyg-setup
1.21      brouard   299: 
                    300: # imachcyg-noreg-setup : imachcygopt imachcygopt.o setup.iss.in noreg-setup.iss $(TMPNOREGSETUPEXE)
                    301: imachcyg-noreg-setup: imachcygopt.exe noreg-setup.iss
1.38      brouard   302:        touch setup.iss.in
1.30      brouard   303:        $(CP) imachcygopt.exe imach.exe
1.42      brouard   304:        $(CP) imachcygopt.exe imach$(VERSION)-$(BINVERSION).exe
1.21      brouard   305:        $(SETUPCOMP) /cc $(TMPNOREGSETUPSCRIPT)
1.31      brouard   306:        cp Output/$(TMPNOREGSETUPEXE) imachcyg-noreg-setup
1.62      brouard   307: # ICL compiler 64
                    308: imachICL-build: imach.c
                    309:        icl /GS /W3 /Zc:wchar_t /O2  /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "UNICODE" /Qipo /Zc:forScope  /MT imach.c 
                    310: #/GS /W3 /Gy /Zc:wchar_t /Zi /O2 /Fd"x64\Release\vc120.pdb" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_LIB" /D "_UNICODE" /D "UNICODE" /Qipo /Zc:forScope /Oi /MT /Fa"x64\Release\" /EHsc /nologo /Fo"x64\Release\" /Qprof-dir "x64\Release\" /Fp"x64\Release\IMaCh-icl-x64-0.98q2.pch"
                    311: #  /Users/nbrouard/Documents/imach/imach-gui/build/icl64/Release/imach.exe
1.57      brouard   312: # both 32 and 64 executables should have been built on Windows with Intel compiler.
1.63    ! brouard   313: imachICL-setup: ../build/icl64/Release/IMaCh-$(VERSION).exe ../build/icl32/Release/IMaCh-$(VERSION).exe setup.iss ../distributions/windows/mybuildicl64.bat ../distributions/windows/mybuildicl32.bat 
1.51      brouard   314:        pwd
1.63    ! brouard   315:        touch setup.iss.in
1.57      brouard   316:        $(SETUPCOMP) /cc setup.iss
1.62      brouard   317:        $(CP) Output/$(TMPSETUPEXE) imachICL-setup
1.57      brouard   318: 
1.62      brouard   319: # imachICL64-setup: IMaCh-icl64-$(VERSION).exe setup.iss
                    320: #      pwd
                    321: #      $(CP) IMaCh-icl64-$(VERSION).exe imach.exe
                    322: #      $(SETUPCOMP) /cc setup.iss
                    323: #      $(CP) Output/$(TMPSETUPEXE) imachICL64-setup
1.45      brouard   324: 
1.62      brouard   325: imachICL64-noreg-setup: IMaCh-icl64-$(VERSION).exe noreg-setup.iss
1.45      brouard   326:        touch setup.iss.in
                    327:        $(SETUPCOMP) /cc $(TMPNOREGSETUPSCRIPT)
1.62      brouard   328:        $(CP) Output/$(TMPSETUPEXE) imachICL64-noreg-setup
                    329: 
1.63    ! brouard   330: ../build/icl64/Release/IMaCh-$(VERSION).exe: imach.c ../distributions/windows/mybuildicl64.bat
1.62      brouard   331:        rm -rf ../build/icl64  && mkdir ../build/icl64
1.63    ! brouard   332:        cp ../distributions/windows/mybuildicl64.bat ../build/icl64/
1.62      brouard   333:        cd ../build/icl64
                    334:        VBoxManage --nologo guestcontrol "Windows7-64" execute --image "C:\Windows\SysWOW64\cmd.exe" \
1.63    ! brouard   335:        --username brouard  --verbose --wait-exit --wait-stdout  --wait-stderr -- "/c" "$(DRIVEG)$(DIRG)\icl64\mybuildicl64.bat" "$(VERSION)" "$(DRIVEG)" "$(DIRG)"
1.62      brouard   336: 
1.63    ! brouard   337: ../build/icl32/Release/IMaCh-$(VERSION).exe: imach.c ../distributions/windows/mybuildicl32.bat
1.62      brouard   338:        rm -rf ../build/icl32 && mkdir -p ../build/icl32
1.63    ! brouard   339:        cp ../distributions/windows/mybuildicl32.bat ../build/icl32/
1.62      brouard   340:        cd ../build/icl32
                    341:        VBoxManage --nologo guestcontrol "Windows7-64" execute --image "C:\Windows\SysWOW64\cmd.exe" \
1.63    ! brouard   342:        --username brouard  --verbose --wait-exit --wait-stdout -- "/c" "$(DRIVEG)$(DIRG)\icl32\mybuildicl32.bat" "$(VERSION)" "$(DRIVEG)" "$(DIRG)"
1.62      brouard   343: 
                    344: ../build/vs32/Release/IMaCh-$(VERSION).exe: imach.c mybuildvs32.bat
                    345:        rm -rf ../build/vs32 && mkdir -p ../build/vs32
                    346:        cp mybuildvs32.bat ../build/vs32/
                    347:        cd ../build/vs32
                    348:        VBoxManage --nologo guestcontrol "Windows7-64" execute --image "C:\Windows\SysWOW64\cmd.exe" \
                    349:        --username brouard  --verbose --wait-exit --wait-stdout -- "/c" "g:\imach\imach-gui\build\vs32\mybuildvs32.bat" "$(VERSION)"
                    350: # C:\Windows\SysWOW64\cmd.exe /E:ON /V:ON /K "g:\imach\imach-gui\build\icl32\mybuild.bat"
                    351: #WORK  --username brouard  --verbose --wait-exit --wait-stdout -- "/c" "c:\users\brouard\mybuild.bat"
                    352: #      --username brouard  --verbose --wait-exit --wait-stdout -- "/c" "g: && cd \imach\imach-gui\build\icl32 && mybuild.bat"
                    353: #      --username brouard  --verbose --wait-exit --wait-stdout -- "/c" "g: && cd \imach\imach-gui\build\icl32-xp  &&" "C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\Tools\VsDevCmd.bat" "&&" "C:\Program Files (x86)\Intel\Composer XE 2015\bin\ipsxe-comp-vars.bat" "ia32" "vs2013" "&&" "msbuild imach-0.98q3.vcxproj /t:Build /p:Configuration=Release"
                    354: #      --username brouard --wait-exit --wait-stdout -- "/c" "g: && cd \imach\imach-gui\build\icl32-xp\ &&C:\Windows\SysWOW64\cmd.exe /E:ON /V:ON /K ""C:\Program Files (x86)\Intel\Composer XE 2015\bin\ipsxe-comp-vars.bat" ia32 vs2013"&& msbuild imach.vcxproj >c:\users\brouard\totog.txt"
                    355: #              --username brouard --wait-exit --wait-stdout -- "/c" "g: && dir >c:\users\brouard\totog.txt"
                    356: #C:\Windows\SysWOW64\cmd.exe /E:ON /V:ON /K ""C:\Program Files (x86)\Intel\Composer XE 2015\bin\ipsxe-comp-vars.bat" ia32 vs2013"
                    357: #C:\Windows\SysWOW64\cmd.exe /E:ON /V:ON /K ""C:\Program Files (x86)\Intel\Composer XE 2015\bin\ipsxe-comp-vars.bat" intel64 vs2013"
1.45      brouard   358: 
1.62      brouard   359: imachICL64-setup: ../build/icl64/Release/IMaCh-$(VERSION).exe setup.iss mybuildicl64.bat
                    360: 
                    361: imachICL32-setup: ../build/icl32/Release/IMaCh-$(VERSION).exe setup.iss mybuildicl32.bat
                    362: 
                    363: imachVS32-setup: ../build/vs32/Release/IMaCh-$(VERSION).exe setup.iss mybuildvs32.bat
1.51      brouard   364: 
1.62      brouard   365: imachICL32-noreg-setup: IMaCh-icl32.exe noreg-setup.iss
1.51      brouard   366:        touch setup.iss.in
1.62      brouard   367:        $(CP) IMaCh-icl32.exe imach.exe
1.51      brouard   368:        $(SETUPCOMP) /cc $(TMPNOREGSETUPSCRIPT)
1.62      brouard   369:        $(CP) Output/$(TMPSETUPEXE) imachICL32-noreg-setup
1.51      brouard   370: 
1.42      brouard   371: imachMVC-setup: imachMVC.exe setup.iss
                    372:        touch setup.iss.in
                    373:        $(CP) imachMVC.exe imach.exe
                    374:        $(SETUPCOMP) /cc setup.iss
1.58      brouard   375:        $(CP) Output/$(TMPSETUPEXE) imachMVC-setup
1.42      brouard   376: 
                    377: # imachcyg-noreg-setup : imachcygopt imachcygopt.o setup.iss.in noreg-setup.iss $(TMPNOREGSETUPEXE)
                    378: imachMVC-noreg-setup: imachMVC.exe noreg-setup.iss
                    379:        touch setup.iss.in
                    380:        $(CP) imachMVC.exe imach.exe
                    381:        $(SETUPCOMP) /cc $(TMPNOREGSETUPSCRIPT)
                    382:        $(CP) Output/$(TMPNOREGSETUPEXE) imachcyg-noreg-setup
                    383: 
1.25      brouard   384: simach : simach.o 
                    385:        $(CC) $(LFLAGS) $(LGSL) -o simach simach.o
                    386: simach.o : simach.c 
1.30      brouard   387:        $(CC) $(CFLAGS) -DGSL -c simach.c
1.25      brouard   388: 
1.56      brouard   389: imachtest: imachtest.o 
                    390:        $(CC) $(LFLAGS) -o imachtest imachtest.o
                    391: ifdef _macosx
                    392:        $(DSYMUTIL) imachtest
                    393: endif
                    394: 
                    395: imach: imach.o 
1.21      brouard   396:        $(CC) $(LFLAGS) -o imach imach.o
1.34      brouard   397: ifdef _macosx
                    398:        $(DSYMUTIL) imach
                    399: endif
                    400: 
1.21      brouard   401: imach.o : imach.c 
1.58      brouard   402:         $(CC) $(CFLAGS) $(CROSSCOMPILATION)  -c imach.c
                    403: #       $(CC) $(CFLAGS) $(CROSSCOMPILATION) -DDEBUGBRENT -c imach.c
1.56      brouard   404: 
                    405: imachtest.o : imach.c 
                    406:         $(CC) $(CFLAGS) $(CROSSCOMPILATION) -DPOWELLORIGINAL -DNRCORIGINAL -DINFINITYORIGINAL -DDEBUGBRENT -o imachtest.o -c imach.c
                    407: 
                    408: #       $(CC) $(CFLAGS) $(CROSSCOMPILATION)  -DFIXMNBRAK -o imachtest.o -c imach.c
1.32      brouard   409: 
1.42      brouard   410: # http://msdn.microsoft.com/en-us/library/abx4dbyh%28v=vs.100%29.aspx
                    411: imachcl: imach.c
                    412:        cl /O2 /MT /o imach.exe imach.c
                    413: 
1.32      brouard   414: imach097b : imach097b.o 
                    415:        $(CC) $(LFLAGS) -o imach097b imach097b.o
                    416: imach097b.o : imach097b.c 
                    417:        $(CC) $(CFLAGS) -DPOWELL -c imach097b.c
1.30      brouard   418: 
                    419: 
                    420: imachsimplified : imachsimplified.o 
                    421:        $(CC)  $(LFLAGSOPT) -o imachsimplified imachsimplified.o
                    422: imachsimplified.o : imachsimplified.c 
                    423:        $(CC) $(CFLAGSOPT) -DPOWELL -c imachsimplified.c
                    424: 
                    425: imachgsl : imachgsl.o 
1.46      brouard   426:        $(CC) -o imachgsl imach.o  $(LFLAGS) $(LGSL) 
1.30      brouard   427: imachgsl.o : imach.c 
                    428:        $(CC) $(CFLAGS) -DGSL $(IGSL) -c imach.c
1.21      brouard   429: 
1.47      brouard   430: imachNEWUOAopt : imachNEWUOAopt.o 
                    431:        $(CC) -o imachNEWUOAopt  imachNEWUOAopt.o  $(LFLAGS) -g $(LNLOPT) 
                    432: imachNEWUOAopt.o : imach.c 
                    433:        $(CC) $(CFLAGS) -g -DNLOPT $(INLOPT) -DNEWUOA -o  imachNEWUOAopt.o -c imach.c
                    434: 
                    435: imachBOBYQAopt : imachBOBYQAopt.o 
                    436:        $(CC) -o imachBOBYQAopt imachBOBYQAopt.o  $(LFLAGS) $(LNLOPT) 
                    437: imachBOBYQAopt.o : imach.c 
                    438:        $(CC) $(CFLAGS) -DNLOPT $(INLOPT) -DBOBYQA -o imachBOBYQAopt.o -c imach.c
                    439: 
1.46      brouard   440: 
1.21      brouard   441: imachopt : imachopt.o 
                    442:        $(CC) $(LFLAGSOPT) -o imachopt imachopt.o
1.62      brouard   443:        ln -f imachopt imach
1.49      brouard   444:        $(CP) imachopt Output/imachopt$(VERSION)-$(BINVERSION)
1.50      brouard   445:        $(CP) -f imach ../bin
1.49      brouard   446: ifdef _intel64onosx
                    447:        $(CP) imachopt Output/imachopt$(VERSION)-$(BINVERSION)
                    448: endif
1.42      brouard   449: ifdef _macosx
                    450:        $(STRIP) imach
                    451: endif
                    452: ifdef _linux32onosx
1.51      brouard   453:        (cd .. && $(TAR) jcvf src/Output/imach-Linux-$(VERSION)-$(BINVERSION).tar.bz2 bin html/doc/biaspar.imach html/doc/data1.txt)
1.42      brouard   454: endif
                    455: ifdef _linux64onosx
1.51      brouard   456:        (cd .. && $(TAR) jcvf src/Output/imach-Linux-$(VERSION)-$(BINVERSION).tar.bz2 bin html/doc/biaspar.imach html/doc/data1.txt)
1.42      brouard   457: endif
                    458: 
1.48      brouard   459: imachopt.o : imach.c
1.51      brouard   460:        $(CC) $(CFLAGSOPT) $(CROSSCOMPILATION) -o imachopt.o -c imach.c
1.45      brouard   461: #      $(CC) $(CFLAGSOPT) -DPOWELL -o imachopt.o -c imach.c
1.21      brouard   462: 
1.49      brouard   463: imachUB : imach32 imach64
                    464:        lipo -create -arch i386 imach_32 -arch x86_64 imach_64 -output imach$(VERSION)
                    465: 
                    466: 
                    467: #imachdmg : imachopt.o create-dmg applet IMaChInfo.plist.in IMaChPkgInfo.in IMaCh.icns main.scpt.in IMaCh-ecrandemarrage.rsrc TXT.rtf
1.36      brouard   468: imachdmg : imachopt.o create-dmg applet IMaChInfo.plist.in IMaChPkgInfo.in IMaCh.icns main.scpt.in IMaCh-ecrandemarrage.rsrc TXT.rtf
1.27      brouard   469:        $(CC) $(LFLAGSOPT) -o imach imachopt.o
1.37      brouard   470:        #hdiutil detach /Volumes/IMaCh\ $(VERSION)
1.36      brouard   471:        rm -rf imach$(VERSION).app
                    472:        mkdir -p imach$(VERSION).app
                    473:        mkdir -p imach$(VERSION).app/Contents
                    474:        mkdir -p imach$(VERSION).app/Contents/MacOS
                    475:        cp applet imach$(VERSION).app/Contents/MacOS
                    476:        mkdir -p imach$(VERSION).app/Contents/Resources
                    477:        mkdir -p imach$(VERSION).app/Contents/Resources/Scripts
                    478:        mkdir -p imach$(VERSION).app/Contents/Resources/bin
1.38      brouard   479:        mkdir -p imach$(VERSION).app/Contents/Resources/html
1.36      brouard   480:        cp imach imach$(VERSION).app/Contents/Resources/bin
1.37      brouard   481:        cp gnuplot_bin/gnuplot_2_6_5_OSX imach$(VERSION).app/Contents/Resources/bin/gnuplot
1.36      brouard   482:        mkdir -p imach$(VERSION).app/Contents/Resources/description.rtfd
                    483:        cp -p TXT.rtf imach$(VERSION).app/Contents/Resources/description.rtfd
                    484:        $(SED) -e "s/@VERSION@/$(VERSION)/g;" \
                    485:        IMaChInfo.plist.in  >imach$(VERSION).app/Contents/Info.plist
                    486:        cp -p IMaChPkgInfo.in  imach$(VERSION).app/Contents/PkgInfo
                    487:        cp -p IMaCh.icns  imach$(VERSION).app/Contents/Resources/applet.icns
                    488:        cp -r -p main.scpt.in imach$(VERSION).app/Contents/Resources/Scripts/main.scpt
                    489:        cp IMaCH-ecrandemarrage.rsrc imach$(VERSION).app/Contents/Resources/applet.rsrc
1.38      brouard   490:        cp ../html/doc/data1.txt  imach$(VERSION).app/Contents/Resources/html
                    491:        cp ../html/doc/biaspar.log  imach$(VERSION).app/Contents/Resources/html
                    492:        cp ../html/doc/biaspar.imach  imach$(VERSION).app/Contents/Resources/html
1.36      brouard   493:        rm -f imach$(VERSION).dmg
1.38      brouard   494:        ./createdmg3.sh --volname "IMaCh $(VERSION)" imach$(VERSION).dmg imach$(VERSION)
                    495:        mv  imach$(VERSION).dmg Output/
1.36      brouard   496: #      ./create-dmg --volname "IMaCh $(VERSION)" imach$(VERSION).dmg imach$(VERSION).app
1.38      brouard   497: #      ./createdmg2.sh --volname "IMaCh $(VERSION)" imach$(VERSION).dmg imach$(VERSION)
1.27      brouard   498: 
1.58      brouard   499: md5:
                    500:        ls Output/* | xargs md5sum
1.38      brouard   501: upload:
1.62      brouard   502:        rsync -v Output/IMaCh-0.98q4-icl-setup.exe brouard@henry.ined.fr:/home/euroreves/html/imach/Download
                    503:        rsync -v Output/imach0.98q4.dmg brouard@henry.ined.fr:/home/euroreves/html/imach/Download
                    504: #      rsync -v Output/* brouard@henry.ined.fr:/home/euroreves/html/imach/Download
1.27      brouard   505: 
1.44      brouard   506: imachcyg : imachcyg.o
                    507:        $(CC) $(LFLAGS) -o imach imachcyg.o
1.21      brouard   508: imachcyg.o : imach.c 
                    509:        $(CC) $(CFLAGS)  -c -o imachcyg.o imach.c
1.44      brouard   510: imachcygopt.exe : imachcygopt.o
                    511:        $(CC) $(LFLAGSOPT) -o imachcygopt.exe imachcygopt.o
1.21      brouard   512: imachcygopt.o : imach.c 
                    513:        $(CC) $(CFLAGSOPT) -c -o imachcygopt.o imach.c
                    514: 
                    515: imachw32.o : imach.c
                    516:        i386-mingw32-gcc -c imach.c -o imachw32.o
                    517: imach.exe : imachw32.o 
                    518:        i386-mingw32-gcc  -mwindows -o imach.exe -lm imachw32.o
                    519:        i386-mingw32-strip imach.exe
                    520: 
1.34      brouard   521: valgrind-test :  imach $(TESTFILE) 
                    522:        valgrind  --dsymutil=yes --leak-check=full --show-leak-kinds=all --track-origins=yes ./imach $(TESTFILE)
                    523: test:  imach $(TESTFILE) 
                    524:        gdb ./imach $(TESTFILE)
1.21      brouard   525: 
                    526: $(PARAM).htm: imach $(PARAM).imach data1.txt
                    527:        ./imach $(PARAM).imach
                    528: 
                    529: clean: 
                    530:        rm or$(PARAM).txt er$(PARAM).txt pijr$(PARAM).txt plr$(PARAM).txt \
                    531:        r$(PARAM).txt tr$(PARAM).txt vpl$(PARAM).txt pr$(PARAM).txt \
                    532:        vr$(PARAM).txt *.gif imach.exe imach.o
                    533: 
                    534: 

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