From: Vincent Cheng Date: Sun, 26 Oct 2014 00:04:28 +0000 (+0100) Subject: bumblebee (3.2.1-7) unstable; urgency=medium X-Git-Tag: archive/raspbian/3.2.1-26+rpi1~1^2^2^2^2~2 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=5be557d7769c500d109399f1bc870e2b2a414cc5;p=bumblebee.git bumblebee (3.2.1-7) unstable; urgency=medium * Move conffile handling introduced in 3.2.1-6 from bumblebee-nvidia to bumblebee. [dgit import unpatched bumblebee 3.2.1-7] --- 5be557d7769c500d109399f1bc870e2b2a414cc5 diff --cc debian/README.Debian index 8e3a3ba,0000000..824d22b mode 100644,000000..100644 --- a/debian/README.Debian +++ b/debian/README.Debian @@@ -1,14 -1,0 +1,95 @@@ +bumblebee for Debian/Ubuntu +--------------------------- + - Bumblebee in Debian defaults to using the primus backend, not because we wish - to diverge from upstream, but simply because virtualgl and libjpeg-turbo are - not yet packaged. libjpeg-turbo is currently blocked by a number of technical - and/or legal issues in Debian; see http://bugs.debian.org/612341. - - Bumblebee in Ubuntu also defaults to using the primus backend, because - virtualgl has not yet been packaged for Ubuntu proper. It is however easy to - switch to using virtualgl by using upstream's PPAs. Follow the instructions at: ++Post-installation instructions: ++------------------------------- ++ ++You must add your user to the bumblebee group in order to use optirun or ++primusrun, i.e. ++ ++ $ sudo adduser $USER bumblebee ++ ++where $USER corresponds to your username. Don't forget to log out and log back ++in for this to take effect. ++ ++If you have sudo configured for your current user, i.e. your user is a member ++of the sudo group, this step is not needed (the bumblebee package postinst ++script takes care of adding sudo users to the bumblebee group automatically). ++To clarify, sudo is not needed to use bumblebee; it simply makes adding your ++user to the bumblebee group unnecessary. ++ ++This step is unnecessary for Ubuntu users since sudo comes pre-configured and ++ready to be used by default (for user accounts created during install). ++ ++To test whether bumblebee has been configured correctly, try running the ++glxgears demo (you must first install mesa-utils): ++ ++ $ optirun glxgears -info ++ ++ ++Primus vs. VirtualGL: ++--------------------- ++ ++Bumblebee in Debian and Ubuntu defaults to using the primus backend, because ++virtualgl has not yet been packaged for Debian/Ubuntu proper. For Ubuntu users, ++it is however easy to switch to using virtualgl by using upstream's PPAs. ++Follow the instructions at: +https://launchpad.net/~bumblebee/+archive/stable + - -- Vincent Cheng Wed, 27 Feb 2013 01:07:57 -0800 ++ ++Common issues: ++-------------- ++ ++- If optirun returns the following error: ++[ERROR]Cannot access secondary GPU - error: Could not load GPU driver ++ ++You must edit /etc/bumblebee/bumblebee.conf using your preferred editor as ++root, and change "KernelDriver=nvidia" to "KernelDriver=nvidia-current", ++then restart the bumblebee daemon, i.e. ++ ++ $ sudo service bumblebeed restart ++ ++(Refer to https://bugs.debian.org/717687 for a brief explanation.) ++ ++- If optirun returns the following error: ++[ERROR]Cannot access secondary GPU - error: [XORG] (EE) No devices detected ++ ++You may have to set the BusID manually, in /etc/bumblebee/xorg.conf.nvidia. ++To get the BusID, run lspci | egrep 'VGA|3D' in a terminal. Refer to the ++comments in that file for further instructions. ++ ++- If optirun returns the following error: ++[ERROR]Cannot access secondary GPU - error: [XORG] (EE) /dev/dri/card0: ++failed to set DRM interface version 1.4: Permission denied ++ ++You have to append the following section to /etc/bumblebee/xorg.conf.nvidia: ++ ++Section "Screen" ++ Identifier "Default Screen" ++ Device "DiscreteNvidia" ++EndSection ++ ++Also refer to https://bugs.debian.org/756522 for a brief explanation. ++ ++- If optirun errors out and dmesg reports that the GPU has "fallen off the bus" ++on Linux >= 3.10, either stick with an older kernel version (<= 3.9), or add ++rcutree.rcu_idle_gp_delay=1 to your grub command line (in /etc/default/grub, ++then run update-grub and reboot) as a workaround. ++ ++This is a known problem upstream and suspected to be an issue with the ++proprietary nvidia driver. Refer to Bumblebee github issue #455, ++https://github.com/Bumblebee-Project/Bumblebee/issues/455. ++ ++ ++A more up-to-date list of common issues can be found on the Debian/Ubuntu wiki ++pages relating to bumblebee, i.e.: ++ ++https://wiki.debian.org/Bumblebee ++https://wiki.ubuntu.com/Bumblebee ++ ++A more comprehensive list is available upstream: ++ ++https://github.com/Bumblebee-Project/Bumblebee/wiki/Troubleshooting ++ ++ ++ -- Vincent Cheng Sat, 25 Oct 2014 10:13:42 -0700 diff --cc debian/bumblebee-nvidia.postinst index 993e6fb,0000000..3420817 mode 100644,000000..100644 --- a/debian/bumblebee-nvidia.postinst +++ b/debian/bumblebee-nvidia.postinst @@@ -1,54 -1,0 +1,65 @@@ +#!/bin/sh +# postinst script for bumblebee-nvidia +# +# see: dh_installdeb(1) + +set -e + ++xconffile=/etc/bumblebee/xorg.conf.nvidia ++ +case "$1" in + configure) + # Ubuntu and Debian's packaging of nvidia's proprietary driver differ greatly + # Also, do not rely solely on dpkg-vendor (see LP: #1061769) + if (which dpkg-vendor >/dev/null && dpkg-vendor --derives-from Ubuntu) || \ + [ -e /etc/dpkg/origins/ubuntu ]; then + + # == Ubuntu specific section == + # Repair GL on the intel display + for arch in x86_64-linux-gnu i386-linux-gnu; do + update-alternatives --force --set \ + ${arch}_gl_conf /usr/lib/$arch/mesa/ld.so.conf 2>/dev/null || true + done + - # versions before Oneiric without multiarch - update-alternatives --force --set \ - gl_conf /usr/lib/mesa/ld.so.conf 2>/dev/null || true ++ # assume first device to be discrete in nvidia/nvidia ++ busid=$(lspci -d10de: -nn | grep '\[030[02]\]' | cut -d' ' -f1 | tr . : | head -1) ++ ++ if [ -z "$busid" ]; then ++ echo "No Nvidia card found. If you really have an Optimus system," ++ echo "try selecting the Optimus setup in BIOS and run:" ++ echo "sudo dpkg-reconfigure bumblebee-nvidia" ++ else ++ echo "Selecting $busid as discrete nvidia card. If this is incorrect," ++ echo "edit the BusID line in $xconffile" ++ sed -i $xconffile -r -e "s/^([\t ]*)#([\t ]*BusID[\t ]*)\"[^\"]*\"$/\\1 \\2\"PCI\:$busid\"/" ++ fi + + else + + # == Debian specific section == + # Repair GL on the intel display + update-alternatives --force --set \ + glx /usr/lib/mesa-diverted 2>/dev/null || true + + fi + + ldconfig + # this has a chance of crashing the machine with mainline kernels... + grep -q '^nouveau ' /proc/modules && rmmod nouveau || true + if [ -e "/etc/init/bumblebeed.conf" ]; then + invoke-rc.d bumblebeed restart || true + fi + ;; + + abort-upgrade|abort-remove|abort-deconfigure) + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +#DEBHELPER# + +exit 0 diff --cc debian/bumblebee-nvidia.postrm index 07fcfde,0000000..7a78df7 mode 100644,000000..100644 --- a/debian/bumblebee-nvidia.postrm +++ b/debian/bumblebee-nvidia.postrm @@@ -1,46 -1,0 +1,43 @@@ +#!/bin/sh +# postrm script for bumblebee-nvidia +# +# see: dh_installdeb(1) + +set -e + +case "$1" in + purge|remove|abort-install) + # Ubuntu and Debian's packaging of nvidia's proprietary driver differ greatly + # Also, do not rely solely on dpkg-vendor (see LP: #1061769) + if (which dpkg-vendor >/dev/null && dpkg-vendor --derives-from Ubuntu) || \ + [ -e /etc/dpkg/origins/ubuntu ]; then + + # == Ubuntu specific section == + # Restore the alternatives in case bumblebee is installed on a + # non-Optimus system that requires the nvidia driver + for arch in x86_64-linux-gnu i386-linux-gnu; do + update-alternatives --force --auto ${arch}_gl_conf 2>/dev/null || true + done + - # versions before Oneiric without multiarch - update-alternatives --force --auto gl_conf 2>/dev/null || true - + else + + # == Debian specific section == + # Restore the alternatives in case bumblebee is installed on a + # non-Optimus system that requires the nvidia driver + update-alternatives --force --auto glx 2>/dev/null || true + + fi + + ldconfig + ;; + upgrade|failed-upgrade|abort-upgrade|disappear) + ;; + *) + echo "postrm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +#DEBHELPER# + +exit 0 diff --cc debian/bumblebee.bumblebeed.upstart index f2bdb67,0000000..3caf1ce mode 100644,000000..100644 --- a/debian/bumblebee.bumblebeed.upstart +++ b/debian/bumblebee.bumblebeed.upstart @@@ -1,44 -1,0 +1,44 @@@ +# Upstart job for Bumblebee daemon + - description "Bumblebee supporting nVidia Optimus cards" ++description "Bumblebee supporting NVIDIA Optimus cards" +author "Lekensteyn " + +# XXX: do we need to stop before / after a graphical DE like kdm? +start on (login-session-start or desktop-session-start) +stop on (desktop-shutdown) + +# restart in case it crashed for some reason +respawn + +script + libopts= + + # When the user installs a nvidia package that is unknown, + # ignore the paths in bumblebee.conf and use detected ones + if ! driver=$(grep -Po '^Driver=\K.*' /etc/bumblebee/bumblebee.conf) \ + || [ -z "$driver" ] || [ "$driver" = "nvidia" ]; then + # find LibraryPath setting of nvidia section + libpath=$(awk -F[=:] '/^\[driver-nvidia\]/{d=1}/^LibraryPath=/{if(d){print $2;exit}}' \ + /etc/bumblebee/bumblebee.conf) || true + + # pick the first available nvidia installation (not necessary + # the latest, e.g. nvidia-current over nvidia-experimental-310) + pkgname=$(ls -1d /usr/lib/nvidia*/libGL.so | cut -d/ -f4 | head -1) || true + + # When the default library path does not contain nvidia drivers, + # it is possibly not installed. If no driver is installed (no + # /usr/lib/nvidia-*), assume that the auto-detection will use + # nouveau instead and do not override paths. + if [ ! -e "$libpath/libGL.so" -a -n "$pkgname" ] && \ + modprobe -nq "$pkgname"; then + # assume nvidia driver even if nouveau is already loaded + libopts="$libopts --driver nvidia" + libopts="$libopts --driver-module $pkgname" + libopts="$libopts --ldpath /usr/lib/$pkgname:/usr/lib32/$pkgname" + libopts="$libopts --module-path /usr/lib/$pkgname/xorg,/usr/lib/xorg/modules" + fi + fi + + # don't use --daemon as Upstart gets confused by that. + exec '/usr/sbin/bumblebeed' --use-syslog $libopts +end script diff --cc debian/bumblebee.conf index 0000000,0000000..9ca066d new file mode 100644 --- /dev/null +++ b/debian/bumblebee.conf @@@ -1,0 -1,0 +1,51 @@@ ++# installed by bumblebee-nvidia ++# to be used by kmod / module-init-tools, and installed in /etc/modprobe.d/ ++# or equivalent ++ ++# do not automatically load nouveau as it may prevent nvidia from loading ++blacklist nouveau ++# do not automatically load nvidia as it's unloaded anyway when bumblebeed ++# starts and may fail bumblebeed to disable the card in a race condition. ++blacklist nvidia ++blacklist nvidia-current ++blacklist nvidia-current-updates ++# 304 ++blacklist nvidia-304 ++blacklist nvidia-304-updates ++blacklist nvidia-experimental-304 ++# 310 ++blacklist nvidia-310 ++blacklist nvidia-310-updates ++blacklist nvidia-experimental-310 ++# 313 ++blacklist nvidia-313 ++blacklist nvidia-313-updates ++blacklist nvidia-experimental-313 ++# 319 ++blacklist nvidia-319 ++blacklist nvidia-319-updates ++blacklist nvidia-experimental-319 ++# 325 ++blacklist nvidia-325 ++blacklist nvidia-325-updates ++blacklist nvidia-experimental-325 ++# 331 ++blacklist nvidia-331 ++blacklist nvidia-331-updates ++blacklist nvidia-experimental-331 ++# 334 ++blacklist nvidia-334 ++blacklist nvidia-334-updates ++blacklist nvidia-experimental-334 ++# 337 ++blacklist nvidia-337 ++blacklist nvidia-337-updates ++blacklist nvidia-experimental-337 ++# 340 ++blacklist nvidia-340 ++blacklist nvidia-340-updates ++blacklist nvidia-experimental-340 ++# 343 ++blacklist nvidia-343 ++blacklist nvidia-343-updates ++blacklist nvidia-experimental-343 diff --cc debian/bumblebee.install index 6073cee,0000000..e2ccfd5 mode 100644,000000..100644 --- a/debian/bumblebee.install +++ b/debian/bumblebee.install @@@ -1,2 -1,0 +1,3 @@@ +debian/bumblebee/etc/bumblebee/* usr/share/bumblebee/default-conf/ ++debian/bumblebee.conf usr/share/bumblebee/default-conf/ +scripts/systemd/bumblebeed.service lib/systemd/system/ diff --cc debian/bumblebee.maintscript index 0000000,0000000..99014bb new file mode 100644 --- /dev/null +++ b/debian/bumblebee.maintscript @@@ -1,0 -1,0 +1,1 @@@ ++rm_conffile /etc/modprobe.d/bumblebee.conf 3.2.1-6~ diff --cc debian/bumblebee.postinst index 76cf24e,0000000..f75e9a4 mode 100644,000000..100644 --- a/debian/bumblebee.postinst +++ b/debian/bumblebee.postinst @@@ -1,44 -1,0 +1,73 @@@ +#!/bin/sh +# postinst script for bumblebee +# +# see: dh_installdeb(1) + +set -e + ++xconffile=/etc/bumblebee/xorg.conf.nouveau ++ +# group that allows users to use Bumblebee +BB_GROUP=bumblebee + +# add members of these groups automatically to group "bumblebee" for new +# installations +USE_GROUPS='adm sudo admin' + +case "$1" in + configure) + # only add a group and members if the configured group does match the + # default group and if the group is missing + if grep -qx ServerGroup=$BB_GROUP /etc/bumblebee/bumblebee.conf && + ! getent group $BB_GROUP > /dev/null; then - groupadd $BB_GROUP ++ groupadd --system $BB_GROUP + users=$(getent group $USE_GROUPS | cut -d: -f4 | tr , '\n' | sort -u) + echo "Adding members from group(s) '$USE_GROUPS' to '$BB_GROUP':" + echo $users + for user in $users; do + gpasswd -a $user $BB_GROUP + done + fi - # rebuild initial ramdisk to include blacklist - update-initramfs -u ++ ++ ++ # Raring specific issue ++ # Also, do not rely solely on dpkg-vendor (see LP: #1061769) ++ if (which dpkg-vendor >/dev/null && dpkg-vendor --derives-from Ubuntu) || \ ++ [ -e /etc/dpkg/origins/ubuntu ]; then ++ # assume first device to be discrete in nvidia/nvidia ++ busid=$(lspci -d10de: -nn | grep '\[030[02]\]' | cut -d' ' -f1 | tr . : | head -1) ++ if [ -z "$busid" ]; then ++ echo "No Nvidia card found. If you really have an Optimus system," ++ echo "try selecting the Optimus setup in BIOS and run:" ++ echo "sudo dpkg-reconfigure bumblebee" ++ else ++ echo "Selecting $busid as discrete nvidia card. If this is incorrect," ++ echo "edit the BusID line in $xconffile ." ++ sed -i $xconffile -r -e "s/^([\t ]*)#([\t ]*BusID[\t ]*)\"[^\"]*\"$/\\1 \\2\"PCI\:$busid\"/" ++ fi ++ ++ # Only for 3.2.1, remove busid.conf if still present. ++ if [ -e /etc/bumblebee/xorg.conf.d/busid.conf ]; then ++ echo "Deleting old /etc/bumblebee/xorg.conf.d/busid.conf" ++ rm /etc/bumblebee/xorg.conf.d/busid.conf ++ fi ++ fi ++ ++ # Do not treat /etc/modprobe.d/bumblebee-nvidia.conf as a conffile ++ # LP: #1242785, https://github.com/Bumblebee-Project/Bumblebee/issues/525 ++ cp -f /usr/share/bumblebee/default-conf/bumblebee.conf /etc/modprobe.d/bumblebee.conf ++ + ;; + + abort-upgrade|abort-remove|abort-deconfigure) + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +#DEBHELPER# + +exit 0 diff --cc debian/bumblebee.postrm index ea81ff5,0000000..f4f06be mode 100644,000000..100644 --- a/debian/bumblebee.postrm +++ b/debian/bumblebee.postrm @@@ -1,35 -1,0 +1,38 @@@ +#!/bin/sh +# postrm script for bumblebee +# +# see: dh_installdeb(1) + +set -e + + +case "$1" in + purge) + groupdel bumblebee || true + # keep this as old versions did not mark these files as conffiles + for file in bumblebee.conf xorg.conf.nvidia xorg.conf.nouveau; do + rm -f /etc/bumblebee/$file + done ++ ++ # Do not treat /etc/modprobe.d/bumblebee-nvidia.conf as a conffile ++ # LP: #1242785, https://github.com/Bumblebee-Project/Bumblebee/issues/525 ++ rm -f /etc/modprobe.d/bumblebee.conf ++ + ;; + remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) + ;; + + *) + echo "postrm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +case "$1" in + purge|remove|abort-install) - # update initial ramdisk to skip blacklist - update-initramfs -u + ;; +esac + +#DEBHELPER# + +exit 0 diff --cc debian/bumblebee.triggers index 0000000,0000000..6c9f454 new file mode 100644 --- /dev/null +++ b/debian/bumblebee.triggers @@@ -1,0 -1,0 +1,1 @@@ ++activate update-initramfs diff --cc debian/changelog index 2c42601,0000000..8d460d4 mode 100644,000000..100644 --- a/debian/changelog +++ b/debian/changelog @@@ -1,19 -1,0 +1,69 @@@ - bumblebee (3.1-1) experimental; urgency=low ++bumblebee (3.2.1-7) unstable; urgency=medium + - * New upstream release. - * Upload to experimental. ++ * Move conffile handling introduced in 3.2.1-6 from bumblebee-nvidia ++ to bumblebee. + - -- Vincent Cheng Tue, 09 Apr 2013 19:59:13 -0700 ++ -- Vincent Cheng Sat, 25 Oct 2014 17:04:28 -0700 + - bumblebee (3.0.1-1) unstable; urgency=low ++bumblebee (3.2.1-6) unstable; urgency=medium ++ ++ * Build with CONF_DRIVER_MODULE_NVIDIA=nvidia-current instead of nvidia. ++ * Stop treating /etc/modprobe.d/bumblebee.conf as a conffile and remove it ++ when removing bumblebee, not just when purging it. (LP: #1242785) ++ - Pre-Depends on dpkg >= 1.15.7.2 for dpkg-maintscript-helper rm_conffile. ++ * Add patches: fix-device-detection.patch, ignore-error-on-X-shutdown.patch, ++ cherry-picked from upstream git. ++ * Allow more nvidia flavours to satisfy bumblebee-nvidia's dependencies ++ (relevant only for Ubuntu). ++ * Update debian/README.Debian. ++ * Update email address. ++ * Update Standards version to 3.9.6, no changes required. ++ ++ -- Vincent Cheng Sat, 25 Oct 2014 10:13:42 -0700 ++ ++bumblebee (3.2.1-5) unstable; urgency=medium ++ ++ * Allow more nvidia flavours to satisfy bumblebee-nvidia's dependencies ++ (relevant only for Ubuntu). (LP: #1261180) ++ * Update Standards version to 3.9.5, no changes required. ++ ++ -- Vincent Cheng Mon, 06 Jan 2014 01:24:33 -0800 ++ ++bumblebee (3.2.1-4) unstable; urgency=low ++ ++ * Use dh-systemd (for systemd-specific additions to maintscripts). ++ (Closes: #715270) ++ * Add bumblebee group as system group (gid in between 100-999) instead ++ of a regular group in postinst. (Closes: #718772) ++ ++ -- Vincent Cheng Tue, 20 Aug 2013 02:35:34 -0700 ++ ++bumblebee (3.2.1-3) unstable; urgency=low ++ ++ * Append /usr/lib/primus to CONF_PRIMUS_LD_PATH in d/rules to ease ++ pre-multiarch backports. (Closes: #712665) ++ * Have bumblebee depend on bbswitch-dkms | bbswitch-source, and ++ bumblebee-nvidia depend on all possible m-a built nvidia modules. ++ * Add support for nvidia-325 packaged in Ubuntu (not relevant for Debian). ++ ++ -- Vincent Cheng Thu, 11 Jul 2013 01:18:07 -0700 ++ ++bumblebee (3.2.1-2) unstable; urgency=low ++ ++ * Allow more nvidia flavours to satisfy bumblebee-nvidia's dependencies ++ (relevant for Ubuntu). ++ ++ -- Vincent Cheng Wed, 29 May 2013 01:45:35 -0700 ++ ++bumblebee (3.2.1-1) unstable; urgency=low + + [ Aron Xu ] + * Initial release (Closes: #659440). + * Thanks to Peter Lekensteyn and Bruno Pagani, most stuff taken from the + packaging for Ubuntu PPA. + + [ Vincent Cheng ] + * Thanks to Igor Urazov for lots of the Debian-specific portions of the + packaging. + - -- Aron Xu Mon, 14 Jan 2013 22:16:25 +0800 ++ -- Vincent Cheng Fri, 03 May 2013 03:04:38 -0700 diff --cc debian/control index 11c0934,0000000..5b79deb mode 100644,000000..100644 --- a/debian/control +++ b/debian/control @@@ -1,52 -1,0 +1,63 @@@ +Source: bumblebee +Section: utils - Priority: optional ++Priority: extra +Maintainer: Debian NVIDIA Maintainers +Uploaders: + Aron Xu , - Vincent Cheng , ++ Vincent Cheng , + Yunqiang Su +Build-Depends: debhelper (>= 9), libbsd-dev (>= 0.2.0), pkg-config, - libx11-dev, libglib2.0-dev, help2man - Standards-Version: 3.9.4 ++ libx11-dev, libglib2.0-dev, help2man, dh-systemd (>= 1.4) ++Standards-Version: 3.9.6 +Homepage: https://launchpad.net/~bumblebee +Vcs-Git: git://anonscm.debian.org/pkg-nvidia/bumblebee.git +Vcs-Browser: http://anonscm.debian.org/gitweb/?p=pkg-nvidia/bumblebee.git + +Package: bumblebee +Architecture: linux-any - Depends: ${shlibs:Depends}, ${misc:Depends}, bbswitch-dkms ++Pre-Depends: dpkg (>= 1.15.7.2) ++Depends: ${shlibs:Depends}, ${misc:Depends}, bbswitch-dkms | bbswitch-source +Recommends: virtualgl | primus +Suggests: bumblebee-nvidia (= ${binary:Version}) +Description: NVIDIA Optimus support for Linux + Bumblebee is an effort to make NVIDIA Optimus enabled laptops work in + GNU/Linux systems. These laptops are built in such a way that the NVIDIA + graphics card can be used on demand so that battery life is improved and + temperature is kept low. + . + It disables the discrete graphics card if no client is detected, and start + an X server making use of NVIDIA card if requested then let software GL + implementations (such as VirtualGL) copy frames to the visible display that + runs on the intergrated graphics. The ability to use discrete graphics + depends on the driver: open source nouveau and proprietary nvidia. + +Package: bumblebee-nvidia +Architecture: amd64 i386 +Section: contrib/utils +Depends: ${shlibs:Depends}, ${misc:Depends}, bumblebee (= ${binary:Version}), - nvidia-glx | nvidia-304 | nvidia-304-updates | nvidia-experimental-304 | ++# proprietary NVIDIA packages in Debian ++ nvidia-driver | nvidia-glx | nvidia-kernel-dkms | nvidia-kernel-amd64 | ++ nvidia-kernel-686-pae | nvidia-kernel-486 | ++# proprietary NVIDIA packages in Ubuntu ++ nvidia | nvidia-current | nvidia-current-updates | nvidia-driver-binary | ++ nvidia-304 | nvidia-304-updates | nvidia-experimental-304 | + nvidia-310 | nvidia-310-updates | nvidia-experimental-310 | - nvidia-313 | nvidia-313-updates | nvidia-experimental-313 - Recommends: virtualgl | primus-nvidia ++ nvidia-313 | nvidia-313-updates | nvidia-experimental-313 | ++ nvidia-319 | nvidia-319-updates | nvidia-experimental-319 | ++ nvidia-325 | nvidia-325-updates | nvidia-experimental-325 | ++ nvidia-331 | nvidia-331-updates | nvidia-experimental-331 | ++ nvidia-334 | nvidia-334-updates | nvidia-experimental-334 | ++ nvidia-337 | nvidia-337-updates | nvidia-experimental-337 | ++ nvidia-340 | nvidia-340-updates | nvidia-experimental-340 | ++ nvidia-343 | nvidia-343-updates | nvidia-experimental-343 +Description: NVIDIA Optimus support using the proprietary NVIDIA driver + This metapackage ensures that the proprietary NVIDIA driver is installed in a + way such that 3D acceleration does not break. It does so by configuring the + OpenGL library path to use the Mesa graphics library. + +Package: bumblebee-dbg - Priority: extra +Architecture: linux-any +Section: debug +Depends: ${misc:Depends}, bumblebee (= ${binary:Version}) +Description: NVIDIA Optimus support - debugging symbols + This package contains the debugging symbols for bumblebee. diff --cc debian/copyright index 38f6dd9,0000000..47a6ce6 mode 100644,000000..100644 --- a/debian/copyright +++ b/debian/copyright @@@ -1,32 -1,0 +1,32 @@@ +Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: bumblebee +Source: https://github.com/Bumblebee-Project/Bumblebee + +Files: * +Copyright: 2011-2013 Bumblebee Project +License: GPL-3.0+ + +Files: debian/* +Copyright: 2011-2013 Peter Lekensteyn + 2011-2013 Bruno Pagani + 2012 Igor Urazov + 2013 Aron Xu - 2013 Vincent Cheng ++ 2013 Vincent Cheng +License: GPL-3.0+ + +License: GPL-3.0+ + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + . + This package is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + . + You should have received a copy of the GNU General Public License + along with this program. If not, see . + . + On Debian systems, the complete text of the GNU General + Public License version 3 can be found in "/usr/share/common-licenses/GPL-3". diff --cc debian/patches/fix-device-detection.patch index 0000000,0000000..791ad63 new file mode 100644 --- /dev/null +++ b/debian/patches/fix-device-detection.patch @@@ -1,0 -1,0 +1,15 @@@ ++Description: Fix detection of devices on bus numbers larger than 9 ++Origin: upstream, https://github.com/Bumblebee-Project/Bumblebee/commit/2073f8537412aa47755eb6f3f22a114403e5285b ++Bug: https://github.com/Bumblebee-Project/Bumblebee/issues/573 ++ ++--- a/src/bbsecondary.c +++++ b/src/bbsecondary.c ++@@ -138,7 +138,7 @@ ++ if (!bb_is_running(bb_status.x_pid)) { ++ char pci_id[12]; ++ static char *x_conf_file; ++- snprintf(pci_id, 12, "PCI:%02x:%02x:%o", pci_bus_id_discrete->bus, +++ snprintf(pci_id, 12, "PCI:%02d:%02d:%o", pci_bus_id_discrete->bus, ++ pci_bus_id_discrete->slot, pci_bus_id_discrete->func); ++ if (!x_conf_file) { ++ x_conf_file = xorg_path_w_driver(bb_config.x_conf_file, bb_config.driver); diff --cc debian/patches/ignore-error-on-X-shutdown.patch index 0000000,0000000..323a333 new file mode 100644 --- /dev/null +++ b/debian/patches/ignore-error-on-X-shutdown.patch @@@ -1,0 -1,0 +1,15 @@@ ++Description: Ignore error on X shutdown ++Origin: upstream, https://github.com/Bumblebee-Project/Bumblebee/commit/25387e92822fb1a56fa43f1f9f636b987018d068 ++ ++--- a/src/bblogger.c +++++ b/src/bblogger.c ++@@ -144,7 +144,8 @@ ++ /* Error lines are errors. */ ++ if (strncmp(string, "(EE)", 4) == 0){ ++ if (strstr(string, "Failed to load module \"kbd\"") || ++- strstr(string, "No input driver matching")) { +++ strstr(string, "No input driver matching") || +++ strstr(string, "Server terminated successfully")) { ++ /* non-fatal errors */ ++ prio = LOG_DEBUG; ++ } else { diff --cc debian/patches/series index 05be462,0000000..d08ccb9 mode 100644,000000..100644 --- a/debian/patches/series +++ b/debian/patches/series @@@ -1,1 -1,0 +1,2 @@@ - 008-primus-libs-fix.patch ++fix-device-detection.patch ++ignore-error-on-X-shutdown.patch diff --cc debian/rules index fe4008f,0000000..34e1dea mode 100755,000000..100755 --- a/debian/rules +++ b/debian/rules @@@ -1,31 -1,0 +1,33 @@@ +#!/usr/bin/make -f +# -*- makefile -*- + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +%: - dh $@ ++ dh $@ --with systemd + +override_dh_auto_configure: +# Ubuntu and Debian's packaging of nvidia's proprietary driver differ greatly +ifeq ($(shell dpkg-vendor --derives-from Ubuntu && echo yes),yes) + dh_auto_configure -- \ + CONF_DRIVER_MODULE_NVIDIA=nvidia-current \ + CONF_LDPATH_NVIDIA=/usr/lib/nvidia-current:/usr/lib32/nvidia-current \ - CONF_MODPATH_NVIDIA=/usr/lib/nvidia-current/xorg,/usr/lib/xorg/modules ++ CONF_MODPATH_NVIDIA=/usr/lib/nvidia-current/xorg,/usr/lib/xorg/modules \ ++ CONF_PRIMUS_LD_PATH=/usr/lib/x86_64-linux-gnu/primus:/usr/lib/i386-linux-gnu/primus +else + dh_auto_configure -- \ - CONF_DRIVER_MODULE_NVIDIA=nvidia \ ++ CONF_DRIVER_MODULE_NVIDIA=nvidia-current \ + CONF_LDPATH_NVIDIA=/usr/lib/x86_64-linux-gnu/nvidia:/usr/lib/i386-linux-gnu/nvidia:/usr/lib/nvidia \ - CONF_MODPATH_NVIDIA=/usr/lib/nvidia,/usr/lib/xorg/modules ++ CONF_MODPATH_NVIDIA=/usr/lib/nvidia,/usr/lib/xorg/modules \ ++ CONF_PRIMUS_LD_PATH=/usr/lib/x86_64-linux-gnu/primus:/usr/lib/i386-linux-gnu/primus:/usr/lib/primus:/usr/lib32/primus +endif + +override_dh_auto_install: + dh_auto_install --destdir=debian/bumblebee/ + +override_dh_installinit: + dh_installinit --name=bumblebeed + +override_dh_strip: + dh_strip --dbg-package=bumblebee-dbg