summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaciej Mrozowski <reavertm@gentoo.org>2012-09-21 22:37:18 +0000
committerMaciej Mrozowski <reavertm@gentoo.org>2012-09-21 22:37:18 +0000
commit852c00bd9c34565d8ac0054186813963821d9092 (patch)
tree0191fe158bd8b5f6e61dd7df0d7fd6dcc9da6286 /dev-games
parentVersion bump. (diff)
downloadgentoo-2-852c00bd9c34565d8ac0054186813963821d9092.tar.gz
gentoo-2-852c00bd9c34565d8ac0054186813963821d9092.tar.bz2
gentoo-2-852c00bd9c34565d8ac0054186813963821d9092.zip
Unbundle expat, bug 253514. Drop obsolete patch.
(Portage version: 2.2.0_alpha128/cvs/Linux x86_64)
Diffstat (limited to 'dev-games')
-rw-r--r--dev-games/simgear/ChangeLog9
-rw-r--r--dev-games/simgear/files/simgear-2.8.0-unbundle-expat.patch141
-rw-r--r--dev-games/simgear/files/simgear-2.8.0-underlinking.patch17
-rw-r--r--dev-games/simgear/simgear-2.8.0-r1.ebuild (renamed from dev-games/simgear/simgear-2.8.0.ebuild)12
4 files changed, 156 insertions, 23 deletions
diff --git a/dev-games/simgear/ChangeLog b/dev-games/simgear/ChangeLog
index 74b5e6acd916..0d5ad013e42b 100644
--- a/dev-games/simgear/ChangeLog
+++ b/dev-games/simgear/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for dev-games/simgear
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-games/simgear/ChangeLog,v 1.53 2012/08/31 21:25:05 reavertm Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-games/simgear/ChangeLog,v 1.54 2012/09/21 22:37:18 reavertm Exp $
+
+*simgear-2.8.0-r1 (21 Sep 2012)
+
+ 21 Sep 2012; Maciej Mrozowski <reavertm@gentoo.org>
+ +files/simgear-2.8.0-unbundle-expat.patch, +simgear-2.8.0-r1.ebuild,
+ -files/simgear-2.8.0-underlinking.patch, -simgear-2.8.0.ebuild:
+ Unbundle expat, bug 253514. Drop obsolete patch.
31 Aug 2012; Maciej Mrozowski <reavertm@gentoo.org> simgear-2.8.0.ebuild:
Remove plib dependency, bug 433143.
diff --git a/dev-games/simgear/files/simgear-2.8.0-unbundle-expat.patch b/dev-games/simgear/files/simgear-2.8.0-unbundle-expat.patch
new file mode 100644
index 000000000000..f9b8b6068111
--- /dev/null
+++ b/dev-games/simgear/files/simgear-2.8.0-unbundle-expat.patch
@@ -0,0 +1,141 @@
+diff -ruN simgear-2.8.0/CMakeLists.txt my/CMakeLists.txt
+--- simgear-2.8.0/CMakeLists.txt 2012-08-16 16:20:28.000000000 +0200
++++ my/CMakeLists.txt 2012-09-22 00:25:49.814097209 +0200
+@@ -66,6 +66,7 @@
+ option(ENABLE_LIBSVN "Set to ON to build SimGear with libsvnclient support" ON)
+ option(ENABLE_RTI "Set to ON to build SimGear with RTI support" OFF)
+ option(ENABLE_TESTS "Set to OFF to disable building SimGear's test applications" ON)
++option(SYSTEM_EXPAT "Set to ON to build SimGear using the system libExpat" OFF)
+
+ if (MSVC)
+ GET_FILENAME_COMPONENT(PARENT_DIR ${PROJECT_SOURCE_DIR} PATH)
+@@ -148,6 +149,16 @@
+ find_package(ZLIB REQUIRED)
+ find_package(Threads REQUIRED)
+
++if (SYSTEM_EXPAT)
++ message(STATUS "Requested to use system Expat library, forcing SIMGEAR_SHARED to true")
++ set(SIMGEAR_SHARED ON)
++ find_package(EXPAT REQUIRED)
++ include_directories(${EXPAT_INCLUDE_DIRS})
++else()
++ message(STATUS "Using built-in expat code")
++ add_definitions(-DHAVE_EXPAT_CONFIG_H)
++endif(SYSTEM_EXPAT)
++
+ check_include_file(sys/time.h HAVE_SYS_TIME_H)
+ check_include_file(sys/timeb.h HAVE_SYS_TIMEB_H)
+ check_include_file(unistd.h HAVE_UNISTD_H)
+@@ -252,7 +263,6 @@
+ ${ALUT_INCLUDE_DIR} ${OPENAL_INCLUDE_DIR} )
+
+ add_definitions(-DHAVE_CONFIG_H)
+-add_definitions(-DHAVE_EXPAT_CONFIG_H)
+
+ # configure a header file to pass some of the CMake settings
+ # to the source code
+diff -ruN simgear-2.8.0/simgear/CMakeLists.txt my/simgear/CMakeLists.txt
+--- simgear-2.8.0/simgear/CMakeLists.txt 2012-08-16 16:20:29.000000000 +0200
++++ my/simgear/CMakeLists.txt 2012-09-22 00:29:52.244101431 +0200
+@@ -54,7 +54,9 @@
+ set_property(TARGET SimGearCore PROPERTY VERSION ${SIMGEAR_VERSION})
+ set_property(TARGET SimGearCore PROPERTY SOVERSION ${SIMGEAR_SOVERSION})
+
+- target_link_libraries(SimGearCore ${ZLIB_LIBRARY} ${RT_LIBRARY})
++ target_link_libraries(SimGearCore ${ZLIB_LIBRARY} ${RT_LIBRARY}
++ ${EXPAT_LIBRARIES}
++ ${CMAKE_THREAD_LIBS_INIT})
+ install(TARGETS SimGearCore LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR})
+
+ if(LIBSVN_FOUND)
+diff -ruN simgear-2.8.0/simgear/simgear_config_cmake.h.in my/simgear/simgear_config_cmake.h.in
+--- simgear-2.8.0/simgear/simgear_config_cmake.h.in 2012-08-16 16:20:29.000000000 +0200
++++ my/simgear/simgear_config_cmake.h.in 2012-09-22 00:25:49.822097209 +0200
+@@ -17,3 +17,5 @@
+ #cmakedefine HAVE_LIBSVN_CLIENT_1
+
+ #cmakedefine GCC_ATOMIC_BUILTINS_FOUND
++
++#cmakedefine SYSTEM_EXPAT
+diff -ruN simgear-2.8.0/simgear/xml/CMakeLists.txt my/simgear/xml/CMakeLists.txt
+--- simgear-2.8.0/simgear/xml/CMakeLists.txt 2012-08-16 16:20:29.000000000 +0200
++++ my/simgear/xml/CMakeLists.txt 2012-09-22 00:25:49.872097210 +0200
+@@ -7,26 +7,31 @@
+ )
+
+ set(SOURCES
+- asciitab.h
+- hashtable.h
+- iasciitab.h
+- latin1tab.h
+- nametab.h
+- utf8tab.h
+- xmldef.h
+- xmlparse.h
+- xmlrole.h
+- xmltok.h
+- xmltok_impl.h
+- hashtable.c
+- xmlparse.c
+- xmlrole.c
+- xmltok.c
+ easyxml.cxx
+- internal.h
+- ascii.h
+- expat.h
+- expat_external.h
+ )
+
++if (NOT SYSTEM_EXPAT)
++ list(APPEND SOURCES
++ asciitab.h
++ hashtable.h
++ iasciitab.h
++ latin1tab.h
++ nametab.h
++ utf8tab.h
++ xmldef.h
++ xmlparse.h
++ xmlrole.h
++ xmltok.h
++ xmltok_impl.h
++ hashtable.c
++ xmlparse.c
++ xmlrole.c
++ xmltok.c
++ internal.h
++ ascii.h
++ expat.h
++ expat_external.h
++ )
++endif()
++
+ simgear_component(xml xml "${SOURCES}" "${HEADERS}")
+diff -ruN simgear-2.8.0/simgear/xml/easyxml.cxx my/simgear/xml/easyxml.cxx
+--- simgear-2.8.0/simgear/xml/easyxml.cxx 2012-08-16 16:20:29.000000000 +0200
++++ my/simgear/xml/easyxml.cxx 2012-09-22 00:25:49.889097210 +0200
+@@ -4,13 +4,22 @@
+ * This file is in the Public Domain, and comes with NO WARRANTY of any kind.
+ */
+
++#ifdef HAVE_CONFIG_H
++# include <simgear_config.h>
++#endif
++
+ #include <simgear/compiler.h>
+
+ #include <string.h> // strcmp()
+
+ #include "easyxml.hxx"
+-#include "xmlparse.h"
+-
++
++#ifdef SYSTEM_EXPAT
++# include <expat.h>
++#else
++# include "xmlparse.h"
++#endif
++
+ #include <fstream>
+ #include <iostream>
+
diff --git a/dev-games/simgear/files/simgear-2.8.0-underlinking.patch b/dev-games/simgear/files/simgear-2.8.0-underlinking.patch
deleted file mode 100644
index a1a4d75c9917..000000000000
--- a/dev-games/simgear/files/simgear-2.8.0-underlinking.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-From: Julian Ospald <hasufell@gentoo.org>
-Date: Fri Aug 24 15:16:41 UTC 2012
-Subject: build system
-
-fix underlinking
-
---- simgear/CMakeLists.txt
-+++ simgear/CMakeLists.txt
-@@ -54,7 +54,7 @@
- set_property(TARGET SimGearCore PROPERTY VERSION ${SIMGEAR_VERSION})
- set_property(TARGET SimGearCore PROPERTY SOVERSION ${SIMGEAR_SOVERSION})
-
-- target_link_libraries(SimGearCore ${ZLIB_LIBRARY} ${RT_LIBRARY})
-+ target_link_libraries(SimGearCore ${ZLIB_LIBRARY} ${RT_LIBRARY} pthread)
- install(TARGETS SimGearCore LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR})
-
- if(LIBSVN_FOUND)
diff --git a/dev-games/simgear/simgear-2.8.0.ebuild b/dev-games/simgear/simgear-2.8.0-r1.ebuild
index c34c23f605df..ca9d172c6469 100644
--- a/dev-games/simgear/simgear-2.8.0.ebuild
+++ b/dev-games/simgear/simgear-2.8.0-r1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-games/simgear/simgear-2.8.0.ebuild,v 1.2 2012/08/31 21:25:05 reavertm Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-games/simgear/simgear-2.8.0-r1.ebuild,v 1.1 2012/09/21 22:37:18 reavertm Exp $
EAPI=4
@@ -16,6 +16,7 @@ SLOT="0"
IUSE="debug jpeg subversion test"
COMMON_DEPEND="
+ dev-libs/expat
>=dev-games/openscenegraph-3.0.1
media-libs/freealut
media-libs/openal
@@ -32,17 +33,18 @@ DEPEND="${COMMON_DEPEND}
"
RDEPEND="${COMMON_DEPEND}"
-DOCS=(AUTHORS ChangeLog NEWS README Thanks)
+PATCHES=(
+ "${FILESDIR}/${P}-unbundle-expat.patch"
+)
-src_prepare() {
- epatch "${FILESDIR}"/${P}-underlinking.patch
-}
+DOCS=(AUTHORS ChangeLog NEWS README Thanks)
src_configure() {
local mycmakeargs=(
-DENABLE_RTI=OFF
-DSIMGEAR_HEADLESS=OFF
-DSIMGEAR_SHARED=ON
+ -DSYSTEM_EXPAT=ON
$(cmake-utils_use jpeg JPEG_FACTORY)
$(cmake-utils_use_enable subversion LIBSVN)
$(cmake-utils_use_enable test TESTS)