Pagina 1 di 1

Qt4 SlackBuild

Inviato: mer 5 lug 2006, 12:20
da gohanz
Ragazzi sapete dove trovare uno SlackBuild per le Qt4, ho fatto un po di ricerche ma niente! :roll:

Inviato: mer 5 lug 2006, 12:38
da DaNiMoTh
Io, molto ma molto tempo fa, avevo fatto questo. Guardatelo, studialo e modifical o :D

Codice: Seleziona tutto

#!/bin/sh
# Build Qt

CWD=`pwd`
TMP=/tmp
VERSION=4.0.0
ARCH=i686
BUILD=1
PKG=$TMP/package-qt
rm -rf $PKG
mkdir -p $PKG
HTMLDOCS=$TMP/package-qt-htmldocs
EXAMPLES=$TMP/package-qt-examples

tar xjvf $CWD/qt-x11-opensource-desktop-$VERSION.tar.bz2
cd qt-x11-opensource-desktop-$VERSION
QTDIR=`pwd`
export QTDIR
export YACC='byacc -d'

# Fix file perms:
chown -R root.root .
find . -perm 2775 -exec chmod 755 {} \;
find . -perm 2755 -exec chmod 755 {} \;
find . -perm 775 -exec chmod 755 {} \;
find . -perm 555 -exec chmod 755 {} \;
find . -perm 664 -exec chmod 644 {} \;
find . -perm 444 -exec chmod 644 {} \;

# Make symlinks for the examples/docs right away:


# These are the flags recommended by KDE (circa 3.0.x):
#./configure -system-zlib -qt-gif -system-libpng -system-libjpeg -plugin-imgfmt-mng -thread -no-stl -no-xinerama -no-g++-exceptions

# And here's what we are currently using.  The "yes" agrees to the GPL, so don't run this script if you
# don't agree.  :-)
echo "yes" | ./configure \
-prefix /usr/lib/qt-4.0 \
-no-g++-exceptions \
-qt3support \
-opengl \
-system-zlib -nis -cups -xshape -xinerama -xcursor -xrandr -xrender -fontconfig -xkb -release \
-accessibility
# We're using '-i' to work around a bug where the build tries to strip html files.
# Build the important stuff:
make -j4

# Half the time this doesn't work for squat, so don't write to tell me I should be
# using "make install".  The methods used here are more likely to continue to work.
make install PREFIX=$PKG

## These are (and always were) a kludge to work around certain vendors still linking
## against a non-threaded Qt.  Now that the links are breaking things (like the kdebindings
## build), out they go.  If something breaks, either recompile it or complain to the vendor.
##
## Add libqt symlinks:
#( cd /usr/lib/qt/lib
#  for link in libqt.so.3 libqt.so.`echo $VERSION | cut -f 1-2 -d .` libqt.so.${VERSION} ; do
#    ln -sf libqt-mt.so.${VERSION} $link
#  done
#)

# Then, package things up in $PKG:


gzip -9 $PKG/usr/lib/qt-4.0/doc/man/man*/*

( cd $PKG/usr/lib/qt-4.0/include/private
  mkdir tmp
  cp *.h tmp
  rm *.h
  mv tmp/* .
  rmdir tmp
  cd ..
  mkdir tmp
  cp *.h tmp
  rm *.h
  mv tmp/* .
  rmdir tmp )

( cd $PKG/usr/lib/qt-4.0/bin
  cp qmake qmake.bin
  rm qmake
  mv qmake.bin qmake 
  strip * )

mkdir -p $PKG/usr/bin
chown root.bin $PKG/usr/bin
( cd $PKG/usr/bin
  for file in assistant designer linguist lrelease lupdate moc qm2ts qmake qtconfig uic ; do
    ln -sf /usr/lib/qt-4.0/bin/$file .
  done )

( cd $PKG/usr/lib/qt-4.0/lib
  strip --strip-unneeded *.so
  rm README )

( cd $PKG/usr/lib/qt-4.0/plugins
  strip --strip-unneeded */*.so
  cd ..
  find . -type d -name .obj -exec rm -r {} \;
  find . -type d -name .moc -exec rm -r {} \; )

( cd $PKG/usr/lib/qt-4.0
  rm -r config.tests qmake src tools translations 
  rm config.status configure Makefile )
  
  mkdir -p $PKG/usr/doc/qt-$VERSION
cp $QTDIR/doc/* $PKG/usr/doc/qt-$VERSION

mkdir -p $PKG/install
zcat $CWD/doinst.sh > $PKG/install/doinst.sh
cat $CWD/slack-desc > $PKG/install/slack-desc

## Maybe something for later?  :-)
##
## HTML documentation and examples are HUGE so they go in their own packages.
#rm -rf $HTMLDOCS $EXAMPLES
#mkdir -p $HTMLDOCS/usr/doc/qt-$VERSION $EXAMPLES/usr/doc/qt-$VERSION
#mv $PKG/usr/doc/qt-$VERSION/html $HTMLDOCS/usr/doc/qt-$VERSION
#mv $PKG/usr/doc/qt-$VERSION/examples $EXAMPLES/usr/doc/qt-$VERSION
#cd $HTMLDOCS
#makepkg -l y -c n $TMP/qt-htmldocs-$VERSION-noarch-$BUILD.tgz
#cd $EXAMPLES
#makepkg -l y -c n $TMP/qt-examples-$VERSION-noarch-$BUILD.tgz

# Build package:
cd $PKG
makepkg -l y -c n --prepend $TMP/qt-$VERSION-$ARCH-$BUILD.tgz

Inviato: mer 5 lug 2006, 12:44
da gohanz
A Grazie! :P

Inviato: mer 5 lug 2006, 13:07
da sid77

Inviato: mer 5 lug 2006, 14:03
da gohanz
Questo รจ uno SlackBuild delle Qt 3.3.* Potrebbe anche andar bene, sinceramente non lo so! :roll:

Inviato: mer 13 dic 2006, 15:01
da Meskalamdug
http://slackware-current.net
Qui ce qt4
PACCHETTIZATO
:)