build-xz.sh (631B)
1 #!/bin/sh 2 # This Source Code Form is subject to the terms of the Mozilla Public 3 # License, v. 2.0. If a copy of the MPL was not distributed with this 4 # file, You can obtain one at http://mozilla.org/MPL/2.0/. 5 # 6 7 set -e 8 set -x 9 10 # Required fetch artifact 11 xz_src=${MOZ_FETCHES_DIR}/xz-source 12 13 # Actual build 14 work_dir=`pwd` 15 dest_dir=${work_dir}/tmp-install 16 tardir=xz 17 18 cd `mktemp -d` 19 ${xz_src}/configure --prefix=/${tardir} CFLAGS=-O2 ${configure_flags_extra} || { exit_status=$? && cat config.log && exit $exit_status ; } 20 export MAKEFLAGS=-j`nproc` 21 make 22 make DESTDIR=${dest_dir} install 23 cd ${dest_dir} 24 25 $(dirname $0)/pack.sh ${tardir}