The following commit has been merged in the master branch:
commit f2daa20786fe5c4f1ad5d24c710a96fe80f2449a
Author: Andres Mejia <[email protected]>
Date:   Sat May 5 17:20:52 2012 -0400

    Add dlopened libs as Recommends for libopenal1.

diff --git a/debian/control b/debian/control
index fc19193..2921d9b 100644
--- a/debian/control
+++ b/debian/control
@@ -53,6 +53,7 @@ Pre-Depends: ${misc:Pre-Depends}
 Depends: libopenal-data (= ${source:Version}),
          ${shlibs:Depends},
          ${misc:Depends}
+Recommends: ${shlibs:Recommends}
 Description: Software implementation of the OpenAL API (shared library)
  OpenAL, the Open Audio Library, is a joint effort to create an open,
  vendor-neutral, cross-platform API for interactive, primarily spatialized
diff --git a/debian/rules b/debian/rules
index 22e8370..a4b7cd1 100755
--- a/debian/rules
+++ b/debian/rules
@@ -7,6 +7,8 @@ else
    TYPE=Debug
 endif
 
+DEB_HOST_ARCH_OS ?= $(shell dpkg-architecture -qDEB_HOST_ARCH_OS)
+
 # For multiarch
 DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
 
@@ -23,6 +25,11 @@ DEB_CMAKE_OPTIONS ?= -DCMAKE_VERBOSE_MAKEFILE=ON \
 
 BUILD_TREE=$(CURDIR)/build-tree
 
+DLOPENED_LIBS = -lportaudio -lpulse -lsndio
+ifeq ($(DEB_HOST_ARCH_OS),linux)
+DLOPENED_LIBS += -lasound
+endif
+
 .PHONY: build
 %:
        dh $@ --parallel
@@ -44,5 +51,14 @@ override_dh_auto_build:
 override_dh_auto_install:
        $(MAKE) --directory=$(BUILD_TREE) install DESTDIR=$(CURDIR)/debian/tmp
 
+override_dh_shlibdeps: debian/tmp/openal-soft-dummy.so
+       dh_shlibdeps -O--parallel
+       # Need to manually add dependencies for dlopened libs.
+       dpkg-shlibdeps -dRecommends -edebian/tmp/openal-soft-dummy.so -xlibc6 
-O >>debian/libopenal1.substvars
+
+debian/tmp/openal-soft-dummy.so:
+       mkdir -p debian/tmp
+       cc -xc -shared -Wl,--no-as-needed -o $@ /dev/null $(DLOPENED_LIBS)
+
 get-orig-source:
        $(dir $_)openal-soft-get-orig-source

-- 
Packaging for openal-soft

_______________________________________________
Pkg-games-commits mailing list
[email protected]
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-games-commits

Reply via email to