diff options
author | Lars Wendler <polynomial-c@gentoo.org> | 2018-05-09 07:53:08 +0200 |
---|---|---|
committer | Lars Wendler <polynomial-c@gentoo.org> | 2018-05-09 07:53:25 +0200 |
commit | 9b025698b3eaa01d5c717e5c9e2a9a1e202d6358 (patch) | |
tree | 75dc72d5573f801746f0acf840159135fee51401 /games-emulation/advancemame | |
parent | dev-ruby/bcrypt-ruby: add ruby25 (diff) | |
download | gentoo-9b025698b3eaa01d5c717e5c9e2a9a1e202d6358.tar.gz gentoo-9b025698b3eaa01d5c717e5c9e2a9a1e202d6358.tar.bz2 gentoo-9b025698b3eaa01d5c717e5c9e2a9a1e202d6358.zip |
games-emulation/advancemame: Use pkg-config to find freetype and sdl
Closes: https://bugs.gentoo.org/655040
Package-Manager: Portage-2.3.36, Repoman-2.3.9
Diffstat (limited to 'games-emulation/advancemame')
4 files changed, 136 insertions, 6 deletions
diff --git a/games-emulation/advancemame/Manifest b/games-emulation/advancemame/Manifest index 5c414d0ed644..43195af92964 100644 --- a/games-emulation/advancemame/Manifest +++ b/games-emulation/advancemame/Manifest @@ -1 +1,2 @@ +DIST advancemame-3.7-use_pkgconfig_for_freetype_and_sdl.patch 21144 BLAKE2B ba374d664db45f938d3b054820868b5aaa63a7461938f5e8a320dc607ef3444c8fc5f87cdd3ef9db130c1048ef9e75afed4f856997f048bcb44eb99d3bcbaefc SHA512 80136d71117329997846fe0f03a3cf3439ee8ff3db649f50a3008595ed2d82cd0e3dcd9c6908edf30e19d516943eeed129eb994a6326effaf94a7eaa5d1b8fa2 DIST advancemame-3.7.tar.gz 25616260 BLAKE2B 455004ff7ce3f7517c6b06767e9d1656bff6b93f822d363cbd42738e0f9ba988c243f600db5f20e24897c27faaf5c458072e2bc9c97cf92803f76299cf3010b8 SHA512 b5af59cdd3cf70dfae0769ed35eb6ce00a6f01d05eefcb687f322420faa2ee5aabf83394249c2ab7f7f1241d3fd09c2f0412666b2dbd27b91e7bc3622f925f74 diff --git a/games-emulation/advancemame/advancemame-3.7.ebuild b/games-emulation/advancemame/advancemame-3.7.ebuild index 37773715f8e2..c371c14107c3 100644 --- a/games-emulation/advancemame/advancemame-3.7.ebuild +++ b/games-emulation/advancemame/advancemame-3.7.ebuild @@ -2,12 +2,15 @@ # Distributed under the terms of the GNU General Public License v2 EAPI=6 -inherit flag-o-matic +inherit autotools flag-o-matic DESCRIPTION="GNU/Linux port of the MAME emulator with GUI menu" HOMEPAGE="http://www.advancemame.it/" SRC_URI="https://github.com/amadvance/advancemame/releases/download/v${PV}/${P}.tar.gz" +# Fetch too big upstream patch +SRC_URI+=" https://github.com/amadvance/advancemame/commit/70f099ac49786a287ebd3949ce8f8670a5731abd.patch -> ${PN}-3.7-use_pkgconfig_for_freetype_and_sdl.patch" + LICENSE="GPL-2 XMAME" SLOT="0" KEYWORDS="~amd64 ~x86" @@ -25,20 +28,28 @@ RDEPEND=" " DEPEND="${RDEPEND} virtual/os-headers + virtual/pkgconfig x86? ( >=dev-lang/nasm-0.98 ) " +PATCHES=( + "${FILESDIR}/${PN}-1.2-pic.patch" + "${FILESDIR}"/${PN}-1.2-verboselog.patch + + # Patches from upstream + "${FILESDIR}/${P}-move_aclocal_to_acinclude.patch" + "${DISTDIR}/${P}-use_pkgconfig_for_freetype_and_sdl.patch" + "${FILESDIR}/${P}-remove_static_configure_option.patch" +) + src_prepare() { default - - eapply "${FILESDIR}/${PN}-1.2-pic.patch" \ - "${FILESDIR}"/${PN}-1.2-verboselog.patch + eautoreconf sed -i -e 's/"-s"//' configure || die use x86 && ln -s $(type -P nasm) "${T}/${CHOST}-nasm" ln -s $(type -P sdl2-config) "${T}/${CHOST}-sdl2-config" - use truetype && ln -s $(type -P freetype-config) "${T}/${CHOST}-freetype-config" } src_configure() { @@ -55,7 +66,6 @@ src_configure() { --enable-zlib \ --disable-slang \ --disable-svgalib \ - --disable-static \ $(use_enable alsa) \ $(use_enable fbcon fb) \ $(use_enable oss) \ diff --git a/games-emulation/advancemame/files/advancemame-3.7-move_aclocal_to_acinclude.patch b/games-emulation/advancemame/files/advancemame-3.7-move_aclocal_to_acinclude.patch new file mode 100644 index 000000000000..4a30e179ae27 --- /dev/null +++ b/games-emulation/advancemame/files/advancemame-3.7-move_aclocal_to_acinclude.patch @@ -0,0 +1,78 @@ +From b0edfe1e5bb1a705fad539e5ab1c299d38dcf9d4 Mon Sep 17 00:00:00 2001 +From: Andrea Mazzoleni <amadvance@gmail.com> +Date: Tue, 8 May 2018 18:55:39 +0200 +Subject: [PATCH 1/3] Use acinclude instead of aclocal + +aclocal.m4 is generated automatically, and we don't have to lose the content. +--- + acinclude.m4 | 20 ++++++++++++++++++++ + aclocal.m4 | 29 ++++++++++++----------------- + 2 files changed, 32 insertions(+), 17 deletions(-) + create mode 100644 acinclude.m4 + +diff --git a/acinclude.m4 b/acinclude.m4 +new file mode 100644 +index 00000000..ceed823a +--- /dev/null ++++ b/acinclude.m4 +@@ -0,0 +1,20 @@ ++dnl @synopsis AC_CHECK_CC_OPT(flag, ifyes, ifno) ++dnl ++dnl Shows a message as like "checking wether gcc accepts flag ... no" ++dnl and executess ifyes or ifno. ++ ++AC_DEFUN([AC_CHECK_CC_OPT], ++[ ++AC_MSG_CHECKING([whether ${CC-cc} accepts $1]) ++echo 'void f(){}' > conftest.c ++if test -z "`${CC-cc} -c $1 conftest.c 2>&1`"; then ++ AC_MSG_RESULT([yes]) ++ $2 ++else ++ AC_MSG_RESULT([no]) ++ $3 ++fi ++rm -f conftest* ++]) ++ ++ +diff --git a/aclocal.m4 b/aclocal.m4 +index d6e7b527..56e944be 100644 +--- a/aclocal.m4 ++++ b/aclocal.m4 +@@ -1,20 +1,15 @@ +-dnl @synopsis AC_CHECK_CC_OPT(flag, ifyes, ifno) +-dnl +-dnl Shows a message as like "checking wether gcc accepts flag ... no" +-dnl and executess ifyes or ifno. ++# generated automatically by aclocal 1.15 -*- Autoconf -*- + +-AC_DEFUN(AC_CHECK_CC_OPT, +-[ +-AC_MSG_CHECKING([whether ${CC-cc} accepts $1]) +-echo 'void f(){}' > conftest.c +-if test -z "`${CC-cc} -c $1 conftest.c 2>&1`"; then +- AC_MSG_RESULT([yes]) +- $2 +-else +- AC_MSG_RESULT([no]) +- $3 +-fi +-rm -f conftest* +-]) ++# Copyright (C) 1996-2014 Free Software Foundation, Inc. + ++# This file is free software; the Free Software Foundation ++# gives unlimited permission to copy and/or distribute it, ++# with or without modifications, as long as this notice is preserved. + ++# This program is distributed in the hope that it will be useful, ++# but WITHOUT ANY WARRANTY, to the extent permitted by law; without ++# even the implied warranty of MERCHANTABILITY or FITNESS FOR A ++# PARTICULAR PURPOSE. ++ ++m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) ++m4_include([acinclude.m4]) +-- +2.17.0 + diff --git a/games-emulation/advancemame/files/advancemame-3.7-remove_static_configure_option.patch b/games-emulation/advancemame/files/advancemame-3.7-remove_static_configure_option.patch new file mode 100644 index 000000000000..342ba1c5c07a --- /dev/null +++ b/games-emulation/advancemame/files/advancemame-3.7-remove_static_configure_option.patch @@ -0,0 +1,41 @@ +From 890af36a3939f0978af779caa878ddeb44183d8d Mon Sep 17 00:00:00 2001 +From: Andrea Mazzoleni <amadvance@gmail.com> +Date: Tue, 8 May 2018 19:32:44 +0200 +Subject: [PATCH 3/3] Remove the --enable-static configure option + +I doubt it still work and it doesn't make sense anymore. +--- + configure.ac | 10 ---------- + 1 file changed, 10 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 4e609993..1c94e037 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -139,13 +139,6 @@ AC_ARG_ENABLE( + ) + AC_SUBST([CONF_DEBUG],[$ac_enable_debug]) + +-AC_ARG_ENABLE( +- [static], +- AC_HELP_STRING([--enable-static],[enable static compilation. (default no)]), +- [ac_enable_static=$enableval], +- [ac_enable_static=no] +-) +- + AC_ARG_ENABLE( + [bare], + AC_HELP_STRING([--enable-bare],[enable compilation without drivers. (default no)]), +@@ -232,9 +225,6 @@ if test $ac_auto_ldflags = yes ; then + else + LDFLAGS="-s" + fi +- if test $ac_enable_static = yes ; then +- LDFLAGS="-static $LDFLAGS" +- fi + if test ! -z $ac_host_ldflags; then + LDFLAGS="$ac_host_ldflags $LDFLAGS" + fi +-- +2.17.0 + |