using ccache

Discussion of third-party/unofficial Firefox/Thunderbird/SeaMonkey builds.
Post Reply
hussam
Posts: 616
Joined: August 22nd, 2003, 11:49 am
Contact:

using ccache

Post by hussam »

How do I use ccache to improve recompiling speed?
For example, I build firefox daily from MOZILLA_1_8_BRANCH on my archlinux.Can somebody refresh my memory with how to use ccache when recompiling firefox to speed things up?
User avatar
RabidPenguin
Posts: 1661
Joined: June 15th, 2003, 8:39 pm
Location: USA
Contact:

Post by RabidPenguin »

I include

Code: Select all

export PATH=/usr/lib/ccache:$PATH
at the beginning of my build script. If I don't want to use ccache for a particular build I just comment that line out. I didn't have to symlink anything to make it work.
Hendikins
Posts: 26
Joined: December 31st, 1969, 5:00 pm
Location: On a train

Post by Hendikins »

I use the following in autofox.sh:

Code: Select all

export CC="ccache gcc"
export CXX="ccache g++"
export CCACHE_HARDLINK="1"
export CCACHE_DIR="/path/to/ccache/directory"
hussam
Posts: 616
Joined: August 22nd, 2003, 11:49 am
Contact:

Post by hussam »

Hendikins, how do you create the tarball?
I'm doing cd ./firefox-release/xpinstall/packager && make MOZ_PKG_APPNAME=firefox
but it won't staticly link the xpt files in /components/ ( the build itself is static ).
Hendikins
Posts: 26
Joined: December 31st, 1969, 5:00 pm
Location: On a train

Post by Hendikins »

I don't bother with the packaging script. I simply compress /dist/bin

Code: Select all

tar -C dist -jhcf $STAGEDIR/$buildfilename bin/
nrthomas
Posts: 1988
Joined: February 9th, 2003, 3:25 pm

Post by nrthomas »

Another way (better?) to make the tarball is "cd ./firefox-release/browser/installer && make" or "make -C firefox-release/browser/installer", assuming firefox-release is your objdir. Use "make installer" for the installer.
Nick Thomas - Mozilla Release Engineer
hussam
Posts: 616
Joined: August 22nd, 2003, 11:49 am
Contact:

Post by hussam »

CrazyFred, make -C firefox-release/browser/installer gave errors.
nrthomas
Posts: 1988
Joined: February 9th, 2003, 3:25 pm

Post by nrthomas »

hussam wrote:CrazyFred, make -C firefox-release/browser/installer gave errors.
Hmm, what sort of errors ?
hussam
Posts: 616
Joined: August 22nd, 2003, 11:49 am
Contact:

Post by hussam »

CrazyFred:

Code: Select all

Creating package directory...
rm -f -rf ../../dist/xpt
/usr/bin/perl -I/home/hussam/packages/firefox/mozilla/xpinstall/packager -e 'use Packager; \
          Packager::Copy("../../dist", "../../dist/firefox", \
                         "packages-static", "unix", 1, 0, 1);'
Error: package file "SCALAR(0x81516f8)" is not a file or is unreadable.
See '-e --help' for more information.
Exiting...
make[1]: *** [firefox-2.0a1.en-US.linux-i686.tar.gz] Error 4
make[1]: Leaving directory `/home/hussam/packages/firefox/mozilla/firefox-release/browser/installer'
make: *** [all] Error 2
make: Leaving directory `/home/hussam/packages/firefox/mozilla/firefox-release/browser/installer'


I can howerver build the installer 'firefox-2.0a1.en-US.linux-i686.installer.tar.gz' using 'make -C firefox-release/browser/installer installer '
nrthomas
Posts: 1988
Joined: February 9th, 2003, 3:25 pm

Post by nrthomas »

Actually, that reminds me of hitting the same bug a few days ago. I bet that just the make will work now that you've done the make installer.
Nick Thomas - Mozilla Release Engineer
hussam
Posts: 616
Joined: August 22nd, 2003, 11:49 am
Contact:

Post by hussam »

CrazyFred, still 'make -C firefox-release/browser/installer' fails but 'make -C firefox-release/browser/installer installer' works with same problem.
any idea?
nrthomas
Posts: 1988
Joined: February 9th, 2003, 3:25 pm

Post by nrthomas »

Have you tried disabling ccache for packaging ? The Linux tinderbox seem to go make installer, make and don't have any problems.
Nick Thomas - Mozilla Release Engineer
hussam
Posts: 616
Joined: August 22nd, 2003, 11:49 am
Contact:

Post by hussam »

CrazyFred, I tried again. I'm still getting the error above when running 'make -C firefox-release/browser/installer'
but for some reason, 'make -C firefox-release/browser/installer installer' still works and I'm making the installer ( like the one for win32 ).
Post Reply