media-libs/sge: Use pkg-config instead of freetype-config.

Closes: https://bugs.gentoo.org/655798
Package-Manager: Portage-2.3.41, Repoman-2.3.9
This commit is contained in:
Lars Wendler
2018-07-07 21:35:22 +02:00
parent bf35a67dbd
commit a44989ce5f
4 changed files with 52 additions and 17 deletions

View File

@@ -1,5 +1,5 @@
--- Makefile.orig 2006-03-29 00:08:39.000000000 -0500
+++ Makefile 2006-03-29 00:09:36.000000000 -0500
--- a/Makefile
+++ b/Makefile
@@ -2,7 +2,7 @@
include Makefile.conf
@@ -95,8 +95,8 @@
ln -sf libSGE.so.$(API_VER).$(SGE_VER) libSGE.so.$(API_VER);\
ln -sf libSGE.so.$(API_VER) libSGE.so
@echo "** Headerfiles installed in $(PREFIX_H)"
--- Makefile.conf.orig 2006-03-29 00:08:39.000000000 -0500
+++ Makefile.conf 2006-03-29 00:08:39.000000000 -0500
--- a/Makefile.conf
+++ b/Makefile.conf
@@ -11,6 +11,7 @@
# Compilers (C and C++)
CC=gcc

View File

@@ -1,5 +1,5 @@
--- sge_tt_text.cpp
+++ sge_tt_text.cpp
--- a/sge_tt_text.cpp
+++ b/sge_tt_text.cpp
@@ -36,10 +36,9 @@
#include "sge_textpp.h"

View File

@@ -0,0 +1,25 @@
https://bugs.gentoo.org/655798
--- sge030809/Makefile.conf
+++ sge030809/Makefile.conf
@@ -35,16 +35,16 @@
SGE_LIBS =$(shell sdl-config --libs) -lstdc++
-# Is freetype-config available?
-HAVE_FT =$(shell if (freetype-config --version) < /dev/null > /dev/null 2>&1; then echo "y"; else echo "n"; fi;)
+# Is freetype available?
+HAVE_FT =$(shell if pkg-config --exists freetype2 ; then echo "y"; else echo "n"; fi;)
ifeq ($(HAVE_FT),n)
USE_FT = n
endif
ifneq ($(USE_FT),n)
USE_FT = y
- SGE_LIBS +=$(shell freetype-config --libs)
- FT_CFLAGS =$(shell freetype-config --cflags)
+ SGE_LIBS +=$(shell pkg-config --libs freetype2)
+ FT_CFLAGS =$(shell pkg-config --cflags freetype2)
endif

View File

@@ -1,8 +1,8 @@
# Copyright 1999-2015 Gentoo Foundation
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
inherit eutils multilib toolchain-funcs
EAPI=6
inherit multilib toolchain-funcs
MY_P="sge${PV}"
DESCRIPTION="Graphics extensions library for SDL"
@@ -14,17 +14,24 @@ SLOT="0"
KEYWORDS="amd64 ~ia64 ppc x86 ~x86-fbsd"
IUSE="doc examples image truetype"
DEPEND="media-libs/libsdl
RDEPEND="media-libs/libsdl
image? ( media-libs/sdl-image )
truetype? ( >=media-libs/freetype-2 )"
DEPEND="${RDEPEND}
virtual/pkgconfig"
S="${WORKDIR}/${MY_P}"
PATCHES=(
"${FILESDIR}"/${P}-build.patch
"${FILESDIR}"/${P}-freetype.patch
"${FILESDIR}"/${P}-cmap.patch
"${FILESDIR}"/${P}-freetype_pkgconfig.patch
)
src_prepare() {
epatch \
"${FILESDIR}"/${P}-build.patch \
"${FILESDIR}"/${P}-freetype.patch \
"${FILESDIR}"/${P}-cmap.patch
default
sed -i "s:\$(PREFIX)/lib:\$(PREFIX)/$(get_libdir):" Makefile || die
sed -i \
-e '/^CC=/d' \
@@ -43,10 +50,13 @@ src_compile() {
}
src_install() {
DOCS="README Todo WhatsNew" \
default
local DOCS=( README Todo WhatsNew )
default
use doc && dohtml docs/*
if use doc ; then
docinto html
dodoc docs/*
fi
if use examples ; then
insinto /usr/share/doc/${PF}