source: git/make_release@ ed08adf

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 ed08adf was f78ad72, checked in by Olly Betts <olly@…>, 25 years ago

Fixed configure for DJGPP (and other places where we don't use a C++
compiler).

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

  • Property mode set to 100755
File size: 4.1 KB
RevLine 
[d7acd89]1#! /bin/sh
[ae1309f]2
3rel=yes
[e66be9a]4if test x"$1" = x-t ; then
[ae1309f]5 rel=
[f30265a0]6 shift
[d7acd89]7fi
[ae1309f]8mk=${@-src rpm deb doc alien djgpp mingw}
9if test x"$rel" = xyes ; then
[f6a3719]10 # Update debian changelog entry if necessary
11 # If it does get updated, then the next check will fail...
12 ./update-debcl.pl
13 # Check everything is checked into CVS
[e66be9a]14 if ! cvs diff > /dev/null 2> /dev/null ; then
15 echo There are changes not checked into CVS - please rectify
16 exit 1
17 fi
18 # Update ChangeLog
[bfa0e10]19 CVS2CL=./cvs2cl.pl
20 if ! test -x $CVS2CL ; then
21 CVS2CL=../cvs2cl/cvs2cl.pl
22 fi
23 if ! $CVS2CL 2> /dev/null ; then
[e66be9a]24 echo Failed to update ChangeLog from CVS
25 exit 1
26 fi
[fd51dc3]27fi
28if test -f Makefile ; then
29 if ! make distclean ; then
30 echo make distclean failed
31 exit 1
32 fi
33fi
[ae1309f]34if test x"$rel" = xyes ; then
[38226ad]35 rm -f config.guess.new config.sub.new
[70bfbfd]36 perl -e '-M "config.guess" && -M "config.sub" && exit 1' &&\
37 wget ftp://ftp.gnu.org/gnu/config/config.guess -O config.guess.new &&\
[38226ad]38 wget ftp://ftp.gnu.org/gnu/config/config.sub -O config.sub.new &&\
39 mv config.guess.new config.guess && mv config.sub.new config.sub
[bd7120b]40fi
[dc459c9]41aclocal
42autoheader
43automake -a
44autoconf
[eea518c]45if ! ./configure ; then
46 echo configure failed
47 exit 1
48fi
[f78ad72]49if test x"$rel" = xyes ; then
50 if ! make distcheck ; then
51 echo make distcheck failed
52 exit 1
53 fi
54else
55 if ! make dist ; then
56 echo make dist failed
57 exit 1
58 fi
[e719df1]59fi
[ae1309f]60if test x"$rel" = xyes && expr "$mk" : '.*\<rpm\>' || test x"$mk" = xrpm ; then
[7eb8d4a]61 if rpm --version > /dev/null 2> /dev/null ; then
62 if ! make rpm ; then
63 echo make rpm failed
64 exit 1
65 fi
66 else
67 echo rpm not installed - skipping rpm generation
[e66be9a]68 fi
[f30265a0]69fi
[ae1309f]70if test x"$rel" = xyes && expr "$mk" : '.*\<deb\>' || test x"$mk" = xdeb ; then
[9cfb427]71 if ! make debian ; then
[7eb8d4a]72 echo make debian failed
[9cfb427]73 exit 1
74 fi
[f30265a0]75fi
[ae1309f]76if test x"$rel" = xyes && expr "$mk" : '.*\<doc\>' || test x"$mk" = xdoc ; then
[e68fccf]77 if ! make dos_doc_exe ; then
78 echo make dos_doc_exe failed
[e66be9a]79 exit 1
80 fi
[21a0009]81 if ! make riscos_doc_zip ; then
82 echo make riscos_doc_zip failed
83 exit 1
84 fi
[fd51dc3]85fi
[ae1309f]86if expr "$mk" : '.*\<alien\>'; then
[f30265a0]87 if ! make alien_src_zip ; then
88 echo make alien_src_zip failed
89 exit 1
90 fi
[4208811]91fi
[9324b2d]92if ! make distclean ; then
93 echo make distclean failed
94 exit 1
95fi
[ae1309f]96if expr "$mk" : '.*\<djgpp\>'; then
[f30265a0]97 SAVE_PATH="$PATH"
98 # for building on mrs30
99 if test -d /opt/crosstools/i386-pc-msdosdjgpp ; then
100 PATH=/opt/crosstools/i386-pc-msdosdjgpp/bin:/opt/crosstools/bin:$PATH
101 fi
102 if ! env LDFLAGS=-s STRIP=echo CAVEROT=caverot.exe \
103 CRLIB=-lalleg CROBJX=dosrot.o ./configure --with-x=no --disable-aven; then
104 echo djgpp configure failed
105 exit 1
106 fi
107 if ! make ; then
108 echo djgpp make failed
109 exit 1
110 fi
[e68fccf]111 if ! make djgpp_exe ; then
112 echo djgpp make djgpp_exe failed
[e66be9a]113 exit 1
114 fi
[f30265a0]115 if ! make distclean ; then
116 echo make distclean failed
117 exit 1
118 fi
119 PATH="$SAVE_PATH"
[fd51dc3]120fi
[ae1309f]121if expr "$mk" : '.*\<mingw\>'; then
[f30265a0]122 SAVE_PATH="$PATH"
123 if test -d /usr/local/cross-tools/i386-mingw32msvc/bin ; then
124 # binaries from http://www.devolution.com/~slouken/SDL/Xmingw32/
125 PATH=/usr/local/cross-tools/bin:/usr/local/cross-tools/i386-mingw32msvc/bin:$PATH
[b0a751b4]126 else
[f30265a0]127 if test -d /usr/i586-mingw32msvc/bin ; then
128 # debian mingw32 package
129 PATH=/usr/i586-mingw32msvc/bin:$PATH
130 CC=/usr/bin/i586-mingw32msvc-gcc
131 export CC
132 CXX=/usr/bin/i586-mingw32msvc-g++
133 export CXX
134 else
135 # variant of debian mingw32 package?
136 PATH=/usr/i386-mingw32msvc/bin:$PATH
137 CC=/usr/bin/i386-mingw32msvc-gcc
138 export CC
139 CXX=/usr/bin/i386-mingw32msvc-g++
140 export CXX
141 fi
142 fi
[3ac2a39f]143 if ! env LDFLAGS="-s -L/opt/rx-win32/lib" CPPFLAGS=-I/opt/rx-win32/include CAVEROT= ./configure --with-x=no --with-wxconfig=`pwd`/mingw_extras/wxmsw-config ; then
[f30265a0]144 echo mingw configure failed
145 exit 1
146 fi
147 if ! make ; then
148 echo mingw make failed
149 exit 1
[b0a751b4]150 fi
[8f6f99b]151 if ! make mingw_iss ; then
152 echo mingw make mingw_iss failed
[e66be9a]153 exit 1
154 fi
[f30265a0]155 if ! make distclean ; then
156 echo make distclean failed
157 exit 1
158 fi
159 PATH="$SAVE_PATH"
160 CC=
161 CXX=
[e66be9a]162fi
Note: See TracBrowser for help on using the repository browser.