source: git/make_release@ 4ee5fbf

RELEASE/1.0 RELEASE/1.1 RELEASE/1.2 debug-ci debug-ci-sanitisers faster-cavernlog log-select main stereo stereo-2025 walls-data walls-data-hanging-as-warning warn-only-for-hanging-survey
Last change on this file since 4ee5fbf was f30265a0, checked in by Olly Betts <olly@…>, 25 years ago

Can now select which bits to build...

git-svn-id: file:///home/survex-svn/survex/trunk@913 4b37db11-9a0c-4f06-9ece-9ab7cdaee568

  • Property mode set to 100755
File size: 3.5 KB
Line 
1#! /bin/sh
2release=yes
3if test x"$1" = x-t ; then
4 release=
5 shift
6fi
7build=${@-src rpm deb doc alien djgpp mingw}
8if test x"$release" = xyes ; then
9 if ! cvs diff > /dev/null 2> /dev/null ; then
10 echo There are changes not checked into CVS - please rectify
11 exit 1
12 fi
13 # Update ChangeLog
14 CVS2CL=./cvs2cl.pl
15 if ! test -x $CVS2CL ; then
16 CVS2CL=../cvs2cl/cvs2cl.pl
17 fi
18 if ! $CVS2CL 2> /dev/null ; then
19 echo Failed to update ChangeLog from CVS
20 exit 1
21 fi
22fi
23if test -f Makefile ; then
24 if ! make distclean ; then
25 echo make distclean failed
26 exit 1
27 fi
28fi
29aclocal
30autoheader
31automake -a
32autoconf
33if ! ./configure ; then
34 echo configure failed
35 exit 1
36fi
37# make distcheck fails - cvs version of automake doesn't clean up all the
38# files it creates... (FIXME: change to distcheck once automake fixed)
39if ! make dist ; then
40 echo make dist failed
41 exit 1
42fi
43if test x"$release" = xyes && expr "$build" : '.*\<rpm\>'; then
44 if rpm --version > /dev/null 2> /dev/null ; then
45 if ! make rpm ; then
46 echo make rpm failed
47 exit 1
48 fi
49 else
50 echo rpm not installed - skipping rpm generation
51 fi
52fi
53if test x"$release" = xyes && expr "$build" : '.*\<deb\>'; then
54 if ! make debian ; then
55 echo make debian failed
56 exit 1
57 fi
58fi
59if test x"$release" = xyes && expr "$build" : '.*\<doc\>'; then
60 if ! make dos_doc_zip ; then
61 echo make dos_doc_zip failed
62 exit 1
63 fi
64 if ! make riscos_doc_zip ; then
65 echo make riscos_doc_zip failed
66 exit 1
67 fi
68fi
69if expr "$build" : '.*\<alien\>'; then
70 if ! make alien_src_zip ; then
71 echo make alien_src_zip failed
72 exit 1
73 fi
74fi
75if ! make distclean ; then
76 echo make distclean failed
77 exit 1
78fi
79if expr "$build" : '.*\<djgpp\>'; then
80 SAVE_PATH="$PATH"
81 # for building on mrs30
82 if test -d /opt/crosstools/i386-pc-msdosdjgpp ; then
83 PATH=/opt/crosstools/i386-pc-msdosdjgpp/bin:/opt/crosstools/bin:$PATH
84 fi
85 if ! env LDFLAGS=-s STRIP=echo CAVEROT=caverot.exe \
86 CRLIB=-lalleg CROBJX=dosrot.o ./configure --with-x=no --disable-aven; then
87 echo djgpp configure failed
88 exit 1
89 fi
90 if ! make ; then
91 echo djgpp make failed
92 exit 1
93 fi
94 if ! make djgpp_zip ; then
95 echo djgpp make djgpp_zip failed
96 exit 1
97 fi
98 if ! make distclean ; then
99 echo make distclean failed
100 exit 1
101 fi
102 PATH="$SAVE_PATH"
103fi
104if expr "$build" : '.*\<mingw\>'; then
105 SAVE_PATH="$PATH"
106 if test -d /usr/local/cross-tools/i386-mingw32msvc/bin ; then
107 # binaries from http://www.devolution.com/~slouken/SDL/Xmingw32/
108 PATH=/usr/local/cross-tools/bin:/usr/local/cross-tools/i386-mingw32msvc/bin:$PATH
109 else
110 if test -d /usr/i586-mingw32msvc/bin ; then
111 # debian mingw32 package
112 PATH=/usr/i586-mingw32msvc/bin:$PATH
113 CC=/usr/bin/i586-mingw32msvc-gcc
114 export CC
115 CXX=/usr/bin/i586-mingw32msvc-g++
116 export CXX
117 else
118 # variant of debian mingw32 package?
119 PATH=/usr/i386-mingw32msvc/bin:$PATH
120 CC=/usr/bin/i386-mingw32msvc-gcc
121 export CC
122 CXX=/usr/bin/i386-mingw32msvc-g++
123 export CXX
124 fi
125 fi
126 if ! env LDFLAGS=-s CAVEROT= ./configure --with-x=no --with-wxconfig=`pwd`/mingw_extras/wxmsw-config ; then
127 echo mingw configure failed
128 exit 1
129 fi
130 if ! make ; then
131 echo mingw make failed
132 exit 1
133 fi
134 if ! make mingw_iss ; then
135 echo mingw make mingw_iss failed
136 exit 1
137 fi
138 if ! make distclean ; then
139 echo make distclean failed
140 exit 1
141 fi
142 PATH="$SAVE_PATH"
143 CC=
144 CXX=
145fi
Note: See TracBrowser for help on using the repository browser.