You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
104 lines
3.3 KiB
104 lines
3.3 KiB
# --- SDE-COPYRIGHT-NOTE-BEGIN --- |
|
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|
# |
|
# Filename: package/.../qt4/qt4.conf |
|
# Copyright (C) 2006 - 2008 The OpenSDE Project |
|
# Copyright (C) 2004 - 2006 The T2 SDE Project |
|
# Copyright (C) 1998 - 2004 Clifford Wolf |
|
# |
|
# More information can be found in the files COPYING and README. |
|
# |
|
# This program is free software; you can redistribute it and/or modify |
|
# it under the terms of the GNU General Public License as published by |
|
# the Free Software Foundation; version 2 of the License. A copy of the |
|
# GNU General Public License can be found in the file COPYING. |
|
# --- SDE-COPYRIGHT-NOTE-END --- |
|
|
|
prefix="${SDECFG_PKG_QT4_PREFIX:-usr}" |
|
set_confopt |
|
if [ "$prefix" = "usr" ]; then |
|
datadir=$datadir/$pkg |
|
fi |
|
|
|
pkg_qt4_preconf() { |
|
# Somehow config options get removed if using the standard config |
|
# handling. So we use a custom one here. |
|
./configure $confopt |
|
} |
|
|
|
# exporting the proper environment variables in profile.d |
|
pkg_qt4_profiled() { |
|
cat > $root/etc/profile.d/qt4 <<-EOT |
|
QT4DIR=/$prefix |
|
QT41DIR=/$prefix |
|
export QT4DIR QT41DIR |
|
EOT |
|
} |
|
|
|
confopt="-prefix $root/$prefix -bindir $root/$bindir -libdir $root/$libdir -docdir $root/$docdir -headerdir $root/$includedir -plugindir $root/$libdir/$pkg/plugins -datadir $root/$datadir -translationdir $root/$datadir/translations -sysconfdir $root/$sysconfdir -v" |
|
|
|
# What may come from system? |
|
for x in zlib libtiff libpng libmng libjpeg openssl nas; do |
|
if pkginstalled $x; then |
|
case "$x" in |
|
openssl) y='-openssl' ;; |
|
nas) y='-system-nas-sound' ;; |
|
*) y="-system-$x" ;; |
|
esac |
|
|
|
var_append confopt ' ' "$y" |
|
fi |
|
done |
|
|
|
# Disable debug information, this interferes with qt4 suffix. With debug |
|
# enabled we end up with 2 sets of executables. One with qt4 suffix and |
|
# one without. As a result we end up with shared files with qt3. |
|
var_append confopt ' ' "-release -no-separate-debug-info" |
|
|
|
# Confirm the license automatically |
|
var_append confopt ' ' "-confirm-license" |
|
|
|
# QT3 support is only needed when no installed. |
|
if pkginstalled qt3; then |
|
var_append confopt ' ' "-no-qt3support" |
|
else |
|
var_append confopt ' ' "-qt3support" |
|
fi |
|
|
|
# Demos and examples are not needed and only waste precious buildtime. |
|
var_append confopt ' ' "-nomake demos" |
|
var_append confopt ' ' "-nomake examples" |
|
|
|
[[ $libdir = *lib64* ]] && |
|
var_append confopt ' ' '-platform linux-g++-64' |
|
|
|
[ "$SDECFG_PKG_QT4_EXCEPTION_STL" = "0" ] && |
|
var_append confopt " " "-no-exceptions -no-stl" |
|
|
|
# Add database support for all installed databases. |
|
tuples="mysql:mysql postgresql:psql sqlite:sqlite sqlite2:sqlite2" |
|
for tuple in $tuples; do |
|
tuplepkg=${tuple#:*} |
|
tupledriver=${tuple#*:} |
|
|
|
if pkginstalled $tuplepkg; then |
|
kgprefix -t $tuplepkg |
|
var_append confopt " " "-plugin-sql-$tupledriver" |
|
for x in CXX GCC; do |
|
var_append ${x}_WRAPPER_APPEND ' ' "-L$( pkgprefix libdir $tuplepkg )/mysql" |
|
done |
|
for x in CXX GCC CPP; do |
|
var_append ${x}_WRAPPER_APPEND ' ' "-I$( pkgprefix includedir $tuplepkg )/mysql" |
|
var_append ${x}_WRAPPER_APPEND ' ' "-I$( pkgprefix includedir $tuplepkg )/mysql" |
|
done |
|
|
|
fi |
|
done |
|
|
|
hook_add preconf 5 "pkg_qt4_preconf" |
|
hook_add postmake 5 "pkg_qt4_profiled" |
|
|
|
var_append INSTALL_WRAPPER_FILTER '|' "sed -e 's,\(assistant\|designer\|linguist\|lrelease\|lupdate\|moc\|qmake\|uic\)\$,\1-$pkg,'" |
|
|
|
createdocs=0 |
|
runconf=0
|
|
|