My local network connectivity changed, uninteresting to casual user.
[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   scp -v mdsms-[0-9]* atrey.karlin.mff.cuni.cz:WWW/sw/
24   exit
25 fi
26
27 # if [ -f Makefile ];then touch ChangeLog;make maintainer-clean;fi
28 rm -r -f \
29   `find -name "*~"` \
30   errs* \
31   `find po -type f -not '(' -name POTFILES.in -o -name "*.po" -o -path "po/CVS*" ')'` \
32   intl \
33   install-sh \
34   mkinstalldirs \
35   missing \
36   INSTALL \
37   COPYING \
38   ABOUT-NLS \
39   Makefile \
40   Makefile.in \
41   */Makefile \
42   */Makefile.in \
43   configure \
44   configure.scan \
45   config.guess \
46   config.status \
47   config.sub \
48   config.log \
49   config.h \
50   confdefs.h \
51   conftest* \
52   autoh[0-9]* \
53   config.cache \
54   config.h.in \
55   stamp-h \
56   stamp-h.in \
57   aclocal.m4 \
58   getopt.c \
59   getopt.h \
60   getopt1.c \
61   need-declaration.m4 \
62   strdup.c \
63   usleep.c \
64   memmove.c \
65   mdsms.1 \
66   mdsms.1.in2 \
67   mdsms \
68   mdsms-[0-9]* \
69   mdsms.spec \
70   manfmt \
71   .deps \
72   ChangeLog \
73   *.o \
74
75
76 if [ "$1" = clean ];then exit;fi
77
78   d="`pwd`"
79   (cd $HOME/src/misc
80    (cd getopt
81     cp getopt.c getopt.h getopt1.c $d
82    )
83    (cd macros
84     cp need-declaration.m4 $d
85    )
86    cp strdup.c usleep.c memmove.c $d
87   )
88
89 aclocal -I .
90 gettextize --copy
91 autoheader
92 touch ChangeLog
93 automake --gnu -c --add-missing
94 rm -f ChangeLog
95 cp $HOME/src/misc/LGPL2.1 COPYING
96 ed po/Makefile.in.in <<HERE
97 ,s/prefix = @/prefix = \$(DESTDIR)@/g
98 w
99 HERE
100 autoheader
101 autoconf
102
103 if [ "$1" = dist ];then
104   exit
105 fi
106 ./configure $CONFDEFS