~ubuntu-branches/ubuntu/quantal/pgbouncer/quantal-security

« back to all changes in this revision

Viewing changes to lib/mk/temos/src/antimake5.temo

  • Committer: Package Import Robot
  • Author(s): Christoph Berg, Peter Eisentraut, Christoph Berg
  • Date: 2012-01-27 17:40:22 UTC
  • mfrom: (14.1.2 sid)
  • Revision ID: package-import@ubuntu.com-20120127174022-zrp5nr3h6lwi5l1e
Tags: 1.5-1
[ Peter Eisentraut ]
* Update watch file to allow .tar.gz in addition to .tgz
* Remove obsolete README.source and repack support in watch file

[ Christoph Berg ]
* New upstream release.
* Use start-stop-daemon for stopping the daemon.  Closes: #641568.
* Use pgbouncer -R to restart in place, thanks Cody Cutrer for the patch.
  Closes: #657204.
* Update URL in README.Debian.  Closes: #655283.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
 
 
2
. ./libtemo.sh || exit 1
 
3
 
 
4
test_start
 
5
 
 
6
title Shared libraries and autoconf
 
7
 
 
8
msg Autoconf setup
 
9
 
 
10
cat_file autogen.sh <<"EOF"
 
11
        ../../std-autogen.sh ../../..
 
12
 
 
13
        # fetch Antimake template from libusual
 
14
        cp ../../antimake.mk antimake.mk.in
 
15
EOF
 
16
 
 
17
cat_file configure.ac <<"EOF"
 
18
        AC_INIT([actest], [0.1])
 
19
        AC_CONFIG_SRCDIR([prog.c])
 
20
        AC_PREREQ([2.59])
 
21
 
 
22
        LT_INIT
 
23
        AC_USUAL_INIT
 
24
 
 
25
        AC_USUAL_PROGRAM_CHECK
 
26
 
 
27
        AC_OUTPUT([antimake.mk])
 
28
EOF
 
29
 
 
30
msg Here are the source files:
 
31
 
 
32
cat_file prog.c <<"EOF"
 
33
        void func1(void);
 
34
        int main(void)
 
35
        {
 
36
                func1();
 
37
                return 0;
 
38
        }
 
39
EOF
 
40
 
 
41
cat_file func.c <<"EOF"
 
42
        #include <stdio.h>
 
43
 
 
44
        void func1(void);
 
45
        void func1(void)
 
46
        {
 
47
                printf("hello from func1\n");
 
48
        }
 
49
EOF
 
50
 
 
51
msg Antimake based Makefile
 
52
 
 
53
cat_file Makefile <<"EOF"
 
54
        lib_LTLIBRARIES = libtemo.la
 
55
        libtemo_la_SOURCES = func.c
 
56
        libtemo_la_LDFLAGS = -version-info 3:0:2
 
57
 
 
58
        bin_PROGRAMS = prog
 
59
        prog_SOURCES = prog.c
 
60
        prog_LDADD = libtemo.la
 
61
 
 
62
        # clean configured files
 
63
        DISTCLEANFILES = \
 
64
                config.status \
 
65
                config.log \
 
66
                antimake.mk \
 
67
                libtool
 
68
 
 
69
        # clean generated files
 
70
        MAINTAINERCLEANFILES = \
 
71
                configure \
 
72
                config.guess \
 
73
                config.sub \
 
74
                install-sh \
 
75
                antimake.mk.in \
 
76
                ltmain.sh
 
77
 
 
78
        EXTRA_DIST = \
 
79
                Makefile \
 
80
                $(MAINTAINERCLEANFILES)
 
81
 
 
82
        # launch Antimake
 
83
        include antimake.mk
 
84
EOF
 
85
 
 
86
msg Build the project
 
87
run sh ./autogen.sh
 
88
runq ./configure
 
89
run make
 
90
run ls
 
91
run ./prog
 
92
 
 
93
msg Create distribution package
 
94
run make dist
 
95
run 'tar tzf actest-0.1.tar.gz | sort'
 
96
 
 
97
msg Test installation
 
98
run 'make install DESTDIR=/tmp/test-inst'
 
99
run ls
 
100
run 'find /tmp/test-inst | sort'
 
101
run rm -rf /tmp/test-inst
 
102
 
 
103
msg Test the distribution package and separate build dir
 
104
run mkdir -p test
 
105
run cd test
 
106
run tar xf ../actest-0.1.tar.gz
 
107
run mkdir build
 
108
run cd build
 
109
runq ../actest-0.1/configure
 
110
run make
 
111
run ls
 
112
run ./prog
 
113
run cd ../..
 
114
 
 
115
msg Clean up
 
116
run make maintainer-clean
 
117
run ls
 
118
 
 
119
msg Done
 
120