rules revision 7c205843b5f25329b7bac4cb41e4c55a21c7aafe
#
# Copyright (C) 2006-2010 Oracle Corporation
#
# This file is part of VirtualBox Open Source Edition (OSE), as
# available from http://www.virtualbox.org. This file is free software;
# General Public License as published by the Free Software Foundation,
# in version 2 as it comes in the "COPYING" file of the VirtualBox OSE
# distribution. VirtualBox OSE is distributed in the hope that it will
# be useful, but WITHOUT ANY WARRANTY of any kind.
#
#
# NOTE: if you make changes to this file, please check if the updates should
#
#export DH_VERBOSE=1
export DH_COMPAT=4
# possible overrides:
# OSE=1 force VBOX_OSE
# NOPARALLEL=1 compile with -j1
# LINUX=<dir> compile vboxdrv against Linux found in <dir>
# VERBOSE=1 verbose build
# DEBUG=1 debug build
# NOSUBVER=1 disable generation of the sub-version field (which is
# either the subversion rev [if available] or the build date)
# NODOCS=1 don't build docs, use precompiled UserManual.pdf and
# VirtualBox.chm from $HOME
# NOMODS=1 don't build any module
# NOQT=1 don't build the Qt GUI
# EFI include the EFI binary from prebuild
# VERSUFFIX=<suffix> set a particular package version suffix (e.g. _customer)
# HEADLESS=1 build the headless version
# NOWEBSVC=1 don't build the webservice API, default for OSE
# STAGEDISO=<path> don't build the VBoxAdditions, use the precompiled .iso
# BLEEDING_EDGE=xyz
arch := $(shell dpkg --print-architecture)
ver := $(VBOX_VERSION_STRING)
debrel := $(if $(shell which lsb_release),_$(shell lsb_release -si)_$(shell lsb_release -sc),unknown)
# shipping Linux kernel modules with bleeding-edge releases doesn't make sense
# Locations of custom built Qt libraries (see below)
VBOX_PACKAGE_DIST=$(debdist) \
VBOX_SVN_REV=$(svnrev) \
fi; \
done
else
# Build architecture-dependent files here.
dh_clean -k
sed \
-e 's|%VERPKG%|$(verpkg)|g' \
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 \
fi \
done)
else
dh_link \
sed \
-e 's|%NOLSB%||g' \
-e 's|%DEBIAN%|yes|g' \
-e 's|%PACKAGE%|virtualbox|g' \
sed \
-e 's|%NOLSB%||g' \
-e 's|%DEBIAN%|yes|g' \
-e 's|%PACKAGE%|virtualbox|g' \
sed -e 's|%VER%|$(debver)|g' \
-e 's|%DATE%|$(shell date -R)|g' \
-e 's|%DEBREL%|$(subst _,~,$(debrel))|g' \
-e 's|%VERPKG%|$(verpkg)|g' \
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 \
$$f \
done
# for some reason, the Qt libraries couldn't be found on newer releases (e.g. Ubuntu hardy)
dh_gencontrol -- \
-Vdkms=$(if $(filter _Ubuntu_hardy _Ubuntu_intrepid _Ubuntu_jaunty _Ubuntu_karmic _Ubuntu_lucid,$(debrel)),dkms,)