Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 104262 Details for
Bug 157997
Qt/Windows ebuild request
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
Multi-category qt-4.2.2.ebuild
qt-4.2.2.ebuild (text/plain), 9.50 KB, created by
Roberto Castagnola
on 2006-12-18 01:56:55 UTC
(
hide
)
Description:
Multi-category qt-4.2.2.ebuild
Filename:
MIME Type:
Creator:
Roberto Castagnola
Created:
2006-12-18 01:56:55 UTC
Size:
9.50 KB
patch
obsolete
># Copyright 1999-2006 Gentoo Foundation ># Distributed under the terms of the GNU General Public License v2 ># $Header: $ > >export CTARGET=${CTARGET:-${CHOST}} >if [[ ${CTARGET} == ${CHOST} ]] ; then > if [[ ${CATEGORY/cross-} != ${CATEGORY} ]] ; then > export CTARGET=${CATEGORY/cross-} > fi >fi > >inherit eutils flag-o-matic toolchain-funcs multilib > >SRCTYPE="opensource-src" >DESCRIPTION="The Qt toolkit is a comprehensive C++ application development framework." >HOMEPAGE="http://www.trolltech.com/" > >SRC_URI="ftp://ftp.trolltech.com/pub/qt/source/qt-x11-${SRCTYPE}-${PV}.tar.gz" >S=${WORKDIR}/qt-x11-${SRCTYPE}-${PV} > >LICENSE="GPL-2" >SLOT="4" >KEYWORDS="~alpha ~amd64 ~ia64 ~ppc ~ppc64 ~sparc ~x86" > >if [[ ${CTARGET} == "mingw32" ]]; then >SRC_URI="${SRC_URI} > qt-win-addons-${PV}.tar.bz2" > >IUSE="accessibility debug doc examples gif odbc pch qt3support sqlite3" > ># cross-compiling need controlled strip >RESTRICT="strip" > >else > >IUSE_INPUT_DEVICES="input_devices_wacom" > >IUSE="accessibility cups dbus debug doc examples firebird gif glib jpeg mng mysql nas nis odbc opengl pch png postgres qt3support sqlite sqlite3 xinerama zlib ${IUSE_INPUT_DEVICES}" > >DEPEND="x11-libs/libXrandr > x11-libs/libXcursor > x11-libs/libXi > x11-libs/libXfont > x11-libs/libSM > x11-proto/xextproto > x11-proto/inputproto > dev-util/pkgconfig > xinerama? ( x11-proto/xineramaproto x11-libs/libXinerama ) > virtual/xft > >=media-libs/freetype-2 > png? ( media-libs/libpng ) > jpeg? ( media-libs/jpeg ) > mng? ( >=media-libs/libmng-1.0.9 ) > nas? ( >=media-libs/nas-1.5 ) > odbc? ( dev-db/unixODBC ) > mysql? ( virtual/mysql ) > firebird? ( dev-db/firebird ) > sqlite3? ( =dev-db/sqlite-3* ) > sqlite? ( =dev-db/sqlite-2* ) > opengl? ( virtual/opengl virtual/glu ) > postgres? ( dev-db/libpq ) > cups? ( net-print/cups ) > zlib? ( sys-libs/zlib ) > glib? ( dev-libs/glib ) > dbus? ( >=sys-apps/dbus-0.93 ) > input_devices_wacom? ( x11-drivers/linuxwacom )" >fi > >is_crosscompile() { > [[ ${CHOST} != ${CTARGET} ]] >} > >pkg_setup() { > PLATFORM=$(qt_mkspecs_dir) > XPLATFORM=$(cross_mkspecs_dir) > > is_crosscompile && QTPREFIXDIR=/usr/${CTARGET}/usr || QTPREFIXDIR=/usr > QTBASEDIR=${QTPREFIXDIR}/$(get_libdir)/qt4 > QTBINDIR=${QTPREFIXDIR}/bin > QTLIBDIR=${QTPREFIXDIR}/$(get_libdir)/qt4 > QTPCDIR=${QTPREFIXDIR}/$(get_libdir)/pkgconfig > QTDATADIR=${QTPREFIXDIR}/share/qt4 > QTDOCDIR=${QTPREFIXDIR}/share/doc/${PF} > QTHEADERDIR=${QTPREFIXDIR}/include/qt4 > is_crosscompile && QTPLUGINDIR=${QTDATADIR}/plugins || QTPLUGINDIR=${QTLIBDIR}/plugins > is_crosscompile && QTSYSCONFDIR=/etc/qt4/${CTARGET} || QTSYSCONFDIR=/etc/qt4 > QTTRANSDIR=${QTDATADIR}/translations > QTEXAMPLESDIR=${QTDATADIR}/examples > QTDEMOSDIR=${QTDATADIR}/demos >} > >qt_use() { > useq ${1} && echo "-${1}" || echo "-no-${1}" > return 0 >} > >qt_mkspecs_dir() { > # Allows us to define which mkspecs dir we want to use. > local spec > > case ${CHOST} in > *-freebsd*|*-dragonfly*) > spec="freebsd" ;; > *-openbsd*) > spec="openbsd" ;; > *-netbsd*) > spec="netbsd" ;; > *-darwin*) > spec="darwin" ;; > *-linux-*|*-linux) > spec="linux" ;; > *) > die "Unknown CHOST, no platform choosed." > esac > > CXX=$(tc-getCXX) > if [[ ${CXX/g++/} != ${CXX} ]]; then > spec="${spec}-g++" > elif [[ ${CXX/icpc/} != ${CXX} ]]; then > spec="${spec}-icc" > else > die "Unknown compiler ${CXX}." > fi > > echo "${spec}" >} > >cross_mkspecs_dir() { > if is_crosscompile; then > case $CTARGET in > mingw32) > xspec="win32-g++" ;; > *) > die "Cross-compile support is for only mingw32." > esac > else > xspec=$(qt_mkspecs_dir) > fi > > echo "${xspec}" >} > >src_unpack() { > unpack ${A} > cd ${S} > > if is_crosscompile; then > epatch ${FILESDIR}/${CTARGET}/ > else ># epatch ${FILESDIR}/qt4-parisc-linux.diff > epatch ${FILESDIR}/qt-4.1.4-sparc.patch > epatch ${FILESDIR}/qt4-sqlite-configure.patch > fi > > # Don't let the user go too overboard with flags. If you really want to, uncomment > # out the line below and give 'er a whirl. > strip-flags > replace-flags -O3 -O2 > > # set c/xxflags and ldflags > sed -i -e "s:QMAKE_CFLAGS_RELEASE.*=.*:QMAKE_CFLAGS_RELEASE=${CFLAGS}:" \ > -e "s:QMAKE_CXXFLAGS_RELEASE.*=.*:QMAKE_CXXFLAGS_RELEASE=${CXXFLAGS}:" \ > -e "s:QMAKE_LFLAGS_RELEASE.*=.*:QMAKE_LFLAGS_RELEASE=${LDFLAGS}:" \ > mkspecs/${PLATFORM}/qmake.conf mkspecs/common/g++.conf > > # Do not link with -rpath. See bug #75181. > sed -i -e "s:QMAKE_RPATH.*=.*:QMAKE_RPATH=:" \ > mkspecs/${PLATFORM}/qmake.conf mkspecs/common/g++.conf > > # Replace X11R6/ directories, so /usr/X11R6/lib -> /usr/lib > sed -i -e "s:X11R6/::" mkspecs/${PLATFORM}/qmake.conf mkspecs/common/linux.conf >} > >src_compile() { > export PATH="${S}/bin:${PATH}" > export LD_LIBRARY_PATH="${S}/lib:${LD_LIBRARY_PATH}" > > [ $(get_libdir) != "lib" ] && myconf="${myconf} -L/usr/$(get_libdir)" > > #common config > use gif && myconf="${myconf} -qt-gif" || myconf="${myconf} -no-gif" > use odbc && myconf="${myconf} -plugin-sql-odbc" || myconf="${myconf} -no-sql-odbc" > use qt3support && myconf="${myconf} -qt3support" || myconf="${myconf} -no-qt3support" > use pch && myconf="${myconf} -pch" > use examples || myconf="${myconf} -nomake examples" > > if [[ ${CTARGET} == "mingw32" ]]; then > # mingw32 config > myconf="${myconf} -qt-libpng -qt-libjpeg -qt-libmng -qt-zlib -no-sql-mysql -no-sql-psql -no-sql-ibase -no-sql-sqlite2 -rtti" > use debug && myconf="${myconf} -debug -debug-and-release" || myconf="${myconf} -release" > use sqlite3 && myconf="${myconf} -plugin-sql-sqlite" || myconf="${myconf} -no-sql-sqlite" > if use accessibility; then > if [[ "$(gcc-major-version ${CTARGET})" == "4" ]]; then > einfo "Accessibility support fails to compile with mingw32-g++-4: disabled" > myconf="${myconf} -no-accessibility" > else > myconf="${myconf} -accessibility" > fi > else > myconf="${myconf} -no-accessibility" > fi > else > # not cross-compile config > if [[ "$(gcc-major-version)" == "4" ]]; then > einfo "Visibility support: auto" > else > einfo "Visibility support: disabled" > myconf="${myconf} -no-reduce-exports" > fi > > myconf="${myconf} $(qt_use accessibility) $(qt_use cups) $(qt_use xinerama)" > myconf="${myconf} $(qt_use opengl) $(qt_use nis)" > > use nas && myconf="${myconf} -system-nas-sound" > use png && myconf="${myconf} -system-libpng" || myconf="${myconf} -qt-libpng" > use jpeg && myconf="${myconf} -system-libjpeg" || myconf="${myconf} -qt-libjpeg" > use debug && myconf="${myconf} -debug -separate-debug-info" || myconf="${myconf} -release -no-separate-debug-info" > use zlib && myconf="${myconf} -system-zlib" || myconf="${myconf} -qt-zlib" > > use mysql && myconf="${myconf} -plugin-sql-mysql -I/usr/include/mysql -L/usr/$(get_libdir)/mysql" || myconf="${myconf} -no-sql-mysql" > use postgres && myconf="${myconf} -plugin-sql-psql -I/usr/include/postgresql/pgsql" || myconf="${myconf} -no-sql-psql" > use firebird && myconf="${myconf} -plugin-sql-ibase" || myconf="${myconf} -no-sql-ibase" > use sqlite3 && myconf="${myconf} -plugin-sql-sqlite -system-sqlite" || myconf="${myconf} -no-sql-sqlite" > use sqlite && myconf="${myconf} -plugin-sql-sqlite2" || myconf="${myconf} -no-sql-sqlite2" > > use dbus && myconf="${myconf} -qdbus" || myconf="${myconf} -no-qdbus" > use glib && myconf="${myconf} -glib" || myconf="${myconf} -no-glib" > > use input_devices_wacom && myconf="${myconf} -tablet" || myconf="${myconf} -no-tablet" > > myconf="${myconf} -largefile -xrender -xrandr -xkb -xshape -sm" > fi > > ./configure -stl -verbose -confirm-license \ > -platform ${PLATFORM} -xplatform ${XPLATFORM} \ > -prefix ${QTPREFIXDIR} -bindir ${QTBINDIR} -libdir ${QTLIBDIR} -datadir ${QTDATADIR} \ > -docdir ${QTDOCDIR} -headerdir ${QTHEADERDIR} -plugindir ${QTPLUGINDIR} \ > -sysconfdir ${QTSYSCONFDIR} -translationdir ${QTTRANSDIR} \ > -examplesdir ${QTEXAMPLESDIR} -demosdir ${QTDEMOSDIR} ${myconf} || die > > emake || die >} > >src_install() { > export PATH="${S}/bin:${PATH}" > export LD_LIBRARY_PATH="${S}/lib:${LD_LIBRARY_PATH}" > > make INSTALL_ROOT=${D} install_subtargets || die > make INSTALL_ROOT=${D} install_mkspecs || die > > if [[ ${CTARGET} == "mingw32" ]]; then > # *.dll are installed twice (in QTBINDIR and in QTLIBDIR) > rm -f ${D}/${QTLIBDIR}/*.dll > # and 'install_qmake' target is missing > exeinto ${QTBINDIR} > doexe ${S}/bin/qmake > # maybe moc, rcc, uic and qmake programs should be installed elsewhere > else > make INSTALL_ROOT=${D} install_qmake || die > fi > > if use doc; then > make INSTALL_ROOT=${D} install_htmldocs || die > fi > > # Install the translations. This may get use flagged later somehow > make INSTALL_ROOT=${D} install_translations || die > > if is_crosscompile; then > # controlled strip > env RESTRICT="" CHOST=${CHOST} prepstrip ${D}/${QTBINDIR} > env RESTRICT="" CHOST=${CTARGET} prepstrip ${D}/${QTLIBDIR} > # want to strip dlls too ># find ${D} -iname "*.dll" -exec $(tc-getSTRIP ${CTARGET}) --strip-unneeded '{}' \; > else > keepdir "${QTSYSCONFDIR}" > > sed -i -e "s:${S}/lib:${QTLIBDIR}:g" ${D}/${QTLIBDIR}/*.la > sed -i -e "s:${S}/lib:${QTLIBDIR}:g" ${D}/${QTLIBDIR}/*.prl > sed -i -e "s:${S}/lib:${QTLIBDIR}:g" ${D}/${QTLIBDIR}/*.pc > > # pkgconfig files refer to WORKDIR/bin as the moc and uic locations. Fix: > sed -i -e "s:${S}/bin:${QTBINDIR}:g" ${D}/${QTLIBDIR}/*.pc > > # Move .pc files into the pkgconfig directory > dodir ${QTPCDIR} > mv ${D}/${QTLIBDIR}/*.pc ${D}/${QTPCDIR} > fi > > # List all the multilib libdirs > local libdirs > for libdir in $(get_all_libdirs); do > libdirs="${libdirs}:/usr/${libdir}/qt4" > done > > if is_crosscompile; then > cat > "${T}/44qt4-${CTARGET}" << EOF >XQMAKESPEC=${XPLATFORM} >EOF > doenvd "${T}/44qt4-${CTARGET}" > # create symlink to use CTARGET-qmake when cross-compiling > dosym ${QTBINDIR}/qmake /usr/bin/${CTARGET}-qmake > else > cat > "${T}/44qt4" << EOF >LDPATH=${libdirs:1} >QMAKESPEC=${PLATFORM} >EOF > doenvd "${T}/44qt4" > fi >}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 157997
:
103927
|
104218
|
104262
|
104673
|
106195
|
106197
|
124692
|
124694
|
124807
|
138369
|
138370
|
139081