Archive: NSIS 2.01 compiling on RH9


NSIS 2.01 compiling on RH9
Is there a make file for unix ? Looks like
the default one is for win32.

[root@dual Source]# make
make -C exehead
make[1]: Entering directory `/export/tmp/Source/exehead'
mingw32-gcc -c -DEXEHEAD -DWIN32_LEAN_AND_MEAN -DZEXPORT=__stdcall -DLZMACALL=__fastcall -Wall -Os -DNSIS_COMPRESS_USE_ZLIB bgbg.c -o Release-zlib/bgbg.o
make[1]: mingw32-gcc: Command not found
make[1]: *** [Release-zlib/bgbg.o] Error 127
make[1]: Leaving directory `/export/tmp/Source/exehead'
make: *** [exehead] Error 2
[root@dual Source]# uname -a
Linux dual 2.4.20-8smp #1 SMP Thu Mar 13 17:45:54 EST 2003 i686 i686 i386 GNU/Linux
[root@dual Source]#


The documentation states:

When building with precompiled exehead .h files, you should set the USE_PRECOMPILED_EXEHEADS flag to 1 on the make command line. This forces the makefile to skip the compilation process of the exeheads, even if the .h files seem outdated or if dependencies are missing.

make USE_PRECOMPILED_EXEHEADS=1
Taken from appendix D section 1: Compiling NSIS Sources.

Since you don't have a cross compiler and using the precompiled exheads is better anyway, you should use that flag.

Thanks for the reply.
1. I instaled the following mingw rpm packages.
[root@dual Source]# rpm -qa |grep mingw
mingw-runtime-3.2-7hl
mingw-w32api-2.5-7hl
binutils-mingw-2.15.90-4hl
gcc-mingw-3.2.3-7hl
[root@dual Source]#
2. The compile went smooth

[root@dual Source]# make
make -C exehead
make[1]: Entering directory `/export/tmp/Source/exehead'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/export/tmp/Source/exehead'
[root@dual Source]# ls
7zGuids.o DialogTemplate.o Plugins.o
7zip exedata.cpp RangeCoderBit.o
afxres.h exedata.h ResourceEditor.cpp
Alloc.o exedata.o ResourceEditor.h
blocksort.o exehead ResourceEditor.o
build.cpp huffman.o ResourceVersionInfo.cpp
build.h lang.cpp ResourceVersionInfo.h
build.o lang.h ResourceVersionInfo.o
bzip2 lang.o script.cpp
bzlib.o lineparse.h script.o
cbzip2.h LZInWindow.o ShConstants.h
clzma.h LZMAEncoder.o strlist.h
compress.o Makefile tokens.cpp
compressor.h makenssi.cpp tokens.h
crc32.c makenssi.dsp tokens.o
crc32.o makenssi.dsw trees.o
CRC.o makenssi.o uservars.h
czlib.h OutBuffer.o util.cpp
deflate.o Platform.h util.h
DialogTemplate.cpp Plugins.cpp util.o
DialogTemplate.h Plugins.h zlib
[root@dual Source]#

3. Now the question,Aren't they suppost to be "exe" or " linux binary"of makensis generated ?

[root@dual Source]# find . -type f -name "makenssi*" -print;find . -type f -name "*.exe" -print
./makenssi.cpp
./makenssi.dsp
./makenssi.dsw
./makenssi.o
./exehead/bin2h.exe
./exehead/Release-zlib/exehead_zlib.exe
./exehead/Release-bzip2/exehead_bzip2.exe
./exehead/Release-lzma/exehead_lzma.exe
[root@dual Source]#


Oops, my bad. it is at ../makensis.
PS. can someone modify the makefile follow the common
practice. like
make [all]
make install

Thanks

<snip>
g++ -Wall -O3 -DCOMPRESS_MF_BT -c -o util.o util.cpp
gcc -Wall -s -Wl,-Map,../makensis.map -o ../makensis 7zGuids.o blocksort.o build.o bzlib.o compress.o CRC.o crc32.o deflate.o DialogTemplate.o exedata.o huffman.o lang.o LZInWindow.o LZMAEncoder.o Alloc.o makenssi.o OutBuffer.o Plugins.o RangeCoderBit.o ResourceEditor.o ResourceVersionInfo.o script.o tokens.o trees.o util.o -lstdc++ -lpthread
[root@dual Source]# ls ../makensis
../makensis
[root@dual Source]#


There is an install script called install.sh in the root directory of the NSIS package.