rules revision e2a0570d35035f00c593417795f2e37b1d4a3242
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# Copyright (C) 2006-2010 Oracle Corporation
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# This file is part of VirtualBox Open Source Edition (OSE), as
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# available from http://www.virtualbox.org. This file is free software;
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# you can redistribute it and/or modify it under the terms of the GNU
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# General Public License as published by the Free Software Foundation,
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# in version 2 as it comes in the "COPYING" file of the VirtualBox OSE
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# distribution. VirtualBox OSE is distributed in the hope that it will
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# be useful, but WITHOUT ANY WARRANTY of any kind.
00e8340a60924420ea08462899c5815a685c78b2vboxsync#export DH_VERBOSE=1
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# possible overrides:
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# OSE=1 force VBOX_OSE
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# NOPARALLEL=1 compile with -j1
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# LINUX=<dir> compile vboxdrv against Linux found in <dir>
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# VERBOSE=1 verbose build
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# DEBUG=1 debug build
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# NOSUBVER=1 disable generation of the sub-version field (which is
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# either the subversion rev [if available] or the build date)
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# NODOCS=1 don't build docs, use precompiled UserManual.pdf and
868d6eb6308a75913b9c494558832732e7539b0evboxsync# NOMODS=1 don't build any module
868d6eb6308a75913b9c494558832732e7539b0evboxsync# NOQT=1 don't build the Qt GUI
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# HEADLESS=1 build the headless version
2dfda90468c5653309a3e93423313e0ec0e627a2vboxsync# NOWEBSVC=1 don't build the webservice API, default for OSE
868d6eb6308a75913b9c494558832732e7539b0evboxsync# STAGEDISO=<path> don't build the VBoxAdditions, use the precompiled .iso
868d6eb6308a75913b9c494558832732e7539b0evboxsync# BLEEDING_EDGE=xyz
pkgdir := ..
debrel := $(if $(shell which lsb_release),_$(shell lsb_release -si)_$(shell lsb_release -sc),unknown)
$(if $(filter _Debian_etch _Ubuntu_dapper _Ubuntu_edgy _Ubuntu_feisty _Ubuntu_gutsy _Ubuntu_hardy,$(debrel)),--with-qt4-dir=$(qtstdc6)) \
$(if $(filter _Debian_sarge _Ubuntu_dapper _Ubuntu_edgy _xandros4.1 _ucs1.3,$(debrel)),--disable-pulse,) \
dh_clean -k
sed \
if [ -f $$d/vboxdrv.ko -a -f $$d/vboxnetflt.ko -a -f $$d/vboxnetadp.ko ]; then \
install -D -g 0 -o 0 -m 0644 \
install -D -g 0 -o 0 -m 0644 \
install -D -g 0 -o 0 -m 0644 \
dh_link \
sed \
dh_strip --keep-debug --exclude=libQtCoreVBox.so.4 --exclude=libQtGuiVBox.so.4 --exclude=libQtNetworkVBox.so.4 --exclude=libQtOpenGLVBox.so.4 --exclude=libqtaccessiblewidgets.so
for f in \
dh_gencontrol -- \