/[gentoo-x86]/app-emulation/wine/wine-1.4.1.ebuild
Gentoo

Contents of /app-emulation/wine/wine-1.4.1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.5 - (hide annotations) (download)
Thu Aug 23 16:45:20 2012 UTC (2 years, 4 months ago) by tetromino
Branch: MAIN
Changes since 1.4: +6 -1 lines
Run tools/make_requests if a user patch modifies the server protocol definition (bug #432348, thanks to Oliver 'oGGy' Ney).

(Portage version: 2.2.0_alpha121/cvs/Linux x86_64)

1 tetromino 1.1 # Copyright 1999-2012 Gentoo Foundation
2     # Distributed under the terms of the GNU General Public License v2
3 tetromino 1.5 # $Header: /var/cvsroot/gentoo-x86/app-emulation/wine/wine-1.4.1.ebuild,v 1.4 2012/08/12 21:53:11 tetromino Exp $
4 tetromino 1.1
5     EAPI="4"
6    
7     inherit autotools eutils flag-o-matic multilib pax-utils
8    
9     if [[ ${PV} == "9999" ]] ; then
10     EGIT_REPO_URI="git://source.winehq.org/git/wine.git"
11     inherit git-2
12     SRC_URI=""
13     #KEYWORDS=""
14     else
15     MY_P="${PN}-${PV/_/-}"
16     SRC_URI="mirror://sourceforge/${PN}/Source/${MY_P}.tar.bz2"
17 scarabeus 1.3 KEYWORDS="-* amd64 x86 ~x86-fbsd"
18 tetromino 1.1 S=${WORKDIR}/${MY_P}
19     fi
20    
21     GV="1.4"
22     DESCRIPTION="free implementation of Windows(tm) on Unix"
23     HOMEPAGE="http://www.winehq.org/"
24     SRC_URI="${SRC_URI}
25     gecko? (
26     mirror://sourceforge/${PN}/Wine%20Gecko/${GV}/wine_gecko-${GV}-x86.msi
27     win64? ( mirror://sourceforge/${PN}/Wine%20Gecko/${GV}/wine_gecko-${GV}-x86_64.msi )
28     )"
29    
30     LICENSE="LGPL-2.1"
31     SLOT="0"
32     IUSE="alsa capi cups custom-cflags elibc_glibc fontconfig +gecko gnutls gphoto2 gsm gstreamer hardened jpeg lcms ldap mp3 ncurses nls odbc openal opencl +opengl +oss +perl png samba scanner selinux ssl test +threads +truetype udisks v4l +win32 +win64 +X xcomposite xinerama xml"
33     REQUIRED_USE="elibc_glibc? ( threads )" #286560
34     RESTRICT="test" #72375
35    
36     MLIB_DEPS="amd64? (
37     truetype? ( >=app-emulation/emul-linux-x86-xlibs-2.1 )
38     X? (
39     >=app-emulation/emul-linux-x86-xlibs-2.1
40     >=app-emulation/emul-linux-x86-soundlibs-2.1
41     )
42     mp3? ( app-emulation/emul-linux-x86-soundlibs )
43     odbc? ( app-emulation/emul-linux-x86-db )
44     openal? ( app-emulation/emul-linux-x86-sdl )
45     opengl? ( app-emulation/emul-linux-x86-opengl )
46     scanner? ( app-emulation/emul-linux-x86-medialibs )
47     v4l? ( app-emulation/emul-linux-x86-medialibs )
48     app-emulation/emul-linux-x86-baselibs
49     >=sys-kernel/linux-headers-2.6
50     )"
51     RDEPEND="truetype? ( >=media-libs/freetype-2.0.0 media-fonts/corefonts )
52     perl? ( dev-lang/perl dev-perl/XML-Simple )
53     capi? ( net-dialup/capi4k-utils )
54     ncurses? ( >=sys-libs/ncurses-5.2 )
55     fontconfig? ( media-libs/fontconfig )
56     gphoto2? ( media-libs/libgphoto2 )
57     openal? ( media-libs/openal )
58     udisks? (
59     sys-apps/dbus
60     sys-fs/udisks:0
61     )
62     gnutls? ( net-libs/gnutls )
63     gstreamer? ( media-libs/gstreamer media-libs/gst-plugins-base )
64     X? (
65     x11-libs/libXcursor
66     x11-libs/libXrandr
67     x11-libs/libXi
68     x11-libs/libXmu
69     x11-libs/libXxf86vm
70     )
71     xinerama? ( x11-libs/libXinerama )
72     alsa? ( media-libs/alsa-lib )
73     cups? ( net-print/cups )
74     opencl? ( virtual/opencl )
75     opengl? ( virtual/opengl )
76     gsm? ( media-sound/gsm )
77     jpeg? ( virtual/jpeg )
78     ldap? ( net-nds/openldap )
79     lcms? ( =media-libs/lcms-1* )
80     mp3? ( >=media-sound/mpg123-1.5.0 )
81     nls? ( sys-devel/gettext )
82     odbc? ( dev-db/unixODBC )
83     samba? ( >=net-fs/samba-3.0.25 )
84     selinux? ( sec-policy/selinux-wine )
85     xml? ( dev-libs/libxml2 dev-libs/libxslt )
86     scanner? ( media-gfx/sane-backends )
87     ssl? ( dev-libs/openssl )
88     png? ( media-libs/libpng )
89     v4l? ( media-libs/libv4l )
90     !win64? ( ${MLIB_DEPS} )
91     win32? ( ${MLIB_DEPS} )
92     xcomposite? ( x11-libs/libXcomposite )"
93     DEPEND="${RDEPEND}
94     X? (
95     x11-proto/inputproto
96     x11-proto/xextproto
97     x11-proto/xf86vidmodeproto
98     )
99     xinerama? ( x11-proto/xineramaproto )
100     !hardened? ( sys-devel/prelink )
101     virtual/pkgconfig
102     virtual/yacc
103     sys-devel/flex"
104    
105     src_unpack() {
106     if use win64 ; then
107     [[ $(( $(gcc-major-version) * 100 + $(gcc-minor-version) )) -lt 404 ]] \
108     && die "you need gcc-4.4+ to build 64bit wine"
109     fi
110    
111     if use win32 && use opencl; then
112     [[ x$(eselect opencl show) = "xintel" ]] &&
113     die "Cannot build wine[opencl,win32]: intel-ocl-sdk is 64-bit only" # 403947
114     fi
115    
116     if [[ ${PV} == "9999" ]] ; then
117     git-2_src_unpack
118     else
119     unpack ${MY_P}.tar.bz2
120     fi
121     }
122    
123     src_prepare() {
124 tetromino 1.5 local md5="$(md5sum server/protocol.def)"
125 tetromino 1.1 epatch "${FILESDIR}"/${PN}-1.1.15-winegcc.patch #260726
126     epatch "${FILESDIR}"/${PN}-1.4_rc2-multilib-portage.patch #395615
127     epatch_user #282735
128 tetromino 1.5 if [[ "$(md5sum server/protocol.def)" != "${md5}" ]]; then
129     einfo "server/protocol.def was patched; running tools/make_requests"
130     tools/make_requests || die #432348
131     fi
132 tetromino 1.1 eautoreconf
133     sed -i '/^UPDATE_DESKTOP_DATABASE/s:=.*:=true:' tools/Makefile.in || die
134     sed -i '/^MimeType/d' tools/wine.desktop || die #117785
135     }
136    
137     do_configure() {
138     local builddir="${WORKDIR}/wine$1"
139     mkdir -p "${builddir}"
140     pushd "${builddir}" >/dev/null
141    
142     ECONF_SOURCE=${S} \
143     econf \
144     --sysconfdir=/etc/wine \
145     $(use_with alsa) \
146     $(use_with capi) \
147     $(use_with lcms cms) \
148     $(use_with cups) \
149     $(use_with ncurses curses) \
150     $(use_with udisks dbus) \
151     $(use_with fontconfig) \
152     $(use_with gnutls) \
153     $(use_with gphoto2 gphoto) \
154     $(use_with gsm) \
155     $(use_with gstreamer) \
156     --without-hal \
157     $(use_with jpeg) \
158     $(use_with ldap) \
159     $(use_with mp3 mpg123) \
160     $(use_with nls gettext) \
161     $(use_with openal) \
162     $(use_with opencl) \
163     $(use_with opengl) \
164     $(use_with ssl openssl) \
165     $(use_with oss) \
166     $(use_with png) \
167     $(use_with threads pthread) \
168     $(use_with scanner sane) \
169     $(use_enable test tests) \
170     $(use_with truetype freetype) \
171     $(use_with v4l) \
172     $(use_with X x) \
173     $(use_with xcomposite) \
174     $(use_with xinerama) \
175     $(use_with xml) \
176     $(use_with xml xslt) \
177     $2
178    
179     emake -j1 depend
180    
181     popd >/dev/null
182     }
183    
184     src_configure() {
185     export LDCONFIG=/bin/true
186     use custom-cflags || strip-flags
187    
188     if use win64 ; then
189     do_configure 64 --enable-win64
190     use win32 && ABI=x86 do_configure 32 --with-wine64=../wine64
191     else
192     ABI=x86 do_configure 32 --disable-win64
193     fi
194     }
195    
196     src_compile() {
197     local b
198     for b in 64 32 ; do
199     local builddir="${WORKDIR}/wine${b}"
200     [[ -d ${builddir} ]] || continue
201     emake -C "${builddir}" all
202     done
203     }
204    
205     src_install() {
206     local b
207     for b in 64 32 ; do
208     local builddir="${WORKDIR}/wine${b}"
209     [[ -d ${builddir} ]] || continue
210     emake -C "${builddir}" install DESTDIR="${D}"
211     done
212     dodoc ANNOUNCE AUTHORS README
213     if use gecko ; then
214     insinto /usr/share/wine/gecko
215     doins "${DISTDIR}"/wine_gecko-${GV}-x86.msi
216     use win64 && doins "${DISTDIR}"/wine_gecko-${GV}-x86_64.msi
217     fi
218     if ! use perl ; then
219     rm "${D}"usr/bin/{wine{dump,maker},function_grep.pl} "${D}"usr/share/man/man1/wine{dump,maker}.1 || die
220     fi
221    
222     if use win32 || ! use win64; then
223     pax-mark psmr "${D}"usr/bin/wine{,-preloader} #255055
224     fi
225     use win64 && pax-mark psmr "${D}"usr/bin/wine64{,-preloader}
226    
227     if use win64 && ! use win32; then
228     dosym /usr/bin/wine{64,} # 404331
229     dosym /usr/bin/wine{64,}-preloader
230     fi
231     }

  ViewVC Help
Powered by ViewVC 1.1.20