From 33e9fbba32f65393e8162cc45695dab0b3512975 Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Fri, 24 Dec 2010 10:41:09 +0900 Subject: [PATCH] Win32 packaging improvements. --- tools/build_scripts/qf-release | 6 ++-- tools/build_scripts/qf-win32.py | 61 +++++++++++++++++++++++---------- 2 files changed, 47 insertions(+), 20 deletions(-) diff --git a/tools/build_scripts/qf-release b/tools/build_scripts/qf-release index 4b2611095..58766cf6d 100755 --- a/tools/build_scripts/qf-release +++ b/tools/build_scripts/qf-release @@ -7,6 +7,7 @@ set -e PATH=/usr/local/bin:$PATH MINGW=~/src/mingw/mingw-cross-env-2.18/usr/i686-pc-mingw32 RELEASE=~/release +export QFSMP=${QFSMP--j4} pref=`dirname $0` if test $# -lt 1; then @@ -87,7 +88,7 @@ mkdir -p linux.o qf-win32.o rm -rf $DIR tar zxvf ../${DIR}.tar.gz cd $DIR - QFSMP=-j3 dpkg-buildpackage -rfakeroot -us -uc + dpkg-buildpackage -rfakeroot -us -uc rm -rf $DIR cd .. mv q*.[a-z]* $RELEASE @@ -109,10 +110,11 @@ if test $do_win32 -eq 1; then ./cross-configure.sh \ --disable-debug --disable-shared \ --program-prefix= - ../tools/cross/cross-make.sh -j3 \ + ../tools/cross/cross-make.sh $QFSMP \ prefix=${qf_win32_dir} \ exec_prefix=${qf_win32_dir} \ pkgdatadir=${qf_win32_dir} \ + man1dir=${qf_win32_dir} \ install $MINGW/bin/strip --strip-unneeded "$qf_win32"/bin/*.exe ../tools/build_scripts/qf-win32.py "$ver-win32" quakeforge "$qf_win32" diff --git a/tools/build_scripts/qf-win32.py b/tools/build_scripts/qf-win32.py index 3c1df61d6..0590b7a54 100755 --- a/tools/build_scripts/qf-win32.py +++ b/tools/build_scripts/qf-win32.py @@ -23,6 +23,7 @@ server = [ dir + "bin/nq-server.exe", dir + "bin/qw-master.exe", dir + "bin/qw-server.exe", + dir + "bin/qtv.exe", ] client_wgl = [ @@ -31,6 +32,7 @@ client_wgl = [ dir + "bin/nq-wgl.exe", dir + "bin/qw-client-wgl.exe", dir + "menu.dat.gz", + dir + "menu.plist", ] client_sgl = [ @@ -39,6 +41,7 @@ client_sgl = [ dir + "bin/nq-sgl.exe", dir + "bin/qw-client-sgl.exe", dir + "menu.dat.gz", + dir + "menu.plist", ] client_sdl = [ @@ -47,6 +50,7 @@ client_sdl = [ dir + "bin/nq-sdl.exe", dir + "bin/qw-client-sdl.exe", dir + "menu.dat.gz", + dir + "menu.plist", ] client_sdl32 = [ @@ -55,6 +59,7 @@ client_sdl32 = [ dir + "bin/nq-sdl32.exe", dir + "bin/qw-client-sdl32.exe", dir + "menu.dat.gz", + dir + "menu.plist", ] tools = [ @@ -63,7 +68,6 @@ tools = [ dir + "bin/bsp2img.exe", dir + "bin/pak.exe", dir + "bin/qfbsp.exe", - dir + "bin/qfcc.exe", dir + "bin/qflight.exe", dir + "bin/qfmodelgen.exe", dir + "bin/qfprogs.exe", @@ -73,25 +77,46 @@ tools = [ dir + "bin/zpak", ] +qfcc = [ + dir, + dir + "bin", + dir + "bin/qfcc.exe", + dir + "bin/qfpreqcc", + dir + "qfcc.1", + dir + "qfcc.pc", +] +qfcc_r = [ + dir + "include/QF/ruamoko", + dir + "lib/ruamoko", +] + devel = [ + dir, + dir "quakeforge.pc", +] + +devel_r = [ dir + "include", dir + "lib", ] -print "zip -9 " + prefix + "-server" + version + ".zip " + " ".join (server) -system ("zip -9 " + prefix + "-server" + version + ".zip " + " ".join (server)) -print "zip -9 " + prefix + "-client-wgl" + version + ".zip " + " ".join (client_wgl) -system ("zip -9 " + prefix + "-client-wgl" + version + ".zip " + " ".join (client_wgl)) -print "zip -9 " + prefix + "-client-sgl" + version + ".zip " + " ".join (client_sgl) -system ("zip -9 " + prefix + "-client-sgl" + version + ".zip " + " ".join (client_sgl)) -print "zip -9 " + prefix + "-client-sdl" + version + ".zip " + " ".join (client_sdl) -system ("zip -9 " + prefix + "-client-sdl" + version + ".zip " + " ".join (client_sdl)) -print "zip -9 " + prefix + "-client-sdl32" + version + ".zip " + " ".join (client_sdl32) -system ("zip -9 " + prefix + "-client-sdl32" + version + ".zip " + " ".join (client_sdl32)) -print "zip -9 " + prefix + "-tools" + version + ".zip " + " ".join (tools) -system ("zip -9 " + prefix + "-tools" + version + ".zip " + " ".join (tools)) -if dir: - print "zip -9 " + prefix + "-devel" + version + ".zip " + dir - system ("zip -9 " + prefix + "-devel" + version + ".zip " + dir) -print "zip -r9 " + prefix + "-devel" + version + ".zip " + " ".join (devel) -system ("zip -r9 " + prefix + "-devel" + version + ".zip " + " ".join (devel)) +packages = [ + (prefix + "-" + "server", server), + (prefix + "-" + "client-wgl", client-wgl), + (prefix + "-" + "client-sgl", client-sgl), + (prefix + "-" + "client-sdl", client-sdl), + (prefix + "-" + "client-sdl32", client-sdl32), + (prefix + "-" + "tools", tools), + (prefix + "-" + "devel", devel), + (prefix + "-" + "devel", devel_r, "-r"), + ("qfcc", qfcc), + ("qfcc", qfcc_r, "-r"), +] + +for p in packages: + opt = "" + if len (p) >= 3: + opt = p[3] + " " + cmd = "zip -9 " + opt + p[0] + version + ".zip " + " ".join (p[1]) + print cmd + system (cmd)