rules revision 3baadeafd9922582dad9b32431362e6296417dd8
8696d418011068e5cedf3a229f7a6613e7798e92ky# Copyright (C) 2006-2011 Oracle Corporation
8696d418011068e5cedf3a229f7a6613e7798e92ky# This file is part of VirtualBox Open Source Edition (OSE), as
8696d418011068e5cedf3a229f7a6613e7798e92ky# available from http://www.virtualbox.org. This file is free software;
8696d418011068e5cedf3a229f7a6613e7798e92ky# you can redistribute it and/or modify it under the terms of the GNU
8696d418011068e5cedf3a229f7a6613e7798e92ky# General Public License as published by the Free Software Foundation,
8696d418011068e5cedf3a229f7a6613e7798e92ky# in version 2 as it comes in the "COPYING" file of the VirtualBox OSE
8696d418011068e5cedf3a229f7a6613e7798e92ky# distribution. VirtualBox OSE is distributed in the hope that it will
8696d418011068e5cedf3a229f7a6613e7798e92ky# be useful, but WITHOUT ANY WARRANTY of any kind.
8696d418011068e5cedf3a229f7a6613e7798e92ky#export DH_VERBOSE=1
8696d418011068e5cedf3a229f7a6613e7798e92ky# possible overrides:
8696d418011068e5cedf3a229f7a6613e7798e92ky# OSE=1 force VBOX_OSE
8696d418011068e5cedf3a229f7a6613e7798e92ky# NOPARALLEL=1 compile with -j1
8696d418011068e5cedf3a229f7a6613e7798e92ky# LINUX=<dir> compile vboxdrv against Linux found in <dir>
8696d418011068e5cedf3a229f7a6613e7798e92ky# VERBOSE=1 verbose build
8696d418011068e5cedf3a229f7a6613e7798e92ky# DEBUG=1 debug build
8696d418011068e5cedf3a229f7a6613e7798e92ky# NOSUBVER=1 disable generation of the sub-version field (which is
8696d418011068e5cedf3a229f7a6613e7798e92ky# either the subversion rev [if available] or the build date)
8696d418011068e5cedf3a229f7a6613e7798e92ky# NODOCS=1 don't build docs, use precompiled UserManual.pdf and
8696d418011068e5cedf3a229f7a6613e7798e92ky# NOMODS=1 don't build any module
8696d418011068e5cedf3a229f7a6613e7798e92ky# NOQT=1 don't build the Qt GUI
8696d418011068e5cedf3a229f7a6613e7798e92ky# HEADLESS=1 build the headless version
8696d418011068e5cedf3a229f7a6613e7798e92ky# NOWEBSVC=1 don't build the webservice API, default for OSE
8696d418011068e5cedf3a229f7a6613e7798e92ky# STAGEDISO=<path> don't build the VBoxAdditions, use the precompiled .iso
8696d418011068e5cedf3a229f7a6613e7798e92ky# BLEEDING_EDGE=xyz
pkgdir := ..
debrel := $(if $(shell which lsb_release),_$(shell lsb_release -si)_$(shell lsb_release -sc),unknown)
instmod := $(if $(filter _Ubuntu_lucid _Ubuntu_maverick _Ubuntu_natty _Ubuntu_oneiric _Debian_sid,$(debrel)),,1)
dh_clean -k
rmdir $$i; \
sed \
install -D -g 0 -o 0 -m 644 $(vboxroot)/src/VBox/Installer/linux/debian/VBox.sh $(prefix)/usr/bin/VBox
if [ -f $$d/vboxdrv.ko -a -f $$d/vboxnetflt.ko -a -f $$d/vboxnetadp.ko -a -f $$d/vboxpci.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 \
install -D -g 0 -o 0 -m 0644 \
dh_link \
sed \
sed \
$(vboxroot)/src/VBox/Installer/linux/vboxballoonctrl-service.sh.in > debian/vboxballoonctrl-service.init
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 -- \