|
# --- ROCK-COPYRIGHT-NOTE-BEGIN ---
|
|
#
|
|
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
|
|
# Please add additional copyright information _after_ the line containing
|
|
# the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by
|
|
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text!
|
|
#
|
|
# ROCK Linux: rock-src/package/x11/mozilla/mozilla.conf
|
|
# ROCK Linux is Copyright (C) 1998 - 2004 Clifford Wolf
|
|
#
|
|
# 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; either version 2 of the License, or
|
|
# (at your option) any later version. A copy of the GNU General Public
|
|
# License can be found at Documentation/COPYING.
|
|
#
|
|
# Many people helped and are helping developing ROCK Linux. Please
|
|
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM
|
|
# file for details.
|
|
#
|
|
# --- ROCK-COPYRIGHT-NOTE-END ---
|
|
|
|
moz_fixup() {
|
|
# clear a possible existing .mozconfig
|
|
echo -n "" > .mozconfig
|
|
|
|
# fix the milestone.txt - if present and needed
|
|
if [ -f config/milestone.txt ] ; then
|
|
if ! grep -q $ver config/milestone.txt ; then
|
|
echo "Warning: Wrong version info in milestone.txt - fixup."
|
|
sed -i '/^[^#].*/d' config/milestone.txt
|
|
echo "$ver" >> config/milestone.txt
|
|
fi
|
|
fi
|
|
}
|
|
|
|
moz_implant_version() {
|
|
# replace the 00... build-id with s.th. useful
|
|
sed -i "s,0000000000,ROCK Linux - $rockver," xpfe/global/build.dtd.in
|
|
}
|
|
|
|
moz_configure() {
|
|
cat >> .mozconfig <<-EOT
|
|
# sh
|
|
# Build configuration script
|
|
# Options for client.mk.
|
|
# mk_add_options MOZ_MAKE_FLAGS=-j4
|
|
|
|
# Options for 'configure' (same as command-line options).
|
|
ac_add_options --prefix=$root/$prefix
|
|
ac_add_options --sysconfdir=$root/etc/$pkg
|
|
ac_add_options --localstatedir=$root/var
|
|
ac_add_options --host=$arch_target
|
|
ac_add_options --disable-debug
|
|
ac_add_options --enable-optimize
|
|
ac_add_options --disable-dtd-debug
|
|
ac_add_options --disable-tests
|
|
ac_add_options --disable-pedantic
|
|
ac_add_options --enable-xft
|
|
ac_add_options --disable-freetype2
|
|
ac_add_options --enable-default-toolkit=gtk2
|
|
export BUILD_OFFICIAL=1
|
|
export MOZILLA_OFFICIAL=1
|
|
mk_add_options BUILD_OFFICIAL=1
|
|
mk_add_options MOZILLA_OFFICIAL=1
|
|
EOT
|
|
}
|
|
|
|
moz_build() {
|
|
eval_config_command $( eval echo $confopt )
|
|
eval $MAKE -f client.mk build
|
|
}
|
|
|
|
moz_install() {
|
|
eval $MAKE install
|
|
}
|
|
|
|
moz_register() {
|
|
echo "Run the component registration ..."
|
|
pushd $MOZILLA_FIVE_HOME
|
|
LD_LIBRARY_PATH=. ./regxpcom
|
|
LD_LIBRARY_PATH=. ./regchrome
|
|
popd
|
|
}
|
|
|
|
moz_main() {
|
|
# maybe obsolete ... to be checked
|
|
export MOZILLA_OFFICIAL=1 BUILD_OFFICIAL=1
|
|
export MOZILLA_FIVE_HOME=$libdir/mozilla-$ver
|
|
|
|
moz_fixup
|
|
moz_implant_version
|
|
|
|
moz_configure
|
|
|
|
cat >> .mozconfig <<-EOT
|
|
ac_add_options --enable-calendar
|
|
ac_add_options --with-extensions
|
|
ac_add_options --enable-extensions=default,venkman,inspector
|
|
ac_add_options --enable-jsd
|
|
ac_add_options --enable-mathml
|
|
ac_add_options --enable-crypto
|
|
ac_add_options --enable-module=psm
|
|
EOT
|
|
|
|
moz_build
|
|
moz_install
|
|
moz_register
|
|
|
|
echo "Copy all mozilla include files" \
|
|
"(required for building galeon, evolution, etc.) ..."
|
|
cp -v xpcom/base/nscore.h $includedir/mozilla-$ver/xpcom/
|
|
cp -v xpcom/glue/nsDebug.h $includedir/mozilla-$ver/xpcom/
|
|
cp -rL dist/include/* $includedir/mozilla-$ver/
|
|
cp -rL dist/public/* $includedir/mozilla-$ver/
|
|
|
|
rm -f $includedir/mozilla
|
|
ln -s mozilla-$ver $includedir/mozilla
|
|
|
|
echo "Creating /etc/profile.d/mozilla ..."
|
|
cat <<- EOT > $root/etc/profile.d/mozilla
|
|
export MOZILLA_FIVE_HOME=$MOZILLA_FIVE_HOME
|
|
EOT
|
|
|
|
echo "Creating library symlinks ..."
|
|
cd $libdir
|
|
for i in ldap50 nspr4 nss3 plc4 plds4 prldap50 smime3 softokn3 ssl3 ; do
|
|
ln -sf $libdir/mozilla-$ver/lib${i}.so $libdir/lib${i}.so
|
|
done
|
|
}
|
|
|
|
# cleanups in this fat directory are a bit expensive
|
|
nocvsinsrcdir=0
|
|
chownsrcdir=0
|
|
|
|
custmain="moz_main"
|
|
|