Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 592434
Collapse All | Expand All

(-)a/x11-libs/fltk/files/fltk-1.3.2-jpeg-9a.patch (-2 / +2 lines)
Lines 1-7 Link Here
1
http://bugs.gentoo.org/479774
1
http://bugs.gentoo.org/479774
2
2
3
--- src/Fl_JPEG_Image.cxx
3
--- a/src/Fl_JPEG_Image.cxx
4
+++ src/Fl_JPEG_Image.cxx
4
+++ b/src/Fl_JPEG_Image.cxx
5
@@ -155,7 +155,7 @@
5
@@ -155,7 +155,7 @@
6
   
6
   
7
   jpeg_create_decompress(&dinfo);
7
   jpeg_create_decompress(&dinfo);
(-)a/x11-libs/fltk/fltk-1.3.3-r4.ebuild (+184 lines)
Line 0 Link Here
1
diff -Naur a/Makefile b/Makefile
2
--- a/Makefile	2014-08-01 21:56:09.000000000 +0100
Line 0 Link Here
1
# Copyright 1999-2016 Gentoo Foundation
2
# Distributed under the terms of the GNU General Public License v2
3
# $Id$
4
5
EAPI=6
6
7
inherit autotools flag-o-matic multilib-minimal xdg
8
9
DESCRIPTION="C++ user interface toolkit for X and OpenGL"
10
HOMEPAGE="http://www.fltk.org/"
11
SRC_URI="http://fltk.org/pub/${PN}/${PV}/${P}-source.tar.gz"
12
13
SLOT="1"
14
LICENSE="FLTK LGPL-2"
15
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~x86-macos"
16
IUSE="cairo debug doc examples games +opengl static-libs +threads +xft +xinerama"
17
18
RDEPEND="
19
	>=media-libs/libpng-1.2:0=[${MULTILIB_USEDEP}]
20
	sys-libs/zlib[${MULTILIB_USEDEP}]
21
	virtual/jpeg:0=[${MULTILIB_USEDEP}]
22
	x11-libs/libICE[${MULTILIB_USEDEP}]
23
	x11-libs/libSM[${MULTILIB_USEDEP}]
24
	x11-libs/libXcursor[${MULTILIB_USEDEP}]
25
	x11-libs/libXext[${MULTILIB_USEDEP}]
26
	x11-libs/libXfixes[${MULTILIB_USEDEP}]
27
	x11-libs/libXt[${MULTILIB_USEDEP}]
28
	cairo? ( x11-libs/cairo[${MULTILIB_USEDEP},X] )
29
	opengl? (
30
		virtual/glu[${MULTILIB_USEDEP}]
31
		virtual/opengl[${MULTILIB_USEDEP}] )
32
	xft? ( x11-libs/libXft[${MULTILIB_USEDEP}] )
33
	xinerama? ( x11-libs/libXinerama[${MULTILIB_USEDEP}] )
34
"
35
DEPEND="
36
	${RDEPEND}
37
	x11-proto/xextproto
38
	doc? ( app-doc/doxygen )
39
	xinerama? ( x11-proto/xineramaproto )
40
"
41
42
PATCHES=(
43
	"${FILESDIR}"/${PN}-1.3.2-desktop.patch
44
	"${FILESDIR}"/${PN}-1.3.0-share.patch
45
	"${FILESDIR}"/${PN}-1.3.2-conf-tests.patch
46
	"${FILESDIR}"/${PN}-1.3.2-jpeg-9a.patch
47
	"${FILESDIR}"/${PN}-1.3.3-visibility.patch
48
	"${FILESDIR}"/${PN}-1.3.3-fl_open_display.patch
49
	"${FILESDIR}"/${PN}-1.3.3-fltk-config.patch
50
	"${FILESDIR}"/${PN}-1.3.3-xutf8-visibility.patch
51
	"${FILESDIR}"/${PN}-1.3.3-makefile-dirs.patch
52
)
53
54
DOCS=(
55
	ANNOUNCEMENT
56
	CHANGES
57
	CREDITS
58
	README
59
)
60
61
pkg_setup() {
62
	unset FLTK_LIBDIRS
63
}
64
65
src_prepare() {
66
	xdg_src_prepare
67
68
	rm -rf zlib jpeg png || die
69
70
	sed -i \
71
		-e 's:@HLINKS@::g' FL/Makefile.in || die
72
	# some fixes introduced because slotting
73
	sed -i \
74
		-e '/RANLIB/s:$(libdir)/\(.*LIBNAME)\):$(libdir)/`basename \1`:g' \
75
		src/Makefile || die
76
	# docs in proper docdir
77
	sed -i \
78
		-e "/^docdir/s:fltk:${PF}/html:" \
79
		-e "/SILENT:/d" \
80
		makeinclude.in || die
81
	sed -e "s/7/${PV}/" \
82
		< "${FILESDIR}"/FLTKConfig.cmake \
83
		> CMake/FLTKConfig.cmake || die
84
	sed -e 's:-Os::g' -i configure.in || die
85
86
	# also in Makefile:config.guess config.sub:
87
	cp misc/config.{guess,sub} . || die
88
89
	eautoconf
90
	multilib_copy_sources
91
}
92
93
multilib_src_configure() {
94
	local FLTK_INCDIR=${EPREFIX}/usr/include/fltk
95
	local FLTK_LIBDIR=${EPREFIX}/usr/$(get_libdir)/fltk
96
	FLTK_LIBDIRS+=${FLTK_LIBDIRS+:}${FLTK_LIBDIR}
97
98
	multilib_is_native_abi && use prefix &&
99
		append-ldflags -Wl,-rpath -Wl,"${FLTK_LIBDIR}"
100
101
	econf \
102
		$(use_enable cairo) \
103
		$(use_enable debug) \
104
		$(use_enable opengl gl) \
105
		$(use_enable threads) \
106
		$(use_enable xft) \
107
		$(use_enable xinerama) \
108
		--disable-localjpeg \
109
		--disable-localpng \
110
		--disable-localzlib \
111
		--docdir="${EPREFIX}/usr/share/doc/${PF}/html" \
112
		--enable-largefile \
113
		--enable-shared \
114
		--enable-xcursor \
115
		--enable-xdbe \
116
		--enable-xfixes \
117
		--includedir=${FLTK_INCDIR} \
118
		--libdir=${FLTK_LIBDIR}
119
}
120
121
multilib_src_compile() {
122
	# Prevent reconfigure on non-native ABIs.
123
	# This is econf's fault as it replaces under WORKDIR.
124
	touch -r makeinclude config.{guess,sub} || die
125
126
	default
127
128
	if multilib_is_native_abi; then
129
		emake -C fluid
130
		use doc && emake -C documentation html
131
		use games && emake -C test blocks checkers sudoku
132
	fi
133
}
134
135
multilib_src_test() {
136
	emake -C fluid
137
	emake -C test
138
}
139
140
multilib_src_install() {
141
	default
142
143
	if multilib_is_native_abi; then
144
		emake -C fluid \
145
			  DESTDIR="${D}" install-linux
146
147
		use doc &&
148
			emake -C documentation \
149
				  DESTDIR="${D}" install
150
151
		use games &&
152
			emake -C test \
153
				  DESTDIR="${D}" install-linux
154
	fi
155
}
156
157
multilib_src_install_all() {
158
	for app in fluid $(use games && echo blocks checkers sudoku); do
159
		dosym /usr/share/icons/hicolor/32x32/apps/${app}.png \
160
			  /usr/share/pixmaps/${app}.png
161
	done
162
163
	if use examples; then
164
		insinto /usr/share/doc/${PF}/examples
165
		doins test/*.{h,cxx,fl} test/demo.menu
166
	fi
167
168
	insinto /usr/share/cmake/Modules
169
	doins CMake/FLTK*.cmake
170
171
	echo "LDPATH=${FLTK_LIBDIRS}" > 99fltk || die
172
	echo "FLTK_DOCDIR=${EPREFIX}/usr/share/doc/${PF}/html" >> 99fltk || die
173
	doenvd 99fltk
174
175
	# FIXME: This is bad, but building only shared libraries is hardly supported
176
	# FIXME: The executables in test/ are linking statically against libfltk
177
	if ! use static-libs; then
178
		rm "${ED}"/usr/lib*/fltk/*.a || die
179
	fi
180
181
	prune_libtool_files
182
}
(-)a/x11-libs/fltk/fltk-1.3.9999-r1.ebuild (-1 / +185 lines)
Line 0 Link Here
0
- 
1
# Copyright 1999-2016 Gentoo Foundation
2
# Distributed under the terms of the GNU General Public License v2
3
# $Id$
4
5
EAPI=6
6
7
inherit autotools flag-o-matic multilib-minimal xdg subversion
8
9
DESCRIPTION="C++ user interface toolkit for X and OpenGL"
10
HOMEPAGE="http://www.fltk.org/"
11
ESVN_REPO_URI="http://seriss.com/public/fltk/fltk/branches/branch-1.3/"
12
ESVN_USER=""
13
ESVN_PASSWORD=""
14
15
SLOT="1"
16
LICENSE="FLTK LGPL-2"
17
KEYWORDS=""
18
IUSE="cairo debug doc examples games +opengl static-libs +threads +xft +xinerama"
19
20
RDEPEND="
21
	>=media-libs/libpng-1.2:0=[${MULTILIB_USEDEP}]
22
	sys-libs/zlib[${MULTILIB_USEDEP}]
23
	virtual/jpeg:0=[${MULTILIB_USEDEP}]
24
	x11-libs/libICE[${MULTILIB_USEDEP}]
25
	x11-libs/libSM[${MULTILIB_USEDEP}]
26
	x11-libs/libXcursor[${MULTILIB_USEDEP}]
27
	x11-libs/libXext[${MULTILIB_USEDEP}]
28
	x11-libs/libXfixes[${MULTILIB_USEDEP}]
29
	x11-libs/libXt[${MULTILIB_USEDEP}]
30
	cairo? ( x11-libs/cairo[${MULTILIB_USEDEP},X] )
31
	opengl? (
32
		virtual/glu[${MULTILIB_USEDEP}]
33
		virtual/opengl[${MULTILIB_USEDEP}] )
34
	xft? ( x11-libs/libXft[${MULTILIB_USEDEP}] )
35
	xinerama? ( x11-libs/libXinerama[${MULTILIB_USEDEP}] )
36
"
37
DEPEND="
38
	${RDEPEND}
39
	x11-proto/xextproto
40
	doc? ( app-doc/doxygen )
41
	xinerama? ( x11-proto/xineramaproto )
42
"
43
44
PATCHES=(
45
	"${FILESDIR}"/${PN}-1.3.0-share.patch
46
	"${FILESDIR}"/${PN}-1.3.2-conf-tests.patch
47
	"${FILESDIR}"/${PN}-1.3.3-visibility.patch
48
	"${FILESDIR}"/${PN}-1.3.3-makefile-dirs.patch
49
)
50
51
DOCS=(
52
	ANNOUNCEMENT
53
	CHANGES
54
	CREDITS
55
	README
56
)
57
58
pkg_setup() {
59
	unset FLTK_LIBDIRS
60
}
61
62
src_prepare() {
63
	xdg_src_prepare
64
65
	rm -rf zlib jpeg png || die
66
67
	sed -i \
68
		-e 's:@HLINKS@::g' FL/Makefile.in || die
69
	sed -i \
70
		-e '/x-fluid/d' fluid/Makefile || die
71
	sed -i \
72
		-e '/C\(XX\)\?FLAGS=/s:@C\(XX\)\?FLAGS@::' \
73
		-e '/^LDFLAGS=/d' \
74
		"${S}/fltk-config.in" || die
75
	# some fixes introduced because slotting
76
	sed -i \
77
		-e '/RANLIB/s:$(libdir)/\(.*LIBNAME)\):$(libdir)/`basename \1`:g' \
78
		src/Makefile || die
79
	# docs in proper docdir
80
	sed -i \
81
		-e "/^docdir/s:fltk:${PF}/html:" \
82
		-e "/SILENT:/d" \
83
		makeinclude.in || die
84
	sed -e "s/7/${PV}/" \
85
		< "${FILESDIR}"/FLTKConfig.cmake \
86
		> CMake/FLTKConfig.cmake || die
87
	sed -e 's:-Os::g' -i configure.in || die
88
89
	# also in Makefile:config.guess config.sub:
90
	cp misc/config.{guess,sub} . || die
91
92
	eautoconf
93
	multilib_copy_sources
94
}
95
96
multilib_src_configure() {
97
	local FLTK_INCDIR=${EPREFIX}/usr/include/fltk
98
	local FLTK_LIBDIR=${EPREFIX}/usr/$(get_libdir)/fltk
99
	FLTK_LIBDIRS+=${FLTK_LIBDIRS+:}${FLTK_LIBDIR}
100
101
	multilib_is_native_abi && use prefix &&
102
		append-ldflags -Wl,-rpath -Wl,"${FLTK_LIBDIR}"
103
104
	econf \
105
		$(use_enable cairo) \
106
		$(use_enable debug) \
107
		$(use_enable opengl gl) \
108
		$(use_enable threads) \
109
		$(use_enable xft) \
110
		$(use_enable xinerama) \
111
		--disable-localjpeg \
112
		--disable-localpng \
113
		--disable-localzlib \
114
		--docdir="${EPREFIX}/usr/share/doc/${PF}/html" \
115
		--enable-largefile \
116
		--enable-shared \
117
		--enable-xcursor \
118
		--enable-xdbe \
119
		--enable-xfixes \
120
		--includedir=${FLTK_INCDIR} \
121
		--libdir=${FLTK_LIBDIR}
122
}
123
124
multilib_src_compile() {
125
	# Prevent reconfigure on non-native ABIs.
126
	# This is econf's fault as it replaces under WORKDIR.
127
	touch -r makeinclude config.{guess,sub} || die
128
129
	default
130
131
	if multilib_is_native_abi; then
132
		emake -C fluid
133
		use doc && emake -C documentation html
134
		use games && emake -C test blocks checkers sudoku
135
	fi
136
}
137
138
multilib_src_test() {
139
	emake -C fluid
140
	emake -C test
141
}
142
143
multilib_src_install() {
144
	default
145
146
	if multilib_is_native_abi; then
147
		emake -C fluid \
148
			  DESTDIR="${D}" install-linux
149
150
		use doc &&
151
			emake -C documentation \
152
				  DESTDIR="${D}" install
153
154
		use games &&
155
			emake -C test \
156
				  DESTDIR="${D}" install-linux
157
	fi
158
}
159
160
multilib_src_install_all() {
161
	for app in fluid $(use games && echo blocks checkers sudoku); do
162
		dosym /usr/share/icons/hicolor/32x32/apps/${app}.png \
163
			  /usr/share/pixmaps/${app}.png
164
	done
165
166
	if use examples; then
167
		insinto /usr/share/doc/${PF}/examples
168
		doins test/*.{h,cxx,fl} test/demo.menu
169
	fi
170
171
	insinto /usr/share/cmake/Modules
172
	doins CMake/FLTK*.cmake
173
174
	echo "LDPATH=${FLTK_LIBDIRS}" > 99fltk || die
175
	echo "FLTK_DOCDIR=${EPREFIX}/usr/share/doc/${PF}/html" >> 99fltk || die
176
	doenvd 99fltk
177
178
	# FIXME: This is bad, but building only shared libraries is hardly supported
179
	# FIXME: The executables in test/ are linking statically against libfltk
180
	if ! use static-libs; then
181
		rm "${ED}"/usr/lib*/fltk/*.a || die
182
	fi
183
184
	prune_libtool_files
185
}

Return to bug 592434