mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-21 19:20:08 +02:00
OpenAL: some sanity fixes
* Fix various install pathes * Use out-of-source build as specified in OpenAL readme, as otherwise rebuilding from an unclean sourcetree fails * Safer patching of the binary output dir.
This commit is contained in:
@@ -5,7 +5,7 @@ OpenAL - A software implementation of the OpenAL 3D audio API.
|
||||
HOMEPAGE="http://kcat.strangesoft.net/openal.html"
|
||||
SRC_URI="http://kcat.strangesoft.net/openal-releases/openal-soft-1.13.tar.bz2"
|
||||
CHECKSUM_MD5="58b7d2809790c70681b825644c5f3614"
|
||||
REVISION="1"
|
||||
REVISION="2"
|
||||
LICENSE="GNU LGPL v2.1"
|
||||
COPYRIGHT="1999-2000 Loki Software
|
||||
2005-2011 OpenAL Soft team"
|
||||
@@ -34,24 +34,26 @@ BUILD_PREREQUIRES="
|
||||
"
|
||||
|
||||
SOURCE_DIR="openal-soft-1.13"
|
||||
|
||||
|
||||
PATCHES="openal-1.13.0.patchset"
|
||||
BUILD()
|
||||
{
|
||||
sed -i "s,RUNTIME DESTINATION bin,RUNTIME DESTINATION $relativeBinDir," CMakeLists.txt
|
||||
cmake . -DCMAKE_INSTALL_PREFIX=$prefix \
|
||||
-DLIB_SUFFIX="/${secondaryArchSuffix/_/}"
|
||||
cd build
|
||||
cmake .. -DCMAKE_INSTALL_PREFIX=$prefix -DBIN_DIR="$relativeBinDir" \
|
||||
-DLIB_SUFFIX="/${secondaryArchSuffix/_/}"
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
cd build
|
||||
make install
|
||||
|
||||
mkdir -p $developDir/headers
|
||||
mkdir -p $binDir
|
||||
mv $prefix/include $developDir/headers
|
||||
|
||||
prepareInstalledDevelLibs libopenal
|
||||
mv $prefix/include/* $developDir/headers
|
||||
rmdir $prefix/include
|
||||
|
||||
prepareInstalledDevelLib libopenal
|
||||
fixPkgconfig
|
||||
|
||||
# devel package
|
||||
|
||||
@@ -1,7 +1,14 @@
|
||||
diff -Naur openal-soft-1.13/Alc/ALc.c openal-soft-1.13-haiku/Alc/ALc.c
|
||||
--- openal-soft-1.13/Alc/ALc.c 2011-02-09 17:52:19.006291456 -0200
|
||||
+++ openal-soft-1.13-haiku/Alc/ALc.c 2011-05-02 01:08:32.000000000 -0300
|
||||
@@ -60,6 +60,9 @@
|
||||
From b755a676e918041fe3320e5e6bfa061b3b892994 Mon Sep 17 00:00:00 2001
|
||||
From: Adrien Destugues <pulkomandy@pulkomandy.tk>
|
||||
Date: Tue, 28 Jan 2014 09:17:21 +0100
|
||||
Subject: applying patch openal-1.13.patch
|
||||
|
||||
|
||||
diff --git a/Alc/ALc.c b/Alc/ALc.c
|
||||
index 6bdcc66..c8b2af4 100644
|
||||
--- a/Alc/ALc.c
|
||||
+++ b/Alc/ALc.c
|
||||
@@ -60,6 +60,9 @@ static BackendInfo BackendList[] = {
|
||||
#ifdef HAVE_SOLARIS
|
||||
{ "solaris", alc_solaris_init, alc_solaris_deinit, alc_solaris_probe, EmptyFuncs },
|
||||
#endif
|
||||
@@ -11,9 +18,11 @@ diff -Naur openal-soft-1.13/Alc/ALc.c openal-soft-1.13-haiku/Alc/ALc.c
|
||||
#ifdef HAVE_DSOUND
|
||||
{ "dsound", alcDSoundInit, alcDSoundDeinit, alcDSoundProbe, EmptyFuncs },
|
||||
#endif
|
||||
diff -Naur openal-soft-1.13/Alc/haiku.cpp openal-soft-1.13-haiku/Alc/haiku.cpp
|
||||
--- openal-soft-1.13/Alc/haiku.cpp 1969-12-31 21:00:00.000000000 -0300
|
||||
+++ openal-soft-1.13-haiku/Alc/haiku.cpp 2011-05-02 01:06:54.000000000 -0300
|
||||
diff --git a/Alc/haiku.cpp b/Alc/haiku.cpp
|
||||
new file mode 100644
|
||||
index 0000000..c66e99d
|
||||
--- /dev/null
|
||||
+++ b/Alc/haiku.cpp
|
||||
@@ -0,0 +1,214 @@
|
||||
+/**
|
||||
+ * OpenAL cross platform audio library
|
||||
@@ -229,10 +238,11 @@ diff -Naur openal-soft-1.13/Alc/haiku.cpp openal-soft-1.13-haiku/Alc/haiku.cpp
|
||||
+ (void)lSamples;
|
||||
+}
|
||||
+
|
||||
diff -Naur openal-soft-1.13/CMakeLists.txt openal-soft-1.13-haiku/CMakeLists.txt
|
||||
--- openal-soft-1.13/CMakeLists.txt 2011-02-15 18:05:40.000000000 -0200
|
||||
+++ openal-soft-1.13-haiku/CMakeLists.txt 2011-05-02 01:08:32.000000000 -0300
|
||||
@@ -16,10 +16,12 @@
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 44f9ea8..ffbe13b 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -16,10 +16,12 @@ INCLUDE(CheckIncludeFiles)
|
||||
INCLUDE(CheckSymbolExists)
|
||||
INCLUDE(CheckCCompilerFlag)
|
||||
INCLUDE(CheckCSourceCompiles)
|
||||
@@ -246,7 +256,7 @@ diff -Naur openal-soft-1.13/CMakeLists.txt openal-soft-1.13-haiku/CMakeLists.txt
|
||||
|
||||
|
||||
SET(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS TRUE)
|
||||
@@ -28,6 +30,7 @@
|
||||
@@ -28,6 +30,7 @@ SET(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS TRUE)
|
||||
OPTION(ALSA "Check for ALSA backend" ON)
|
||||
OPTION(OSS "Check for OSS backend" ON)
|
||||
OPTION(SOLARIS "Check for Solaris backend" ON)
|
||||
@@ -254,7 +264,7 @@ diff -Naur openal-soft-1.13/CMakeLists.txt openal-soft-1.13-haiku/CMakeLists.txt
|
||||
OPTION(DSOUND "Check for DirectSound backend" ON)
|
||||
OPTION(WINMM "Check for Windows Multimedia backend" ON)
|
||||
OPTION(PORTAUDIO "Check for PortAudio backend" ON)
|
||||
@@ -334,6 +337,7 @@
|
||||
@@ -334,6 +337,7 @@ SET(BACKENDS "")
|
||||
SET(HAVE_ALSA 0)
|
||||
SET(HAVE_OSS 0)
|
||||
SET(HAVE_SOLARIS 0)
|
||||
@@ -262,7 +272,7 @@ diff -Naur openal-soft-1.13/CMakeLists.txt openal-soft-1.13-haiku/CMakeLists.txt
|
||||
SET(HAVE_DSOUND 0)
|
||||
SET(HAVE_WINMM 0)
|
||||
SET(HAVE_PORTAUDIO 0)
|
||||
@@ -378,6 +382,24 @@
|
||||
@@ -378,6 +382,24 @@ IF(SOLARIS)
|
||||
ENDIF()
|
||||
ENDIF()
|
||||
|
||||
@@ -287,10 +297,11 @@ diff -Naur openal-soft-1.13/CMakeLists.txt openal-soft-1.13-haiku/CMakeLists.txt
|
||||
# Check DSound/MMSystem backend
|
||||
IF(DSOUND)
|
||||
CHECK_INCLUDE_FILE(dsound.h HAVE_DSOUND_H)
|
||||
diff -Naur openal-soft-1.13/OpenAL32/Include/alMain.h openal-soft-1.13-haiku/OpenAL32/Include/alMain.h
|
||||
--- openal-soft-1.13/OpenAL32/Include/alMain.h 2011-02-09 17:50:49.001835008 -0200
|
||||
+++ openal-soft-1.13-haiku/OpenAL32/Include/alMain.h 2011-05-02 01:08:32.000000000 -0300
|
||||
@@ -276,6 +276,9 @@
|
||||
diff --git a/OpenAL32/Include/alMain.h b/OpenAL32/Include/alMain.h
|
||||
index 02153a8..e3b357a 100644
|
||||
--- a/OpenAL32/Include/alMain.h
|
||||
+++ b/OpenAL32/Include/alMain.h
|
||||
@@ -276,6 +276,9 @@ void alc_oss_probe(int type);
|
||||
void alc_solaris_init(BackendFuncs *func_list);
|
||||
void alc_solaris_deinit(void);
|
||||
void alc_solaris_probe(int type);
|
||||
@@ -300,9 +311,10 @@ diff -Naur openal-soft-1.13/OpenAL32/Include/alMain.h openal-soft-1.13-haiku/Ope
|
||||
void alcDSoundInit(BackendFuncs *func_list);
|
||||
void alcDSoundDeinit(void);
|
||||
void alcDSoundProbe(int type);
|
||||
diff -Naur openal-soft-1.13/config.h.in openal-soft-1.13-haiku/config.h.in
|
||||
--- openal-soft-1.13/config.h.in 2010-06-08 05:56:28.066846720 -0300
|
||||
+++ openal-soft-1.13-haiku/config.h.in 2011-05-02 01:08:32.000000000 -0300
|
||||
diff --git a/config.h.in b/config.h.in
|
||||
index 3c1e7e6..27a19cf 100644
|
||||
--- a/config.h.in
|
||||
+++ b/config.h.in
|
||||
@@ -13,6 +13,9 @@
|
||||
/* Define if we have the Solaris backend */
|
||||
#cmakedefine HAVE_SOLARIS
|
||||
@@ -313,3 +325,46 @@ diff -Naur openal-soft-1.13/config.h.in openal-soft-1.13-haiku/config.h.in
|
||||
/* Define if we have the DSound backend */
|
||||
#cmakedefine HAVE_DSOUND
|
||||
|
||||
--
|
||||
1.8.3.4
|
||||
|
||||
|
||||
From af8af1218c33e188372b600c4c0bfefc616b43e6 Mon Sep 17 00:00:00 2001
|
||||
From: Adrien Destugues <pulkomandy@pulkomandy.tk>
|
||||
Date: Tue, 28 Jan 2014 09:22:49 +0100
|
||||
Subject: Make bin directory a variable.
|
||||
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index ffbe13b..a060122 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -488,6 +488,7 @@ SET(libdir "\${exec_prefix}/lib${LIB_SUFFIX}")
|
||||
SET(bindir "\${exec_prefix}/bin")
|
||||
SET(includedir "\${prefix}/include")
|
||||
SET(PACKAGE_VERSION "${LIB_VERSION}")
|
||||
+SET(BIN_DIR "bin" CACHE STRING "relative dir where to put executables")
|
||||
|
||||
# End configuration
|
||||
CONFIGURE_FILE(
|
||||
@@ -512,7 +513,7 @@ TARGET_LINK_LIBRARIES(${LIBNAME} ${EXTRA_LIBS})
|
||||
|
||||
# Add an install target here
|
||||
INSTALL(TARGETS ${LIBNAME}
|
||||
- RUNTIME DESTINATION bin
|
||||
+ RUNTIME DESTINATION "${BIN_DIR}"
|
||||
LIBRARY DESTINATION "lib${LIB_SUFFIX}"
|
||||
ARCHIVE DESTINATION "lib${LIB_SUFFIX}"
|
||||
)
|
||||
@@ -554,7 +555,7 @@ IF(UTILS)
|
||||
ADD_EXECUTABLE(openal-info utils/openal-info.c)
|
||||
TARGET_LINK_LIBRARIES(openal-info ${LIBNAME})
|
||||
INSTALL(TARGETS openal-info
|
||||
- RUNTIME DESTINATION bin
|
||||
+ RUNTIME DESTINATION "${BIN_DIR}"
|
||||
LIBRARY DESTINATION "lib${LIB_SUFFIX}"
|
||||
ARCHIVE DESTINATION "lib${LIB_SUFFIX}"
|
||||
)
|
||||
--
|
||||
1.8.3.4
|
||||
|
||||
Reference in New Issue
Block a user