Page 1 of 1

Compiling my own installer

Posted: 06 Mar 2008, 06:03
by Uber Schwarz
How do I compile my own installer from the daily trunk snapshot in the tar.gz file? I have the NSIS program.

Re: Compiling my own installer

Posted: 06 Mar 2008, 13:43
by DevUrandom
On an autotools enabled system you can do:

Code: Select all

./autogen.sh
./configure --enable-data --enable-installer \
  --with-installer-extdir=\"${PREFIX}/bin\" --with-installer-version=\"2.0.999.999\" \
  --with-distributor="Uber Schwarz" \
  --prefix="${PREFIX}" \
  LIBS='-lintl -liconv -lz -lfreetype -lfontconfig -lexpat' \
  CFLAGS="-pipe -m32 -march=i686 -O2 -g" \
  CXXFLAGS="-pipe -m32 -march=i686 -O2 -g" \
  CPPFLAGS="-I${PREFIX}/include" \
  LDFLAGS="-L${PREFIX}/lib"
make -j4
(You need to set PREFIX to the place of the devpkg.)
(Having to specify LIBS is not a bug, but a result from the devpkg containing just static libs, which have no dependency information.)

Re: Compiling my own installer

Posted: 08 Mar 2008, 08:22
by Buginator
DevUrandom wrote: On an autotools enabled system you can do:

Code: Select all

./autogen.sh
./configure --enable-data --enable-installer \
  --with-installer-extdir="${PREFIX}/bin" --with-installer-version="2.0.999.999" \
  --with-distributor="Uber Schwarz" \
  --prefix="${PREFIX}" \
  LIBS='-lintl -liconv -lz -lfreetype -lfontconfig -lexpat' \
  CFLAGS="-pipe -m32 -march=i686 -O2 -g" \
  CXXFLAGS="-pipe -m32 -march=i686 -O2 -g" \
  CPPFLAGS="-I${PREFIX}/include" \
  LDFLAGS="-L${PREFIX}/lib"
make -j4
(You need to set PREFIX to the place of the devpkg.)
(Having to specify LIBS is not a bug, but a result from the devpkg containing just static libs, which have no dependency information.)
And just so you know, some of those flags don't work on all build systems, so you may need to edit that also.

Re: Compiling my own installer

Posted: 08 Mar 2008, 13:13
by DevUrandom
Buginator wrote: And just so you know, some of those flags don't work on all build systems, so you may need to edit that also.
Some don't? The ones I posted are just those which we provide for Warzone, nothing which should depend on the buildsystem.

Btw, I see I forgot the crosscompilation flags...
So here you have it complete:

Code: Select all

./autogen.sh
./configure --target=${MINGW32} --host=${MINGW32} --enable-static --disable-shared \
  --enable-data --enable-installer \
  --with-installer-extdir="${PREFIX}/bin" --with-installer-version="2.0.999.999" \
  --with-distributor="Uber Schwarz" \
  --prefix="${PREFIX}" \
  LIBS='-lintl -liconv -lz -lfreetype -lfontconfig -lexpat' \
  CFLAGS="-pipe -m32 -march=i686 -O2 -g" \
  CXXFLAGS="-pipe -m32 -march=i686 -O2 -g" \
  CPPFLAGS="-I${PREFIX}/include" \
  LDFLAGS="-L${PREFIX}/lib"
make -j4
You need to set PREFIX to the place of the devpkg.
You need to set MINGW32 to the arch of your crosscompiler. For Debian this is "i386-pc-mingw32msvc", I think.