Debian Codegraph @

Makefile

raw ◀ ▶
Source reconstructed at patch state 1 of 3 — not the installed (fully patched) source.
3 Debian patches touch this file
1 # ============================================================================
2 # gzstream, C++ iostream classes wrapping the zlib compression library.
3 # Copyright (C) 2001 Deepak Bandyopadhyay, Lutz Kettner
4 #
5 # This library is free software; you can redistribute it and/or
6 # modify it under the terms of the GNU Lesser General Public
7 # License as published by the Free Software Foundation; either
8 # version 2.1 of the License, or (at your option) any later version.
9 #
10 # This library is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 # Lesser General Public License for more details.
14 #
15 # You should have received a copy of the GNU Lesser General Public
16 # License along with this library; if not, write to the Free Software
17 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18 # ============================================================================
19 #
20 # File : Makefile
21 # Revision : $Revision: 1.3 $
22 # Revision_date : $Date: 2001/10/04 15:09:28 $
23 # Author(s) : Deepak Bandyopadhyay, Lutz Kettner
24 #
25 # ============================================================================
26
27 # ----------------------------------------------------------------------------
28 # adapt these settings to your need:
29 # add '-DGZSTREAM_NAMESPACE=name' to CPPFLAGS to place the classes
30 # in its own namespace. Note, this macro needs to be set while creating
31 # the library as well while compiling applications based on it.
32 # As an alternative, gzstream.C and gzstream.h can be edited.
33 # ----------------------------------------------------------------------------
34
35 # CXX = CC -n32 -LANG:std # for SGI Irix 6.5, MIPSpro CC version 7.30
36 CXX = g++ # for Linux RedHat 6.1, g++ version 2.95.2
37
38 CPPFLAGS = -I. -O
39 LDFLAGS = -L. -lgzstream -lz
40 AR = ar cr
41
42 # ----------------------------------------------------------------------------
43 # plain simple rules to make and cleanup the library:
44 # make default; compiles the library
45 # make test; compiles and executes test. O.K. message marks success.
46 # make clean; removes temporary files
47 # make cleanall; removes temporary files, the library, and programs
48 # ----------------------------------------------------------------------------
49
50 default: libgzstream.a
51
52 test: test_gzip test_gunzip
53 ./test_gzip COPYING.LIB gz.tmp.gz
54 gunzip gz.tmp.gz
55 diff COPYING.LIB gz.tmp
56 gzip gz.tmp
57 ./test_gunzip gz.tmp.gz gz.tmp
58 diff COPYING.LIB gz.tmp
59 rm gz.tmp.gz gz.tmp
60 # *** O.K. Test finished successfully. ***
61
62 install: libgzstream.a test
63 cp libgzstream.a /usr/lib
64 cp gzstream.h /usr/include
65 chmod o+r /usr/include/gzstream.h
66 # *** O.K. Installation finished successfully. ***
67
68 gzstream.o : gzstream.C gzstream.h
69 ${CXX} ${CPPFLAGS} -c -o gzstream.o gzstream.C
70
71 test_gzip.o : test_gzip.C gzstream.h
72 ${CXX} ${CPPFLAGS} -c -o test_gzip.o test_gzip.C
73
74 test_gunzip.o : test_gunzip.C gzstream.h
75 ${CXX} ${CPPFLAGS} -c -o test_gunzip.o test_gunzip.C
76
77 libgzstream.a : gzstream.o
78 ${AR} libgzstream.a gzstream.o
79
80 test_gzip : test_gzip.o libgzstream.a
81 ${CXX} -o test_gzip test_gzip.o ${LDFLAGS}
82
83 test_gunzip : test_gunzip.o libgzstream.a
84 ${CXX} -o test_gunzip test_gunzip.o ${LDFLAGS}
85
86 clean :
87 rm -f *.o
88
89 cleanall :
90 rm -f *.o libgzstream.a test_gzip test_gunzip
91
92 uninstall:
93 rm /usr/include/gzstream.h /usr/lib/libgzstream.a
94
95 # ============================================================================
96 # EOF
97