blob: 586fa1098032ea428c6b3874edbb6bce5f114dbc [file] [log] [blame]
Harald Welte95f42062010-08-24 15:33:04 +02001#!/usr/bin/make -f
2# -*- makefile -*-
3# Sample debian/rules that uses debhelper.
4#
5# This file was originally written by Joey Hess and Craig Small.
6# As a special exception, when this file is copied by dh-make into a
7# dh-make output file, you may use that output file without restriction.
8# This special exception was added by Craig Small in version 0.37 of dh-make.
9#
10# Modified to make a template file for a multi-binary package with separated
11# build-arch and build-indep targets by Bill Allombert 2001
12
13# Uncomment this to turn on verbose mode.
14#export DH_VERBOSE=1
15
Eric Butlerf04324a2012-08-14 21:01:20 -070016DEBIAN := $(shell dpkg-parsechangelog | grep ^Version: | cut -d' ' -f2)
17DEBVERS := $(shell echo '$(DEBIAN)' | cut -d- -f1)
18VERSION := $(shell echo '$(DEBVERS)' | sed -e 's/[+-].*//' -e 's/~//g')
19
Harald Welte95f42062010-08-24 15:33:04 +020020%:
Holger Hans Peter Freythera4d91252012-11-06 14:44:44 +010021 dh --sourcedirectory=openbsc --with autoreconf $@
Eric Butler37074482012-08-14 17:40:58 -070022
Holger Hans Peter Freytherd7b97d42012-11-06 19:26:50 +010023# This is needed for debian stable (squeeze)
24override_dh_autoreconf:
25 cd openbsc && autoreconf --install --force
26
Holger Hans Peter Freyther5cbb44a2013-12-12 13:07:47 +010027override_dh_strip:
28 dh_strip -posmocom-bsc --dbg-package=osmocom-bsc-dbg
29 dh_strip -posmocom-nitb --dbg-package=osmocom-nitb-dbg
30 dh_strip -posmocom-ipaccess-utils --dbg-package=osmocom-ipaccess-utils-dbg
31 dh_strip -posmocom-bs11-utils --dbg-package=osmocom-bs11-utils-dbg
32 dh_strip -posmocom-sgsn --dbg-package=osmocom-sgsn-dbg
33 dh_strip -posmocom-gbproxy --dbg-package=osmocom-gbproxy-dbg
34 dh_strip -posmocom-bsc-nat --dbg-package=osmocom-bsc-nat-dbg
35
Eric Butler37074482012-08-14 17:40:58 -070036override_dh_auto_configure:
Holger Hans Peter Freythera4d91252012-11-06 14:44:44 +010037 echo $(VERSION) > openbsc/.tarball-version
38 dh_auto_configure --sourcedirectory=openbsc -- --enable-nat --enable-osmo-bsc
Eric Butler37074482012-08-14 17:40:58 -070039