diff options
author | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 13:49:04 -0700 |
---|---|---|
committer | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 17:38:18 -0700 |
commit | 56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch) | |
tree | 3f91093cdb475e565ae857f1c5a7fd339e2d781e /games-strategy/widelands | |
download | gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.xz |
proj/gentoo: Initial commit
This commit represents a new era for Gentoo:
Storing the gentoo-x86 tree in Git, as converted from CVS.
This commit is the start of the NEW history.
Any historical data is intended to be grafted onto this point.
Creation process:
1. Take final CVS checkout snapshot
2. Remove ALL ChangeLog* files
3. Transform all Manifests to thin
4. Remove empty Manifests
5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$
5.1. Do not touch files with -kb/-ko keyword flags.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests
X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project
X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration
X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn
X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts
X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration
X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging
X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'games-strategy/widelands')
-rw-r--r-- | games-strategy/widelands/Manifest | 1 | ||||
-rw-r--r-- | games-strategy/widelands/files/widelands-0.17-cxxflags.patch | 33 | ||||
-rw-r--r-- | games-strategy/widelands/files/widelands-0.17-gcc47.patch | 12 | ||||
-rw-r--r-- | games-strategy/widelands/metadata.xml | 8 | ||||
-rw-r--r-- | games-strategy/widelands/widelands-0.17.ebuild | 84 |
5 files changed, 138 insertions, 0 deletions
diff --git a/games-strategy/widelands/Manifest b/games-strategy/widelands/Manifest new file mode 100644 index 00000000000..9c0c0115bff --- /dev/null +++ b/games-strategy/widelands/Manifest @@ -0,0 +1 @@ +DIST widelands-build17-src.tar.bz2 175547379 SHA256 be48b3b8f342a537b39a3aec2f7702250a6a47e427188ba3bece67d7d90f3cc5 SHA512 ace4127ba00bbe788cb266d2c508b2d9b0651c99f65f08a3c7d680f8998e64e26252f7095c1b62d94012b99ef1a6dc2f8be08d17f2e8f1ab864abc650c658f2d WHIRLPOOL 35454b86d467058017ac71da8fae23b3556fe8e6ced5cf94fbd07ff21b2b38eca444be6168224d3023cd1af81867a3e6e45dd1773ef54675769ec51403b24cfa diff --git a/games-strategy/widelands/files/widelands-0.17-cxxflags.patch b/games-strategy/widelands/files/widelands-0.17-cxxflags.patch new file mode 100644 index 00000000000..419d5d78a35 --- /dev/null +++ b/games-strategy/widelands/files/widelands-0.17-cxxflags.patch @@ -0,0 +1,33 @@ +From: Julian Ospald <hasufell@gentoo.org> +Date: Wed May 16 12:06:13 UTC 2012 + +respect CXXFLAGS + +--- CMakeLists.txt ++++ CMakeLists.txt +@@ -209,24 +209,7 @@ + + # CMAKE only defines "-g", but we need -DDEBUG also, and we need -DNOPARACHUTE (for SDL) in Debug + set (CMAKE_CXX_FLAGS_DEBUG "-g -DDEBUG -DNOPARACHUTE${WL_COMPILERFLAG_OLDSTYLECAST}${WL_COMPILERFLAG_GENERICWARNINGS}${WL_COMPILERFLAG_EXTRAWARNINGS}${WL_COMPILERFLAG_STRICT}" CACHE STRING "Set by widelands CMakeLists.txt" FORCE) +- +-#This can be removed if no one uses gcc 4.5.1 or 4.5.2 any more +-IF (${CMAKE_COMPILER_IS_GNUCXX}) +-EXEC_PROGRAM ( +- ${CMAKE_CXX_COMPILER} +- ARGS --version +- OUTPUT_VARIABLE WLBUILD_COMPILERVERSION +- ) +- STRING(REGEX REPLACE ".*(4)\\.(5)\\.([0-9]).*" "\\1.\\2.\\3" WLBUILD_COMPILERVERSION_REP ${WLBUILD_COMPILERVERSION}) +- IF (WLBUILD_COMPILERVERSION_REP STREQUAL "4.5.1" OR WLBUILD_COMPILERVERSION_REP STREQUAL "4.5.2") +- message("Detected gcc ${WLBUILD_COMPILERVERSION_REP}") +- message("Suffering from gcc bug, disabling -O3") +- set (CMAKE_CXX_FLAGS_RELEASE "-O2 -DNDEBUG" CACHE STRING "Set by widelands CMakeLists.txt" FORCE) +- ELSE (WLBUILD_COMPILERVERSION_REP STREQUAL "4.5.1" OR WLBUILD_COMPILERVERSION_REP STREQUAL "4.5.2") +- #This line is the default and should be preserved. +- set (CMAKE_CXX_FLAGS_RELEASE "-O3 -DNDEBUG" CACHE STRING "Set by widelands CMakeLists.txt" FORCE) +- ENDIF (WLBUILD_COMPILERVERSION_REP STREQUAL "4.5.1" OR WLBUILD_COMPILERVERSION_REP STREQUAL "4.5.2") +-ENDIF (${CMAKE_COMPILER_IS_GNUCXX}) ++set (CMAKE_CXX_FLAGS_RELEASE "-DNDEBUG" CACHE STRING "Release compiler flags" FORCE) + + #If building with MSVC, then check for 3rdparty libs + if (DEFINED MSVC) diff --git a/games-strategy/widelands/files/widelands-0.17-gcc47.patch b/games-strategy/widelands/files/widelands-0.17-gcc47.patch new file mode 100644 index 00000000000..9ea19c3571d --- /dev/null +++ b/games-strategy/widelands/files/widelands-0.17-gcc47.patch @@ -0,0 +1,12 @@ +=== modified file 'src/main.cc' +--- src/main.cc 2012-02-15 21:25:34 +0000 ++++ src/main.cc 2012-05-02 07:43:01 +0000 +@@ -28,6 +28,7 @@ + #include <iostream> + #include <stdexcept> + #include <typeinfo> ++#include <unistd.h> + + #include <SDL_main.h> + + diff --git a/games-strategy/widelands/metadata.xml b/games-strategy/widelands/metadata.xml new file mode 100644 index 00000000000..78bf2ca1e1e --- /dev/null +++ b/games-strategy/widelands/metadata.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <herd>games</herd> + <upstream> + <remote-id type="launchpad">widelands</remote-id> + </upstream> +</pkgmetadata> diff --git a/games-strategy/widelands/widelands-0.17.ebuild b/games-strategy/widelands/widelands-0.17.ebuild new file mode 100644 index 00000000000..9a4e1caa886 --- /dev/null +++ b/games-strategy/widelands/widelands-0.17.ebuild @@ -0,0 +1,84 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=5 +inherit eutils versionator toolchain-funcs flag-o-matic cmake-utils games + +MY_PV=build$(get_version_component_range 2) +MY_P=${PN}-${MY_PV}-src +DESCRIPTION="A game similar to Settlers 2" +HOMEPAGE="http://www.widelands.org/" +SRC_URI="http://launchpad.net/widelands/${MY_PV}/build-$(get_version_component_range 2)/+download/${MY_P}.tar.bz2" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 ppc x86" +IUSE="" + +DEPEND="dev-lang/lua + media-libs/libsdl[video] + media-libs/sdl-image[jpeg,png] + media-libs/sdl-mixer[vorbis] + media-libs/sdl-gfx + media-libs/sdl-net + media-libs/libpng + sys-libs/zlib + media-libs/glew + media-libs/sdl-ttf + >=dev-libs/boost-1.37" +RDEPEND="${DEPEND}" + +S=${WORKDIR}/${MY_P} + +CMAKE_BUILD_TYPE=Release +PREFIX=${GAMES_DATADIR}/${PN} + +src_prepare() { + epatch \ + "${FILESDIR}"/${P}-cxxflags.patch \ + "${FILESDIR}"/${P}-gcc47.patch + + sed -i -e 's:__ppc__:__PPC__:' src/s2map.cc || die + sed -i -e '74i#define OF(x) x' src/io/filesystem/{un,}zip.h || die + sed -i -e '22i#define OF(x) x' src/io/filesystem/ioapi.h || die + sed -i -e '/Boost_USE_STATIC_LIBS/s:ON:OFF:' CMakeLists.txt || die + + # how do I hate boost? Let me count the ways... + local boost_ver=$(best_version ">=dev-libs/boost-1.37") + + boost_ver=${boost_ver/*boost-/} + boost_ver=${boost_ver%.*} + boost_ver=${boost_ver/./_} + + einfo "Using boost version ${boost_ver}" + append-cxxflags \ + -I/usr/include/boost-${boost_ver} + append-ldflags \ + -L/usr/$(get_libdir)/boost-${boost_ver} + export BOOST_INCLUDEDIR="/usr/include/boost-${boost_ver}" + export BOOST_LIBRARYDIR="/usr/$(get_libdir)/boost-${boost_ver}" +} + +src_configure() { + local mycmakeargs+=( + '-DWL_VERSION_STANDARD=true' + "-DWL_INSTALL_PREFIX=${GAMES_PREFIX}" + "-DWL_INSTALL_DATADIR=${GAMES_DATADIR}/${PN}" + "-DWL_INSTALL_LOCALEDIR=${GAMES_DATADIR}/${PN}/locale" + "-DWL_INSTALL_BINDIR=${GAMES_BINDIR}" + ) + cmake-utils_src_configure +} + +src_compile() { + cmake-utils_src_compile +} + +src_install() { + cmake-utils_src_install + newicon pics/wl-ico-128.png ${PN}.png + make_desktop_entry ${PN} Widelands + dodoc ChangeLog CREDITS + prepgamesdirs +} |