10 export CCACHE_DIR=$outdir/ccache
11 export CCACHE_LOGFILE=$CCACHE_DIR/log
12 export CCACHE_NLEVELS=1
13 export CCACHE_HARDLINK=1
15 install -d $outdir $rpmdir $logs
17 # init ccache with unlimited size (it's default is 1G)
18 if [ ! -d "$CCACHE_DIR" ]; then
22 # clear logfile if bigger than 2GiB
23 CCACHE_LOGSIZE=$((0x7FFFFFFF))
25 if [ -s "$CCACHE_LOGFILE" ] && [ $(stat -c %s "$CCACHE_LOGFILE") -gt $CCACHE_LOGSIZE ]; then
30 # print some stats on startup
33 log=$logs/$(date +%Y%m%d_%H%M%S)
35 mv $outdir/chromium-browser-*.*.*.*/src/REMOVED-*.txt $log
38 _smp_mflags=$(rpm -E %{?_smp_mflags})
39 time $dir/teeboth '' rpmbuild \
40 ${_smp_mflags:+--define "_smp_mflags ${_smp_mflags}"} \
41 --define "_unpackaged_files_terminate_build 1" \
42 --define '_enable_debug_packages 0' \
43 --define "_topdir $dir" \
44 --define "_specdir $dir" \
45 --define "_sourcedir $dir" \
46 --define "_builddir $outdir" \
47 --define "_rpmdir $rpmdir" \