3 rm -f cygkms
*.dll libkms
*.dll vlmcsd-
* vlmcs-
* vlmcsdmulti-
* *_all.
* vlmcsd.exe vlmcs.exe vlmcsdmulti.exe
2> /dev
/null
7 NUMCPU
=`cat /proc/cpuinfo | grep "processor" | wc -l`
9 CF
="-Wno-missing-braces -fno-common -fno-exceptions -fno-non-call-exceptions -fno-stack-protector -fmerge-all-constants -fno-unwind-tables -fno-asynchronous-unwind-tables -pipe"
10 CFMSRPC
="-Wno-missing-braces -Wno-unused-variable $CF" # -fno-common -fno-stack-protector -fmerge-all-constants -pipe"
12 PF64
="-mpreferred-stack-boundary=4 -march=nocona -mtune=generic"
13 LFCYG32
="-fwhole-program -Wl,--nxcompat,--dynamicbase,--tsaware,--large-address-aware"
14 LFWIN32
="-fwhole-program -lws2_32 -Wl,--nxcompat,--dynamicbase,--tsaware,--large-address-aware"
15 LFCYG64
="-fwhole-program -Wl,--nxcompat,--dynamicbase,--tsaware"
16 LFWIN64
="-fwhole-program -lws2_32 -Wl,--nxcompat,--dynamicbase,--tsaware"
18 MAKEFLAGS
="-j$NUMCPU -B"
19 REUSEFLAGS
="-j$NUMCPU"
21 make $MAKEFLAGS cygkms32.dll FEATURES
=minimum THREADS
=1 DLL_NAME
=cygkms32.dll DNS_PARSER
=internal CC
=i686-pc-cygwin-gcc.exe CFLAGS
="$CF -flto=jobserver -fvisibility=hidden" PLATFORMFLAGS
="$PF32" LDFLAGS
="$LFCYG32"
22 make $MAKEFLAGS cygkms64.dll FEATURES
=minimum THREADS
=1 DLL_NAME
=cygkms64.dll DNS_PARSER
=internal CC
=x86_64-pc-cygwin-gcc.exe CFLAGS
="$CF -flto=jobserver -fvisibility=hidden" PLATFORMFLAGS
="$PF64" LDFLAGS
="$LFCYG64"
23 make $MAKEFLAGS all vlmcsdmulti-cygwin-x86 THREADS
=1 DNS_PARSER
=internal CLIENT_NAME
=vlmcs-cygwin-x86 PROGRAM_NAME
=vlmcsd-cygwin-x86 MULTI_NAME
=vlmcsdmulti-cygwin-x86 CC
=i686-pc-cygwin-gcc.exe CFLAGS
="$CF" PLATFORMFLAGS
="$PF32" LDFLAGS
="$LFCYG32"
24 make $MAKEFLAGS all vlmcsdmulti-cygwin-x64 THREADS
=1 DNS_PARSER
=internal CLIENT_NAME
=vlmcs-cygwin-x64 PROGRAM_NAME
=vlmcsd-cygwin-x64 MULTI_NAME
=vlmcsdmulti-cygwin-x64 CC
=x86_64-pc-cygwin-gcc.exe CFLAGS
="$CF" PLATFORMFLAGS
="$PF64" LDFLAGS
="$LFCYG64"
25 make $MAKEFLAGS MSRPC
=1 THREADS
=1 DNS_PARSER
=internal CLIENT_NAME
=vlmcs-cygwin-msrpc-x86 PROGRAM_NAME
=vlmcsd-cygwin-msrpc-x86 MULTI_NAME
=vlmcsdmulti-cygwin-msrpc-x86 CC
=i686-pc-cygwin-gcc.exe CFLAGS
="$CF -fasynchronous-unwind-tables" PLATFORMFLAGS
="$PF32" LDFLAGS
="$LFCYG32"
26 make $MAKEFLAGS MSRPC
=1 THREADS
=1 DNS_PARSER
=internal CLIENT_NAME
=vlmcs-cygwin-msrpc-x64 PROGRAM_NAME
=vlmcsd-cygwin-msrpc-x64 MULTI_NAME
=vlmcsdmulti-cygwin-msrpc-x64 CC
=x86_64-pc-cygwin-gcc.exe CFLAGS
="$CFMSRPC" PLATFORMFLAGS
="$PF64" LDFLAGS
="$LFCYG64"
28 make $MAKEFLAGS vlmcsdmulti-cygwin-msrpc-x64 MSRPC
=1 THREADS
=1 DNS_PARSER
=internal MULTI_NAME
=vlmcsdmulti-cygwin-msrpc-x64 CC
=x86_64-pc-cygwin-gcc.exe CFLAGS
="$CFMSRPC -flto=jobserver" PLATFORMFLAGS
="$PF64" LDFLAGS
="$LFCYG64"
29 make $MAKEFLAGS vlmcsdmulti-cygwin-msrpc-x86 MSRPC
=1 THREADS
=1 DNS_PARSER
=internal MULTI_NAME
=vlmcsdmulti-cygwin-msrpc-x86 CC
=i686-pc-cygwin-gcc.exe CFLAGS
="$CFMSRPC -flto=jobserver" PLATFORMFLAGS
="$PF32" LDFLAGS
="$LFCYG32"
32 make $MAKEFLAGS THREADS
=1 MSRPC
=1 DNS_PARSER
=internal CLIENT_NAME
=vlmcs-cygwin-msrpc-x86-openssl-EXPERIMENTAL CRYPTO
=openssl_with_aes PROGRAM_NAME
=vlmcsd-cygwin-x86-openssl-EXPERIMENTAL CC
=i686-pc-cygwin-gcc.exe CFLAGS
="$CFMSRPC" PLATFORMFLAGS
="$PF32" LDFLAGS
="$LFCYG32"
33 make $MAKEFLAGS THREADS
=1 MSRPC
=1 DNS_PARSER
=internal CLIENT_NAME
=vlmcs-cygwin-msrpc-x64-openssl-EXPERIMENTAL CRYPTO
=openssl_with_aes PROGRAM_NAME
=vlmcsd-cygwin-x64-openssl-EXPERIMENTAL CC
=x86_64-pc-cygwin-gcc.exe CFLAGS
="$CFMSRPC" PLATFORMFLAGS
="$PF64" LDFLAGS
="$LFCYG64"
37 make $MAKEFLAGS libkms32.dll CRYPTO
=windows FEATURES
=minimum THREADS
=1 DLL_NAME
=libkms32.dll CC
=i686-w64-MingW32-gcc.exe CFLAGS
="$CF -flto=jobserver -fvisibility=hidden" PLATFORMFLAGS
="$PF32" LDFLAGS
="-static-libgcc $LFWIN32"
38 make $MAKEFLAGS libkms64.dll CRYPTO
=windows FEATURES
=minimum THREADS
=1 DLL_NAME
=libkms64.dll CC
=x86_64-w64-MingW32-gcc.exe CFLAGS
="$CF -flto=jobserver -fvisibility=hidden" PLATFORMFLAGS
="$PF64" LDFLAGS
="-static-libgcc $LFWIN64"
39 make $MAKEFLAGS all vlmcsdmulti-Windows-x86 THREADS
=1 CRYPTO
=windows CLIENT_NAME
=vlmcs-Windows-x86 PROGRAM_NAME
=vlmcsd-Windows-x86 MULTI_NAME
=vlmcsdmulti-Windows-x86 CC
=i686-w64-MingW32-gcc.exe CFLAGS
="$CF" PLATFORMFLAGS
="$PF32" LDFLAGS
="$LFWIN32"
40 make $MAKEFLAGS all vlmcsdmulti-Windows-x64 THREADS
=1 CRYPTO
=windows CLIENT_NAME
=vlmcs-Windows-x64 PROGRAM_NAME
=vlmcsd-Windows-x64 MULTI_NAME
=vlmcsdmulti-Windows-x64 CC
=x86_64-w64-MingW32-gcc.exe CFLAGS
="$CF" PLATFORMFLAGS
="$PF64" LDFLAGS
="$LFWIN64"
41 make -Bj MSRPC
=1 CRYPTO
=windows CLIENT_NAME
=vlmcs-Windows-msrpc-x86 PROGRAM_NAME
=vlmcsd-Windows-msrpc-x86 MULTI_NAME
=vlmcsdmulti-Windows-msrpc-x86 CC
=i686-w64-MingW32-gcc.exe CFLAGS
="$CFMSRPC" PLATFORMFLAGS
="$PF32" LDFLAGS
="-Wl,--nxcompat,--dynamicbase,--tsaware,--large-address-aware"
42 make $MAKEFLAGS THREADS
=1 MSRPC
=1 CRYPTO
=windows CLIENT_NAME
=vlmcs-Windows-msrpc-x64 PROGRAM_NAME
=vlmcsd-Windows-msrpc-x64 MULTI_NAME
=vlmcsdmulti-Windows-msrpc-x64 CC
=x86_64-w64-MingW32-gcc.exe CFLAGS
="$CFMSRPC" PLATFORMFLAGS
="$PF64" LDFLAGS
="$LFCYG64"
44 make $MAKEFLAGS vlmcsdmulti-Windows-msrpc-x86 THREADS
=1 MSRPC
=1 CRYPTO
=windows MULTI_NAME
=vlmcsdmulti-Windows-msrpc-x86 CC
=i686-w64-MingW32-gcc.exe CFLAGS
="$CFMSRPC" PLATFORMFLAGS
="$PF32" LDFLAGS
="-Wl,--nxcompat,--dynamicbase,--tsaware,--large-address-aware"
45 make $MAKEFLAGS vlmcsdmulti-Windows-msrpc-x64 THREADS
=1 MSRPC
=1 CRYPTO
=windows MULTI_NAME
=vlmcsdmulti-Windows-msrpc-x64 CC
=x86_64-w64-MingW32-gcc.exe CFLAGS
="$CFMSRPC" PLATFORMFLAGS
="$PF64" LDFLAGS
="$LFCYG64"
48 rm -f *_all.
* *.o
2> /dev
/null
&
51 echo "Installing binaries"
53 cp -p vlmcs-cygwin-x64.exe
/usr
/local
/bin
/vlmcs
&
54 cp -p vlmcsd-cygwin-x64.exe
/usr
/local
/bin
/vlmcsd
&
55 cp -p cygkms64.dll
/usr
/local
/bin
/cygkms.dll
&
57 cp -p libkms32.dll
/cygdrive
/c
/nttools
/x86
&
58 cp -p libkms64.dll
/cygdrive
/c
/nttools
/x64
&
59 cp -p vlmcsdmulti-Windows-x86.exe
/cygdrive
/c
/nttools
/x86
/vlmcsdmulti.exe
61 cmd
/C mklink c
:\\nttools
\\x86
\\vlmcsd.exe vlmcsdmulti.exe
2> /dev
/null
&
62 cmd
/C mklink c
:\\nttools
\\x86
\\vlmcs.exe vlmcsdmulti.exe
2> /dev
/null
&
64 echo "Installing man pages"
66 mkdir
-p /usr
/share
/man
/man8
67 mkdir
-p /usr
/share
/man
/man1
68 mkdir
-p /usr
/share
/man
/man7
69 mkdir
-p /usr
/share
/man
/man5
71 cp -p vlmcsd
.7 /usr
/share
/man
/man7
72 cp -p vlmcsd
.8 /usr
/share
/man
/man8
73 cp -p vlmcsd.ini
.5 /usr
/share
/man
/man5
74 cp -p vlmcs
.1 vlmcsdmulti
.1 /usr
/share
/man
/man1
76 bzip2 -f /usr
/share
/man
/man
5/vlmcsd.ini
.5 /usr
/share
/man
/man
7/vlmcsd
.7 /usr
/share
/man
/man
8/vlmcsd
.8 /usr
/share
/man
/man
1/vlmcs
.1 /usr
/share
/man
/man
1/vlmcsdmulti
.1 &
78 # Copy stuff to distribution server
79 scp
-p vlmcsd-
* vlmcs-
* vlmcsdmulti-
* *.dll root@ubuntu64
:x
/binaries
/Windows
/intel