File: rules

package info (click to toggle)
glew 2.0.0-3
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 8,200 kB
  • ctags: 22,861
  • sloc: ansic: 54,939; sh: 1,531; perl: 876; makefile: 622; python: 135
file content (80 lines) | stat: -rwxr-xr-x 1,802 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
#!/usr/bin/make -f
# (C) 2003 Marcelo E. Magall´┐Żn <mmagallo@debian.org>
# (C) 2006-2011 Joost Yervante Damad <andete@debian.org>
# (C) 2012 Matteo F. Vescovi <mfv.debian@gmail.com>

export DH_VERBOSE
# export DH_NO_ACT
# export DH_OPTIONS

CFLAGS = -Wall -g

srcversion := $(shell dpkg-parsechangelog | grep ^Version: | cut -d ' ' -f 2)

ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
	CFLAGS += -O0
else
	CFLAGS += -O2
endif
ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
	INSTALL_PROGRAM += -s
endif

DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)

configure: configure-stamp
configure-stamp:
	dh_testdir
	touch configure-stamp

build:

install: build-stamp
build-stamp: configure-stamp
	dh_testdir
	dh_testroot
	dh_prep
	$(MAKE) GL_LDFLAGS=-lGL GLU_LDFLAGS=-lGLU GLUT_LDFLAGS=-lglut LIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH)
	touch build-stamp
	dh_installdirs
	$(MAKE) install.all GLEW_DEST=$(CURDIR)/debian/tmp/usr LIBDIR=$(CURDIR)/debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)

clean:
	dh_testdir
	dh_testroot
	rm -f build-stamp build-stampmx configure-stamp
	$(MAKE) distclean
	dh_clean

# Build architecture-independent files here.
binary-indep: build install
# We have nothing to do by default.

build-arch: build
build-indep: build

# Build architecture-dependent files here.
binary-arch: build install
	dh_testdir
	dh_testroot
	dh_installdocs
	dh_installchangelogs
	dh_install --sourcedir=debian/tmp
	dh_installman
	dh_link
	dh_strip -plibglew2.0 --dbg-package=libglew-dbg
	dh_compress
	dh_fixperms
	dh_makeshlibs -V
	dh_installdeb
	dh_shlibdeps # -ldebian/tmp/usr/lib
	dh_gencontrol
	dh_md5sums
	dh_builddeb

binary: binary-indep binary-arch

debian/%.1: debian/%.sgml
	docbook-to-man $< > $@

.PHONY: build clean binary-indep binary-arch binary install debian-manpages