6924226f7408e4b08650a31bc80c54eb3ffca62f
[tclrobot.git] / debian / rules
1 #!/usr/bin/make -f
2 # Sample debian/rules that uses debhelper.
3 # GNU copyright 1997 to 1999 by Joey Hess.
4
5 # Uncomment this to turn on verbose mode.
6 #export DH_VERBOSE=1
7
8
9
10
11 CFLAGS = -Wall -g
12
13 ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
14         CFLAGS += -O0
15 else
16         CFLAGS += -O2
17 endif
18 ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
19         INSTALL_PROGRAM += -s
20 endif
21
22 # shared library versions, option 1
23 version=2.0.5
24 major=2
25 # option 2, assuming the library is created as src/.libs/libfoo.so.2.0.5 or so
26 #version=`ls src/.libs/lib*.so.* | \
27 # awk '{if (match($$0,/[0-9]+\.[0-9]+\.[0-9]+$$/)) print substr($$0,RSTART)}'`
28 #major=`ls src/.libs/lib*.so.* | \
29 # awk '{if (match($$0,/\.so\.[0-9]+$$/)) print substr($$0,RSTART+4)}'`
30
31 configure: configure-stamp
32 configure-stamp:
33         dh_testdir
34         # Add here commands to configure the package.
35         ./configure --prefix=$(CURDIR)/debian/tmp/usr
36         touch configure-stamp
37
38
39 build: build-stamp
40 build-stamp: configure-stamp 
41         dh_testdir
42
43         # Add here commands to compile the package.
44         $(MAKE)
45
46         touch build-stamp
47
48 clean:
49         dh_testdir
50         dh_testroot
51         rm -f build-stamp configure-stamp
52
53         # Add here commands to clean up after the build process.
54         -$(MAKE) clean
55
56         dh_clean
57
58 install: build
59         dh_testdir
60         dh_testroot
61         dh_clean -k
62         dh_installdirs
63
64         # Add here commands to install the package into debian/tmp
65         $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
66         #cp tclrobot.so debian/tmp/usr/lib/libtclrobot.so
67
68
69 # Build architecture-independent files here.
70 binary-indep: build install
71 # We have nothing to do by default.
72
73 # Build architecture-dependent files here.
74 binary-arch: build install
75         dh_testdir
76         dh_testroot
77         dh_installchangelogs 
78         dh_installdocs
79 #       dh_installexamples
80         dh_install
81 #       dh_installmenu
82 #       dh_installdebconf       
83 #       dh_installlogrotate
84 #       dh_installemacsen
85 #       dh_installpam
86 #       dh_installmime
87 #       dh_installinit
88 #       dh_installcron
89 #       dh_installinfo
90 #       dh_installman
91         dh_link
92         dh_strip
93         dh_compress
94         dh_fixperms
95 #       dh_perl
96 #       d_python
97 #       dh_makeshlibs
98         dh_installdeb
99         dh_shlibdeps
100         dh_gencontrol
101         dh_md5sums
102         dh_builddeb
103
104 binary: binary-indep binary-arch
105 .PHONY: build clean binary-indep binary-arch binary install configure