diff options
author | eroen <eroen@occam.eroen.eu> | 2013-06-24 19:16:33 +0200 |
---|---|---|
committer | eroen <eroen@occam.eroen.eu> | 2013-06-24 19:16:33 +0200 |
commit | 060e9679544c797f842cc5accdff813050bb5db5 (patch) | |
tree | 890f1588b4a09749b27d6733d0df87570d507975 /media-libs | |
parent | ruby-1.8.7_p371 - eapi5, multilib (diff) | |
download | eroen-060e9679544c797f842cc5accdff813050bb5db5.tar.gz eroen-060e9679544c797f842cc5accdff813050bb5db5.tar.bz2 eroen-060e9679544c797f842cc5accdff813050bb5db5.zip |
libsdl-2.0.0_pre7304 from gamerlay
Diffstat (limited to 'media-libs')
-rw-r--r-- | media-libs/libsdl/Manifest | 6 | ||||
-rw-r--r-- | media-libs/libsdl/files/libsdl-add-libtool-export-cmake-v2.patch | 54 | ||||
-rw-r--r-- | media-libs/libsdl/files/libsdl-universal_sizeof_voidp.patch | 18 | ||||
-rw-r--r-- | media-libs/libsdl/files/libsdl-universal_xdata32_check.patch | 49 | ||||
-rw-r--r-- | media-libs/libsdl/libsdl-2.0.0_pre7304.ebuild | 122 | ||||
-rw-r--r-- | media-libs/libsdl/metadata.xml | 37 |
6 files changed, 286 insertions, 0 deletions
diff --git a/media-libs/libsdl/Manifest b/media-libs/libsdl/Manifest new file mode 100644 index 0000000..cb12a85 --- /dev/null +++ b/media-libs/libsdl/Manifest @@ -0,0 +1,6 @@ +AUX libsdl-add-libtool-export-cmake-v2.patch 1857 SHA256 b533e84f49a9d5f946ca0ec3be5a245e32ea0cbbd84c9b1ca2cbfd1dea161d64 SHA512 24739bf7bf7720695c6d758f65675609ad32f7118b7c262b6b89056ee959cca33888cde9659bcc5688431994e1da84b577fba75fba6ce60ca6d534b3c47852df WHIRLPOOL 931da494bf855701b96af95ec27a9d3862646c11ee3fb79ada5cfc668b6ab08c364d2d227f9bf1ec19affd935c8b13d0a3a7b4280f45df9c81e1ed3319b6d55a +AUX libsdl-universal_sizeof_voidp.patch 620 SHA256 c3025530ffc276a08528a884dc1843f09236529b879e651001050a8a00889ba3 SHA512 38a4c786206bd53bc926fd0cb916c373489442d005c31b0e9f7f70627002b78e46cdeae45c5dfd53e7abe16d20112aca5c72d1eb291673dbb5fd65db7fc92ac8 WHIRLPOOL 6c295273fec479ee59a48cd5496fe09c902bb5ff224726e3a0f7e15c8359bd59baf7b0c34400e97687c5315a0336436637d4ec2d9e2d7cedf89d85f62ec42aea +AUX libsdl-universal_xdata32_check.patch 2047 SHA256 591c15b4dda2f2a2bcdaceb17db57e5209d5bbc8fb529cbd295f24818dc09bc6 SHA512 d8c0557094bb831ada0bf59aaf7d7782e2ada7bed34e9c70aa19ec0f56e53bab23cab5542b9c66414d69acc9393dcb392148b8d22ec4c098712df3df8018ed7b WHIRLPOOL ecdb4f69217840a00dee550332b0be3dfbc3a7b60c10578a0ce1a370e1b65d391234c8f01f5cbb357bea885f426460429129ee742e1844f79efb5a4999cdce21 +DIST SDL-2.0.0-7304.tar.gz 4397624 SHA256 555d4d1f242d121f8ff46a18fdf17a14130db5f8cda947e5b8d966fa6a517285 SHA512 7678a4a2511708d9d88db0027a77143b3c0c235e40e58d98cc19a8f0aab1c133a4ec8de2316beb9e685bc37f92174aab8d0d5561554a5afff0241579ded143ca WHIRLPOOL cc2ff1a1de2c1c0ef68ffaadbb4792c1b1d7f18722d12bf508a7a55f8bfbf60fa36f341cee99a33d38fc86c8745714502981b5f7e147a7b56d78aa1b03b9d045 +EBUILD libsdl-2.0.0_pre7304.ebuild 3554 SHA256 8813ff086d9ce11e517ebbeae2add7a062e7aa65cb50f59acd2262e6cd23841b SHA512 ec5c66a70514cd062505afe35685fc791bc9c95a626c686628bba3a2f7568a072ca34e5e829c7fb04cd58acbffda76e343efdd950dc64637b440ce5e833d3d53 WHIRLPOOL bc35878facdc5c9b06af32e6e547beeda5673c8a0aa9f6e475816566c5e3e695e30443868f38840d9a18d1debf5dfe791c1867bba719cd79b203082089dea3c8 +MISC metadata.xml 1748 SHA256 e5cb522593b21398c5ee78e508aedc2c9c6b9ae2972bf112ac2ddc536e4d4c73 SHA512 7307321b5d3c3198a7e6111eaa4235e3caa03e15cd065b12cd75312a4da95e4cef6294ca9a717c48da8fc505cc65df128aff92390b204e19cb33bf7751a3a8c9 WHIRLPOOL 3a493729bb5ea3400ea80e4697f655047a0d5a46fa03dd40cf79be7df09eaff56901da1d041a57e30cc3a4dccca8f95a3fc2fa8e1fb8ee81a84ebf69e55e709d diff --git a/media-libs/libsdl/files/libsdl-add-libtool-export-cmake-v2.patch b/media-libs/libsdl/files/libsdl-add-libtool-export-cmake-v2.patch new file mode 100644 index 0000000..4a072b6 --- /dev/null +++ b/media-libs/libsdl/files/libsdl-add-libtool-export-cmake-v2.patch @@ -0,0 +1,54 @@ +# HG changeset patch +# User David Gow <david@ingeniumdigital.com> +# Date 1362822158 -28800 +# Node ID e4ce88b90d6079ed1ef0c4bd40abd652e475a8fc +# Parent 792af948ee02e474d9077389cde5396d8101b448 +Emulate libtool's release option in CMake + +diff -r 792af948ee02 -r e4ce88b90d60 CMakeLists.txt +--- a/CMakeLists.txt Sat Mar 09 16:55:02 2013 +0800 ++++ b/CMakeLists.txt Sat Mar 09 17:42:38 2013 +0800 +@@ -38,6 +38,8 @@ + math(EXPR LT_CURRENT "${SDL_MICRO_VERSION} - ${SDL_INTERFACE_AGE}") + math(EXPR LT_AGE "${SDL_BINARY_AGE} - ${SDL_INTERFACE_AGE}") + set(LT_REVISION "${SDL_INTERFACE_AGE}") ++set(LT_RELEASE "${SDL_MAJOR_VERSION}.${SDL_MINOR_VERSION}") ++set(LT_VERSION "${LT_CURRENT}.${LT_REVISION}.${LT_AGE}") + + # General settings & flags + set(LIBRARY_OUTPUT_DIRECTORY "build") +@@ -1135,9 +1137,17 @@ + + if(SDL_SHARED) + add_library(SDL2 SHARED ${SOURCE_FILES}) +- set_target_properties(SDL2 PROPERTIES +- VERSION ${SDL_VERSION} +- SOVERSION ${LT_CURRENT}) ++ if(UNIX) ++ set_target_properties(SDL2 PROPERTIES ++ VERSION ${LT_VERSION} ++ SOVERSION ${LT_CURRENT} ++ OUTPUT_NAME "SDL2-${LT_RELEASE}") ++ else(UNIX) ++ set_target_properties(SDL2 PROPERTIES ++ VERSION ${SDL_VERSION} ++ SOVERSION ${LT_CURRENT} ++ OUTPUT_NAME "SDL2") ++ endif(UNIX) + set(_INSTALL_LIBS "SDL2" ${_INSTALL_LIBS}) + target_link_libraries(SDL2 ${EXTRA_LIBS} ${EXTRA_LDFLAGS}) + endif(SDL_SHARED) +@@ -1165,6 +1175,13 @@ + list(APPEND INCLUDE_FILES ${BIN_INCLUDE_FILES}) + install(FILES ${INCLUDE_FILES} DESTINATION include/SDL2) + ++if(SDL_SHARED) ++ install(CODE " ++ execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink ++ \"libSDL2-2.0.so\" \"libSDL2.so\")") ++ install(FILES ${SDL2_BINARY_DIR}/libSDL2.so DESTINATION "lib${LIB_SUFFIX}") ++endif(SDL_SHARED) ++ + if(NOT WINDOWS OR CYGWIN) + if(FREEBSD) + # FreeBSD uses ${PREFIX}/libdata/pkgconfig diff --git a/media-libs/libsdl/files/libsdl-universal_sizeof_voidp.patch b/media-libs/libsdl/files/libsdl-universal_sizeof_voidp.patch new file mode 100644 index 0000000..8d9ecea --- /dev/null +++ b/media-libs/libsdl/files/libsdl-universal_sizeof_voidp.patch @@ -0,0 +1,18 @@ +diff -r fe82d15464d1 include/SDL_config.h.cmake +--- a/include/SDL_config.h.cmake Sun Mar 17 09:47:25 2013 -0700 ++++ b/include/SDL_config.h.cmake Mon Mar 18 20:31:51 2013 +0600 +@@ -37,7 +37,13 @@ + #cmakedefine volatile @HAVE_VOLATILE@ + + /* C datatypes */ +-#cmakedefine SIZEOF_VOIDP @SIZEOF_VOIDP@ ++/* Define SIZEOF_VOIDP for 64/32 architectures */ ++#ifdef __LP64__ ++#define SIZEOF_VOIDP 8 ++#else ++#define SIZEOF_VOIDP 4 ++#endif ++ + #cmakedefine HAVE_GCC_ATOMICS @HAVE_GCC_ATOMICS@ + #cmakedefine HAVE_GCC_SYNC_LOCK_TEST_AND_SET @HAVE_GCC_SYNC_LOCK_TEST_AND_SET@ + #cmakedefine HAVE_PTHREAD_SPINLOCK @HAVE_PTHREAD_SPINLOCK@ diff --git a/media-libs/libsdl/files/libsdl-universal_xdata32_check.patch b/media-libs/libsdl/files/libsdl-universal_xdata32_check.patch new file mode 100644 index 0000000..d741025 --- /dev/null +++ b/media-libs/libsdl/files/libsdl-universal_xdata32_check.patch @@ -0,0 +1,49 @@ +# HG changeset patch +# User Azamat H. Hackimov <azamat.hackimov@gmail.com> +# Date 1370413935 -21600 +# Node ID 00d5ada80b60f6e163a2ebbb5949515dd9646458 +# Parent 2a858d938e21eb4f6f4496f29557a1fa14b566b4 +Make _XData32 checking universal for 32 and 64 architectures. +_XData32 is used only for 64, so there should be no regression in 32bit +enviroment. +This commit intended for making universal SDL_config.h in mixed 32/64 +enviroment. + +diff -r 2a858d938e21 -r 00d5ada80b60 cmake/sdlchecks.cmake +--- a/cmake/sdlchecks.cmake Wed Jun 05 12:28:53 2013 +0600 ++++ b/cmake/sdlchecks.cmake Wed Jun 05 12:32:15 2013 +0600 +@@ -357,6 +357,7 @@ + endif(HAVE_XGENERICEVENT) + + check_c_source_compiles(" ++ #define LONG64 + #include <X11/Xlibint.h> + extern int _XData32(Display *dpy,register _Xconst long *data,unsigned len); + int main(int argc, char **argv) {}" HAVE_CONST_XDATA32) +diff -r 2a858d938e21 -r 00d5ada80b60 configure.in +--- a/configure.in Wed Jun 05 12:28:53 2013 +0600 ++++ b/configure.in Wed Jun 05 12:32:15 2013 +0600 +@@ -1147,14 +1147,15 @@ + AC_MSG_CHECKING(for const parameter to _XData32) + have_const_param_xdata32=no + AC_TRY_COMPILE([ +- #include <X11/Xlibint.h> +- extern int _XData32(Display *dpy,register _Xconst long *data,unsigned len); +- ],[ +- ],[ +- have_const_param_xdata32=yes +- AC_DEFINE(SDL_VIDEO_DRIVER_X11_CONST_PARAM_XDATA32) +- ]) +- AC_MSG_RESULT($have_const_param_xdata32) ++ #define LONG64 ++ #include <X11/Xlibint.h> ++ extern int _XData32(Display *dpy,register _Xconst long *data,unsigned len); ++ ],[ ++ ],[ ++ have_const_param_xdata32=yes ++ AC_DEFINE(SDL_VIDEO_DRIVER_X11_CONST_PARAM_XDATA32) ++ ]) ++ AC_MSG_RESULT($have_const_param_xdata32) + + dnl AC_CHECK_LIB(X11, XGetEventData, AC_DEFINE(SDL_VIDEO_DRIVER_X11_SUPPORTS_GENERIC_EVENTS, 1, [Have XGenericEvent])) + AC_MSG_CHECKING([for XGenericEvent]) diff --git a/media-libs/libsdl/libsdl-2.0.0_pre7304.ebuild b/media-libs/libsdl/libsdl-2.0.0_pre7304.ebuild new file mode 100644 index 0000000..e1c0338 --- /dev/null +++ b/media-libs/libsdl/libsdl-2.0.0_pre7304.ebuild @@ -0,0 +1,122 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +EAPI=5 + +inherit cmake-multilib eutils + +MY_PV=${PV/_pre/-} + +DESCRIPTION="Simple Direct Media Layer" +HOMEPAGE="http://www.libsdl.org/" +SRC_URI="http://www.libsdl.org/tmp/SDL-${MY_PV}.tar.gz" +LICENSE="ZLIB" +SLOT="2" +KEYWORDS="~amd64 ~x86" +IUSE="3dnow alsa altivec +asm aqua fusionsound gles mmx nas opengl oss pulseaudio sse sse2 static-libs +threads tslib +video X xinerama xscreensaver" + +#FIXME: Replace "gles" deps with "virtual/opengles", after hitting Portage. +#FIXME: media-libs/nas no have emul-* ebuild +#FIXME: virtual/opengl for abi_x86_32 require additional handling +RDEPEND=" + nas? ( + media-libs/nas + x11-libs/libX11 + x11-libs/libXext + x11-libs/libXt + ) + X? ( + x11-libs/libX11 + x11-libs/libXcursor + x11-libs/libXext + x11-libs/libXi + x11-libs/libXt + x11-libs/libXrandr + x11-libs/libXrender + x11-libs/libXxf86vm + ) + xinerama? ( x11-libs/libXinerama ) + xscreensaver? ( x11-libs/libXScrnSaver ) + alsa? ( media-libs/alsa-lib ) + fusionsound? ( >=media-libs/FusionSound-1.1.1 ) + pulseaudio? ( >=media-sound/pulseaudio-0.9 ) + gles? ( || ( media-libs/mesa[gles2] media-libs/mesa[gles] ) ) + opengl? ( virtual/opengl ) + tslib? ( x11-libs/tslib ) +" + +DEPEND="${RDEPEND} + nas? ( + x11-proto/xextproto + x11-proto/xproto + ) + X? ( + x11-proto/inputproto + x11-proto/xextproto + x11-proto/xf86vidmodeproto + x11-proto/xproto + x11-proto/randrproto + x11-proto/renderproto + ) + xinerama? ( x11-proto/xineramaproto ) + xscreensaver? ( x11-proto/scrnsaverproto ) +" + +S="${WORKDIR}/SDL-${MY_PV}" + +DOCS=( BUGS.txt CREDITS.txt README.txt README-hg.txt README-SDL.txt TODO.txt WhatsNew.txt ) + +src_prepare() { + # Currently cmake produce libsdl2.so targets, + # but libtool libsdl2-2.0.so, so many applications (e.g. Steam) fails to + # find system libsdl. This patch workaround this problem. + # See http://bugzilla.libsdl.org/show_bug.cgi?id=1743 + epatch "${FILESDIR}/${PN}-add-libtool-export-cmake-v2.patch" + # Make headers more universal for 32/64 archs. + # See http://bugzilla.libsdl.org/show_bug.cgi?id=1893 + epatch "${FILESDIR}/${PN}-universal_sizeof_voidp.patch" + epatch "${FILESDIR}/${PN}-universal_xdata32_check.patch" + + epatch_user +} + +src_configure() { + mycmakeargs=( + # Disable assertion tests. + -DASSERTIONS=disabled + # Avoid hard-coding RPATH entries into dynamically linked SDL libraries. + -DRPATH=NO + # Disable obsolete and/or inapplicable libraries. + -DARTS=NO + -DESD=NO + $(cmake-utils_use 3dnow 3DNOW) + $(cmake-utils_use alsa ALSA) + $(cmake-utils_use altivec ALTIVEC) + $(cmake-utils_use asm ASSEMBLY) + $(cmake-utils_use aqua VIDEO_COCOA) + $(cmake-utils_use fusionsound FUSIONSOUND) + $(cmake-utils_use gles VIDEO_OPENGLES) + $(cmake-utils_use mmx MMX) + $(cmake-utils_use nas NAS) + $(cmake-utils_use opengl VIDEO_OPENGL) + $(cmake-utils_use oss OSS) + $(cmake-utils_use pulseaudio PULSEAUDIO) + $(cmake-utils_use threads PTHREADS) + $(cmake-utils_use sse SSE) + $(cmake-utils_use sse SSEMATH) + $(cmake-utils_use sse2 SSE2) + $(cmake-utils_use static-libs SDL_STATIC) + $(cmake-utils_use tslib INPUT_TSLIB) + $(cmake-utils_use video VIDEO_DUMMY) + $(cmake-utils_use X VIDEO_X11) + $(cmake-utils_use X VIDEO_X11_XCURSOR) + $(cmake-utils_use X VIDEO_X11_XINERAMA) + $(cmake-utils_use X VIDEO_X11_XINPUT) + $(cmake-utils_use X VIDEO_X11_XRANDR) + $(cmake-utils_use xscreensaver VIDEO_X11_XSCRNSAVER) + $(cmake-utils_use X VIDEO_X11_XVM) + #$(cmake-utils_use joystick SDL_JOYSTICK) + ) + cmake-multilib_src_configure +} diff --git a/media-libs/libsdl/metadata.xml b/media-libs/libsdl/metadata.xml new file mode 100644 index 0000000..6a3aa9f --- /dev/null +++ b/media-libs/libsdl/metadata.xml @@ -0,0 +1,37 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer> + <email>azamat.hackimov@gmail.com</email> + <name>Azamat H. Hackimov</name> + </maintainer> + <longdescription> +Simple DirectMedia Layer is a cross-platform multimedia library designed +to provide low level access to audio, keyboard, mouse, joystick, 3D +hardware via OpenGL, and 2D video framebuffer. It is used by MPEG +playback software, emulators, and many popular games, including the +award winning Linux port of "Civilization: Call To Power." + +SDL supports Linux, Windows, Windows CE, BeOS, MacOS, MacOS X, FreeBSD, +NetBSD, OpenBSD, BSD/OS, Solaris, IRIX, and QNX. The code also contains +support for AmigaOS, Dreamcast, Atari, AIX, OSF/Tru64, RISC OS, +SymbianOS, and OS/2, but these are not officially supported. + +SDL is written in C, but works with C++ natively, and has bindings to +several other languages, including Ada, C#, D, Eiffel, Erlang, Euphoria, +Go, Guile, Haskell, Java, Lisp, Lua, ML, Objective C, Pascal, Perl, PHP, +Pike, Pliant, Python, Ruby, Smalltalk, and Tcl. +</longdescription> + <upstream> + <doc lang="en">http://www.libsdl.org/cgi/docwiki.cgi</doc> + <bugs-to>http://bugzilla.libsdl.org</bugs-to> + </upstream> + <use> + <!--flag name="directx">Adds support for Windows DirectX audio and video</flag--> + <flag name="asm">Enable assembly for optimization (3dnow, mmx, sse, sse2)</flag> + <flag name="fusionsound">Enable FusionSound audio support</flag> + <flag name="gles">Enable OpenGL ES video support</flag> + <flag name="tslib">Enable tslib-based touchscreen device support</flag> + <flag name="video">Control video support (disable at your own risk)</flag> + </use> +</pkgmetadata> |