hopefully fixed firefox & thunderbird package
[hdw-linux/hdw-linux.git] / packages / x11 / thunderbird / thunderbird
1 # hdw - linux thunderbird package
2 #
3 # author: hackbard@hackdaworld.dyndns.org
4 #
5 # [V] 1.6a1
6 # [S] 3-8
7 # [D] mozilla-cvs-20050905_1800.tar.bz2 http://hdwlinux.org/download/hdw-linux/hdw-linux-1.0/sources/x11/thunderbird/
8
9 srcdir=mozilla
10 optimize="`echo $hdw_cflags | awk '{ print $1 }'`"
11 extensions="wallet,spellcheck,xmlextras,webservices"
12 export PKG_CONFIG_PATH="$prefix/X11R6/lib/pkgconfig"
13 # firefox doesn't like optimization
14 unset CFLAGS CPPFLAGS CXXFLAGS
15
16 pre_install()   {
17         export MOZILLA_OFFICIAL=1 BUILD_OFFICIAL=1 MOZ_THUNDERBIRD=1
18         export MOZILLA_FIVE_HOME=$prefix/lib/thunderbird-$ver
19         sed "s,0000000000,hdw-linux -- ${hdw_version}," \
20                 xpfe/global/build.dtd.in > xpfe/global/build.dtd.in.new
21         mv xpfe/global/build.dtd.in.new xpfe/global/build.dtd.in
22         sed -i 's|    dist_bin="$moz_libdir"|\
23                         &\n    run_moz="$dist_bin/run-mozilla.sh"|' \
24                         browser/app/mozilla.in
25                 }
26
27 confopt="$confopt --enable-default-toolkit=gtk2 --with-x --with-system-zlib"
28 confopt="$confopt --with-system-jpeg --with-system-png"
29 confopt="$confopt --with-default-mozilla-five-home=$MOZILLA_FIVE_HOME"
30 confopt="$confopt --enable-xft --enable-crypto --enable-xinerama"
31 confopt="$confopt --enable-application=mail --enable-strip --enable-strip-libs"
32 confopt="$confopt --enable-reorder --enable-cpp-rtti"
33 confopt="$confopt --enable-extensions=$extensions" 'all' or '$extensions'
34 confopt="$confopt --disable-tests --disable-debug"
35 confopt="$confopt --disable-pedantic --disable-logging --disable-accessibility"
36 confopt="$confopt --disable-freetype2 --disable-installer --disable-mathml"
37 confopt="$confopt --disable-profilesharing --enable-single-profile"
38 confopt="$confopt --enable-necko-protocols=http,file,jar,viewsource,res,data"
39 confopt="$confopt --enable-image-decoders=default,-xbm"
40 confopt="$confopt --disable-oji --disable-plugins --disable-necko-disk-cache"
41 confopt="$confopt --enable-optimize='$optimize'"
42
43 post_install()  {
44         install -d $prefix/include/thunderbird-$ver/nss
45         cp -vLf dist/private/nss/*.h dist/public/nss/*.h \
46                 $prefix/include/thunderbird-$ver/nss
47         install -d $prefix/lib/thunderbird-$ver/defaults/isp/US
48         install mailnews/base/ispdata/movemail.rdf \
49                 mail/extensions/newsblog/rss.rdf \
50                 $prefix/lib/thunderbird-$ver/defaults/isp &&
51         ln -sfv ../{movemail,rss}.rdf \
52                 $prefix/lib/thunderbird-$ver/defaults/isp/US
53         ln -sfv thunderbird-$ver $prefix/lib/thunderbird
54         ln -sfv thunderbird-$ver $prefix/include/thunderbird
55
56         cd $prefix/lib/thunderbird-$ver
57         [ -f ./regxpcom ] && LD_LIBRARY_PATH=. ./regxpcom
58         [ -f ./regchrome ] && LD_LIBRARY_PATH=. ./regchrome
59         touch `find $PWD -name *.rdf`
60                 }