--ring-send tested with 9110 and fixed.
[mdsms.git] / autogen.sh
1 #!/bin/sh
2 # Run this to generate all the initial makefiles, etc.
3
4 # $Id$
5
6 # /lib/gconv/ISO8859-2.so is apparently clashing with EFence. :-(
7 CONFDEFS="--enable-maintainer-mode --enable-debug --without-efence"
8
9 if [ "$1" = rpm -o "$1" = rpmup ];then
10         ./autogen.sh
11   make
12   make dist
13   cp mdsms-[0-9]*.tar.gz /usr/src/redhat/SOURCES
14   rpm -ba --sign mdsms.spec
15         make dist-tarZ
16         rm /usr/src/redhat/SOURCES/mdsms-[0-9]*.tar.gz
17   mv /usr/src/redhat/SRPMS/mdsms-[0-9]*-*.src.rpm .
18   mv /usr/src/redhat/RPMS/i386/mdsms-[0-9]*-*.i386.rpm .
19         ls -l mdsms-[0-9]*
20         if [ "$1" = rpm ];then exit;fi
21         echo "Uploading $[`cat mdsms-[0-9]*|wc -c`] bytes..."
22         tar cf - mdsms-[0-9]*|ssh twilight ssh atrey.karlin.mff.cuni.cz 'cd WWW/sw\;tar xvvf -'
23         exit
24 fi
25
26 # if [ -f Makefile ];then touch ChangeLog;make maintainer-clean;fi
27 rm -r -f \
28         `find -name "*~"` \
29         errs* \
30         `find po -type f -not '(' -name POTFILES.in -o -name "*.po" -o -path "po/CVS*" ')'` \
31         intl \
32         install-sh \
33         mkinstalldirs \
34         missing \
35         INSTALL \
36         COPYING \
37         ABOUT-NLS \
38         Makefile \
39         Makefile.in \
40         */Makefile \
41         */Makefile.in \
42         configure \
43         configure.scan \
44         config.guess \
45         config.status \
46         config.sub \
47         config.log \
48         config.h \
49         confdefs.h \
50         conftest* \
51         autoh[0-9]* \
52         config.cache \
53         config.h.in \
54         stamp-h \
55         stamp-h.in \
56         aclocal.m4 \
57         getopt.c \
58         getopt.h \
59         getopt1.c \
60         need-declaration.m4 \
61         strdup.c \
62         usleep.c \
63         memmove.c \
64         mdsms.1 \
65         mdsms.1.in2 \
66         mdsms \
67         mdsms-[0-9]* \
68         mdsms.spec \
69         manfmt \
70         .deps \
71         ChangeLog \
72         *.o \
73
74
75 if [ "$1" = clean ];then exit;fi
76
77         d="`pwd`"
78         (cd $HOME/src/misc
79          (cd getopt
80                 cp getopt.c getopt.h getopt1.c $d
81          )
82          (cd macros
83                 cp need-declaration.m4 $d
84          )
85          cp strdup.c usleep.c memmove.c $d
86         )
87
88 aclocal -I .
89 gettextize --copy
90 autoheader
91 touch ChangeLog
92 automake --gnu -c --add-missing
93 rm -f ChangeLog
94 cp $HOME/src/misc/LGPL2.1 COPYING
95 ed po/Makefile.in.in <<HERE
96 ,s/prefix = @/prefix = \$(DESTDIR)@/g
97 w
98 HERE
99 autoheader
100 autoconf
101
102 if [ "$1" = dist ];then
103   exit
104 fi
105 ./configure $CONFDEFS