1 |
commit: 56e0c700f0c0aa406e84d7dd300557c0eb3c4a3d |
2 |
Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu May 10 20:16:05 2018 +0000 |
4 |
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu May 10 20:16:22 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=56e0c700 |
7 |
|
8 |
x11-misc/xfe: Use pkg-cofing to find freetype and xft. |
9 |
|
10 |
Closes: https://bugs.gentoo.org/514800 |
11 |
Package-Manager: Portage-2.3.36, Repoman-2.3.9 |
12 |
|
13 |
...e-1.42-use_pkgconfig_for_freetype_and_xft.patch | 57 ++++++++++++++++++++++ |
14 |
x11-misc/xfe/xfe-1.42.ebuild | 16 +++--- |
15 |
2 files changed, 66 insertions(+), 7 deletions(-) |
16 |
|
17 |
diff --git a/x11-misc/xfe/files/xfe-1.42-use_pkgconfig_for_freetype_and_xft.patch b/x11-misc/xfe/files/xfe-1.42-use_pkgconfig_for_freetype_and_xft.patch |
18 |
new file mode 100644 |
19 |
index 00000000000..1394f59abc2 |
20 |
--- /dev/null |
21 |
+++ b/x11-misc/xfe/files/xfe-1.42-use_pkgconfig_for_freetype_and_xft.patch |
22 |
@@ -0,0 +1,57 @@ |
23 |
+--- xfe-1.42/configure.ac |
24 |
++++ xfe-1.42/configure.ac |
25 |
+@@ -29,6 +29,7 @@ |
26 |
+ AC_PROG_INSTALL |
27 |
+ AC_PROG_LN_S |
28 |
+ AC_PROG_MAKE_SET |
29 |
++PKG_PROG_PKG_CONFIG |
30 |
+ |
31 |
+ |
32 |
+ # Internationalization |
33 |
+@@ -109,16 +110,13 @@ |
34 |
+ |
35 |
+ echo "checking whether FOX was compiled with Xft support... yes" |
36 |
+ |
37 |
+- # Check for FreeType2 headers |
38 |
+- freetype_config='' |
39 |
+- AC_CHECK_PROGS(freetype_config,freetype-config,) |
40 |
+- if test -n "$freetype_config"; then |
41 |
+- freetype_cflags=`$freetype_config --cflags` |
42 |
+- freetype_libs=`$freetype_config --libs` |
43 |
+- LIBS="$LIBS $freetype_libs" |
44 |
+- CPPFLAGS="$freetype_cflags $CPPFLAGS" |
45 |
+- fi |
46 |
+- AC_CHECK_HEADER(config/ftheader.h,,[AC_CHECK_HEADER(freetype/config/ftheader.h,,AC_MSG_ERROR("ftheader.h not found"))]) |
47 |
++ # Check for FreeType2 |
48 |
++ PKG_CHECK_MODULES(FREETYPE, freetype2, [ |
49 |
++ freetype_cflags="$FREETYPE_CFLAGS" |
50 |
++ freetype_libs="$FREETYPE_LIBS" |
51 |
++ LIBS="$LIBS $freetype_libs" |
52 |
++ CPPFLAGS="$freetype_cflags $CPPFLAGS" |
53 |
++ ], AC_MSG_ERROR("freetype not found")) |
54 |
+ |
55 |
+ # Check for Xft headers |
56 |
+ xft_config='' |
57 |
+@@ -131,15 +129,13 @@ |
58 |
+ CXXFLAGS="${CXXFLAGS} -DHAVE_XFT_H" |
59 |
+ else |
60 |
+ # On some systems (e.g. Fedora) xft-config is deprecated and pkg-config should be used instead |
61 |
+- pkg_config='' |
62 |
+- AC_CHECK_PROGS(pkg_config,pkg-config,) |
63 |
+- if test -n "$pkg_config"; then |
64 |
+- xft_cflags=`$pkg_config --cflags xft` |
65 |
+- xft_libs=`$pkg_config --libs xft` |
66 |
+- LIBS="$LIBS $xft_libs" |
67 |
+- CPPFLAGS="$xft_cflags $CPPFLAGS" |
68 |
+- CXXFLAGS="${CXXFLAGS} -DHAVE_XFT_H" |
69 |
+- fi |
70 |
++ PKG_CHECK_MODULES(XFT, xft, [ |
71 |
++ xft_cflags="$XFT_CFLAGS" |
72 |
++ xft_libs="$XFT_LIBS" |
73 |
++ LIBS="$LIBS $xft_libs" |
74 |
++ CPPFLAGS="$xft_cflags $CPPFLAGS" |
75 |
++ CXXFLAGS="$CXXFLAGS -DHAVE_XFT_H" |
76 |
++ ], AC_MSG_ERROR("Xft not found")) |
77 |
+ fi |
78 |
+ AC_CHECK_HEADER(X11/Xft/Xft.h,,AC_MSG_ERROR("Xft.h not found")) |
79 |
+ |
80 |
|
81 |
diff --git a/x11-misc/xfe/xfe-1.42.ebuild b/x11-misc/xfe/xfe-1.42.ebuild |
82 |
index df2bd089efc..dd6e5a79a2d 100644 |
83 |
--- a/x11-misc/xfe/xfe-1.42.ebuild |
84 |
+++ b/x11-misc/xfe/xfe-1.42.ebuild |
85 |
@@ -1,4 +1,4 @@ |
86 |
-# Copyright 1999-2017 Gentoo Foundation |
87 |
+# Copyright 1999-2018 Gentoo Foundation |
88 |
# Distributed under the terms of the GNU General Public License v2 |
89 |
|
90 |
EAPI=6 |
91 |
@@ -36,6 +36,8 @@ DEPEND=" |
92 |
|
93 |
DOCS=( AUTHORS BUGS ChangeLog README TODO ) |
94 |
|
95 |
+PATCHES=( "${FILESDIR}/${PN}-1.42-use_pkgconfig_for_freetype_and_xft.patch" ) |
96 |
+ |
97 |
src_prepare() { |
98 |
default |
99 |
|
100 |
@@ -62,15 +64,15 @@ src_prepare() { |
101 |
-e 's|AM_CONFIG_HEADER|AC_CONFIG_HEADERS|g' \ |
102 |
configure.ac || die |
103 |
|
104 |
- eapply_user |
105 |
- |
106 |
eautoreconf |
107 |
} |
108 |
|
109 |
src_configure() { |
110 |
- econf \ |
111 |
- $(use_enable debug) \ |
112 |
- $(use_enable nls) \ |
113 |
- $(use_enable startup-notification sn) \ |
114 |
+ local myeconfargs=( |
115 |
+ $(use_enable debug) |
116 |
+ $(use_enable nls) |
117 |
+ $(use_enable startup-notification sn) |
118 |
--enable-minimalflags |
119 |
+ ) |
120 |
+ econf "${myeconfargs[@]}" |
121 |
} |