mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-11 23:24:35 +00:00
aff1f4ab94
The following parameters are now available: * hardeningDisable To disable specific hardening flags * hardeningEnable To enable specific hardening flags Only the cc-wrapper supports this right now, but these may be reused by other wrappers, builders or setup hooks. cc-wrapper supports the following flags: * fortify * stackprotector * pie (disabled by default) * pic * strictoverflow * format * relro * bindnow
47 lines
1 KiB
Nix
47 lines
1 KiB
Nix
{ stdenv, fetchurl }:
|
|
|
|
stdenv.mkDerivation rec {
|
|
name = "boost-build-2.0-m12";
|
|
|
|
src = fetchurl {
|
|
url = "mirror://sourceforge/boost/${name}.tar.bz2";
|
|
sha256 = "10sbbkx2752r4i1yshyp47nw29lyi1p34sy6hj7ivvnddiliayca";
|
|
};
|
|
|
|
hardeningDisable = [ "format" ];
|
|
|
|
patchPhase = ''
|
|
grep -r '/usr/share/boost-build' \
|
|
| awk '{split($0,a,":"); print a[1];}' \
|
|
| xargs sed -i "s,/usr/share/boost-build,$out/share/boost-build,"
|
|
'';
|
|
|
|
buildPhase = ''
|
|
cd jam_src
|
|
./build.sh
|
|
'';
|
|
|
|
installPhase = ''
|
|
# Install Bjam
|
|
mkdir -p $out/bin
|
|
cd "$(ls | grep bin)"
|
|
cp -a bjam $out/bin
|
|
|
|
# Bjam is B2
|
|
ln -s bjam $out/bin/b2
|
|
|
|
# Install the shared files (don't include jam_src)
|
|
cd ../..
|
|
rm -rf jam_src
|
|
mkdir -p $out/share
|
|
cp -a . $out/share/boost-build
|
|
'';
|
|
|
|
meta = with stdenv.lib; {
|
|
homepage = http://www.boost.org/boost-build2/;
|
|
license = stdenv.lib.licenses.boost;
|
|
platforms = platforms.unix;
|
|
maintainers = with maintainers; [ wkennington ];
|
|
};
|
|
}
|