treewide: remove usages of header and stopNest
they're obsolete
This commit is contained in:
@@ -524,7 +524,7 @@ buildStdenv.mkDerivation ({
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Extract the debug info.
|
# Extract the debug info.
|
||||||
header "separating debug info from $i (build ID $id)"
|
echo "separating debug info from $i (build ID $id)"
|
||||||
mkdir -p "$dst/''${id:0:2}"
|
mkdir -p "$dst/''${id:0:2}"
|
||||||
$OBJCOPY --only-keep-debug "$i" "$dst/''${id:0:2}/''${id:2}.debug"
|
$OBJCOPY --only-keep-debug "$i" "$dst/''${id:0:2}/''${id:2}.debug"
|
||||||
|
|
||||||
|
|||||||
@@ -1,10 +1,8 @@
|
|||||||
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
||||||
source "$stdenv/setup"
|
source "$stdenv/setup"
|
||||||
|
|
||||||
header "exporting \`$url' (revision $rev) into \`$out'"
|
echo "exporting \`$url' (revision $rev) into \`$out'"
|
||||||
|
|
||||||
# Perform a lightweight checkout so that we don't end up importing
|
# Perform a lightweight checkout so that we don't end up importing
|
||||||
# all the repository's history.
|
# all the repository's history.
|
||||||
BZR_LOG=/dev/null bzr -Ossl.cert_reqs=none export -r "$rev" --format=dir "$out" "$url"
|
BZR_LOG=/dev/null bzr -Ossl.cert_reqs=none export -r "$rev" --format=dir "$out" "$url"
|
||||||
|
|
||||||
stopNest
|
|
||||||
|
|||||||
@@ -24,5 +24,3 @@ else
|
|||||||
fi
|
fi
|
||||||
(cd export && cvs -f -z0 -d "$cvsRoot" export $tag "$module")
|
(cd export && cvs -f -z0 -d "$cvsRoot" export $tag "$module")
|
||||||
mv export/* $out
|
mv export/* $out
|
||||||
|
|
||||||
stopNest
|
|
||||||
|
|||||||
@@ -11,10 +11,8 @@ elif test -n "$context"; then
|
|||||||
tagflags="--context=$context"
|
tagflags="--context=$context"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
header "getting $url $partial ${tagtext} into $out"
|
echo "getting $url $partial ${tagtext} into $out"
|
||||||
|
|
||||||
darcs get --lazy $tagflags "$url" "$out"
|
darcs get --lazy $tagflags "$url" "$out"
|
||||||
# remove metadata, because it can change
|
# remove metadata, because it can change
|
||||||
rm -rf "$out/_darcs"
|
rm -rf "$out/_darcs"
|
||||||
|
|
||||||
stopNest
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
||||||
source "${stdenv}/setup"
|
source "${stdenv}/setup"
|
||||||
header "exporting ${repository}/${imageName} (tag: ${tag}) into ${out}"
|
echo "exporting ${repository}/${imageName} (tag: ${tag}) into ${out}"
|
||||||
mkdir -p "${out}"
|
mkdir -p "${out}"
|
||||||
|
|
||||||
cat <<EOF > "${out}/compositeImage.sh"
|
cat <<EOF > "${out}/compositeImage.sh"
|
||||||
@@ -26,4 +26,3 @@ ${gnutar}/bin/tar \
|
|||||||
-c "${manifest}" "${repositories}" -T "${imageFileStorePaths}"
|
-c "${manifest}" "${repositories}" -T "${imageFileStorePaths}"
|
||||||
EOF
|
EOF
|
||||||
chmod +x "${out}/compositeImage.sh"
|
chmod +x "${out}/compositeImage.sh"
|
||||||
stopNest
|
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ stdenv.mkDerivation {
|
|||||||
inherit name;
|
inherit name;
|
||||||
builder = writeText "${fetcher}-builder.sh" ''
|
builder = writeText "${fetcher}-builder.sh" ''
|
||||||
source "$stdenv/setup"
|
source "$stdenv/setup"
|
||||||
header "${fetcher} exporting to $out"
|
echo "${fetcher} exporting to $out"
|
||||||
|
|
||||||
declare -A creds
|
declare -A creds
|
||||||
|
|
||||||
@@ -49,7 +49,7 @@ stdenv.mkDerivation {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -f "$dockerCredentialsFile" ]; then
|
if [ -f "$dockerCredentialsFile" ]; then
|
||||||
header "using credentials from $dockerCredentialsFile"
|
echo "using credentials from $dockerCredentialsFile"
|
||||||
|
|
||||||
CREDSFILE=$(cat "$dockerCredentialsFile")
|
CREDSFILE=$(cat "$dockerCredentialsFile")
|
||||||
creds[token]=$(${awk} -F'=' '/DOCKER_TOKEN/ {print $2}' <<< "$CREDSFILE" | head -n1)
|
creds[token]=$(${awk} -F'=' '/DOCKER_TOKEN/ {print $2}' <<< "$CREDSFILE" | head -n1)
|
||||||
@@ -77,8 +77,6 @@ stdenv.mkDerivation {
|
|||||||
${layerDigestFlag} \
|
${layerDigestFlag} \
|
||||||
"${repository}/${imageName}" \
|
"${repository}/${imageName}" \
|
||||||
"${tag}"
|
"${tag}"
|
||||||
|
|
||||||
stopNest
|
|
||||||
'';
|
'';
|
||||||
|
|
||||||
buildInputs = [ haskellPackages.hocker ];
|
buildInputs = [ haskellPackages.hocker ];
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
|
|||||||
builder = writeScript "xpibuilder" ''
|
builder = writeScript "xpibuilder" ''
|
||||||
source $stdenv/setup
|
source $stdenv/setup
|
||||||
|
|
||||||
header "firefox addon $name into $out"
|
echo "firefox addon $name into $out"
|
||||||
|
|
||||||
UUID="${extid}"
|
UUID="${extid}"
|
||||||
mkdir -p "$out/$UUID"
|
mkdir -p "$out/$UUID"
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
||||||
source $stdenv/setup
|
source $stdenv/setup
|
||||||
header "Cloning Fossil $url [$rev] into $out"
|
echo "Cloning Fossil $url [$rev] into $out"
|
||||||
|
|
||||||
# Fossil, bless its adorable little heart, wants to write global configuration
|
# Fossil, bless its adorable little heart, wants to write global configuration
|
||||||
# to $HOME/.fossil. AFAICT, there is no way to disable this functionality.
|
# to $HOME/.fossil. AFAICT, there is no way to disable this functionality.
|
||||||
@@ -19,5 +19,3 @@ popd
|
|||||||
|
|
||||||
# Just nuke the checkout file.
|
# Just nuke the checkout file.
|
||||||
rm $out/.fslckout
|
rm $out/.fslckout
|
||||||
|
|
||||||
stopNest
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
||||||
source $stdenv/setup
|
source $stdenv/setup
|
||||||
|
|
||||||
header "exporting $url (rev $rev) into $out"
|
echo "exporting $url (rev $rev) into $out"
|
||||||
|
|
||||||
$SHELL $fetcher --builder --url "$url" --out "$out" --rev "$rev" \
|
$SHELL $fetcher --builder --url "$url" --out "$out" --rev "$rev" \
|
||||||
${leaveDotGit:+--leave-dotGit} \
|
${leaveDotGit:+--leave-dotGit} \
|
||||||
@@ -18,4 +18,3 @@ $SHELL $fetcher --builder --url "$url" --out "$out" --rev "$rev" \
|
|||||||
${branchName:+--branch-name "$branchName"}
|
${branchName:+--branch-name "$branchName"}
|
||||||
|
|
||||||
runHook postFetch
|
runHook postFetch
|
||||||
stopNest
|
|
||||||
|
|||||||
@@ -1,10 +1,8 @@
|
|||||||
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
||||||
source $stdenv/setup
|
source $stdenv/setup
|
||||||
header "getting $url${rev:+ ($rev)} into $out"
|
echo "getting $url${rev:+ ($rev)} into $out"
|
||||||
|
|
||||||
hg clone --insecure "$url" hg-clone
|
hg clone --insecure "$url" hg-clone
|
||||||
|
|
||||||
hg archive -q$subrepoClause -y ${rev:+-r "$rev"} --cwd hg-clone $out
|
hg archive -q$subrepoClause -y ${rev:+-r "$rev"} --cwd hg-clone $out
|
||||||
rm -f $out/.hg_archival.txt
|
rm -f $out/.hg_archival.txt
|
||||||
|
|
||||||
stopNest
|
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ if ! [ -f "$cacheDB" ]; then
|
|||||||
mtn --db "$cacheDB" db init
|
mtn --db "$cacheDB" db init
|
||||||
fi
|
fi
|
||||||
|
|
||||||
header "getting revision $selector";
|
echo "getting revision $selector";
|
||||||
|
|
||||||
done=;
|
done=;
|
||||||
for source in $dbs; do
|
for source in $dbs; do
|
||||||
@@ -32,9 +32,7 @@ for source in $dbs; do
|
|||||||
fi;
|
fi;
|
||||||
done;
|
done;
|
||||||
|
|
||||||
stopNest;
|
echo "checking out the revision $revision";
|
||||||
|
|
||||||
header "checking out the revision $revision";
|
|
||||||
|
|
||||||
if test -n "$done"; then
|
if test -n "$done"; then
|
||||||
mtn checkout --db "$cacheDB" -r "$revision" "$out" -b "${branch}"
|
mtn checkout --db "$cacheDB" -r "$revision" "$out" -b "${branch}"
|
||||||
@@ -43,10 +41,6 @@ else
|
|||||||
exit 1;
|
exit 1;
|
||||||
fi;
|
fi;
|
||||||
|
|
||||||
stopNest
|
echo "clearing _MTN in the output"
|
||||||
|
|
||||||
header "clearing _MTN in the output"
|
|
||||||
|
|
||||||
rm -rf "$out/_MTN"
|
rm -rf "$out/_MTN"
|
||||||
|
|
||||||
stopNest
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
||||||
source $stdenv/setup
|
source $stdenv/setup
|
||||||
|
|
||||||
header "exporting $url (r$rev) into $out"
|
echo "exporting $url (r$rev) into $out"
|
||||||
|
|
||||||
if test -n "$http_proxy"; then
|
if test -n "$http_proxy"; then
|
||||||
# Configure proxy
|
# Configure proxy
|
||||||
@@ -22,5 +22,3 @@ fi;
|
|||||||
svn export --trust-server-cert --non-interactive \
|
svn export --trust-server-cert --non-interactive \
|
||||||
${ignoreExternals:+--ignore-externals} ${ignoreKeywords:+--ignore-keywords} \
|
${ignoreExternals:+--ignore-externals} ${ignoreKeywords:+--ignore-keywords} \
|
||||||
-r "$rev" "$url" "$out"
|
-r "$rev" "$url" "$out"
|
||||||
|
|
||||||
stopNest
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
||||||
source $stdenv/setup
|
source $stdenv/setup
|
||||||
|
|
||||||
header "exporting $url (r$rev) into $out"
|
echo "exporting $url (r$rev) into $out"
|
||||||
|
|
||||||
if test "$sshSupport"; then
|
if test "$sshSupport"; then
|
||||||
export SVN_SSH="$openssh/bin/ssh"
|
export SVN_SSH="$openssh/bin/ssh"
|
||||||
@@ -12,5 +12,3 @@ fi
|
|||||||
# whether the server is being spoofed --- only the cryptographic
|
# whether the server is being spoofed --- only the cryptographic
|
||||||
# hash of the output matters.
|
# hash of the output matters.
|
||||||
expect -f $sshSubversion "$username" "$password" "$rev" "$url" $out
|
expect -f $sshSubversion "$username" "$password" "$rev" "$url" $out
|
||||||
|
|
||||||
stopNest
|
|
||||||
|
|||||||
@@ -37,7 +37,7 @@ if [ -n "$downloadToTemp" ]; then downloadedFile="$TMPDIR/file"; fi
|
|||||||
tryDownload() {
|
tryDownload() {
|
||||||
local url="$1"
|
local url="$1"
|
||||||
echo
|
echo
|
||||||
header "trying $url"
|
echo "trying $url"
|
||||||
local curlexit=18;
|
local curlexit=18;
|
||||||
|
|
||||||
success=
|
success=
|
||||||
|
|||||||
@@ -43,9 +43,8 @@ vmTools.runInLinuxImage (stdenv.mkDerivation (
|
|||||||
[ ! -f /etc/lsb-release ] || (source /etc/lsb-release; echo "OS release: $DISTRIB_DESCRIPTION")
|
[ ! -f /etc/lsb-release ] || (source /etc/lsb-release; echo "OS release: $DISTRIB_DESCRIPTION")
|
||||||
echo "System/kernel: $(uname -a)"
|
echo "System/kernel: $(uname -a)"
|
||||||
if test -e /etc/debian_version; then echo "Debian release: $(cat /etc/debian_version)"; fi
|
if test -e /etc/debian_version; then echo "Debian release: $(cat /etc/debian_version)"; fi
|
||||||
header "installed Debian packages"
|
echo "installed Debian packages"
|
||||||
dpkg-query --list
|
dpkg-query --list
|
||||||
stopNest
|
|
||||||
'';
|
'';
|
||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
@@ -73,11 +72,10 @@ vmTools.runInLinuxImage (stdenv.mkDerivation (
|
|||||||
[ "$(echo $out/debs/*.deb)" != "" ]
|
[ "$(echo $out/debs/*.deb)" != "" ]
|
||||||
|
|
||||||
for i in $out/debs/*.deb; do
|
for i in $out/debs/*.deb; do
|
||||||
header "Generated DEB package: $i"
|
echo "Generated DEB package: $i"
|
||||||
dpkg-deb --info "$i"
|
dpkg-deb --info "$i"
|
||||||
pkgName=$(dpkg-deb -W "$i" | awk '{print $1}')
|
pkgName=$(dpkg-deb -W "$i" | awk '{print $1}')
|
||||||
echo "file deb $i" >> $out/nix-support/hydra-build-products
|
echo "file deb $i" >> $out/nix-support/hydra-build-products
|
||||||
stopNest
|
|
||||||
done
|
done
|
||||||
dpkg -i $out/debs/*.deb
|
dpkg -i $out/debs/*.deb
|
||||||
|
|
||||||
|
|||||||
@@ -74,10 +74,9 @@ stdenv.mkDerivation (
|
|||||||
if test -n "$succeedOnFailure"; then
|
if test -n "$succeedOnFailure"; then
|
||||||
if test -n "$keepBuildDirectory"; then
|
if test -n "$keepBuildDirectory"; then
|
||||||
KEEPBUILDDIR="$out/`basename $TMPDIR`"
|
KEEPBUILDDIR="$out/`basename $TMPDIR`"
|
||||||
header "Copying build directory to $KEEPBUILDDIR"
|
echo "Copying build directory to $KEEPBUILDDIR"
|
||||||
mkdir -p $KEEPBUILDDIR
|
mkdir -p $KEEPBUILDDIR
|
||||||
cp -R "$TMPDIR/"* $KEEPBUILDDIR
|
cp -R "$TMPDIR/"* $KEEPBUILDDIR
|
||||||
stopNest
|
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
'';
|
'';
|
||||||
|
|||||||
@@ -64,10 +64,9 @@ stdenv.mkDerivation (
|
|||||||
if test -n "$succeedOnFailure"; then
|
if test -n "$succeedOnFailure"; then
|
||||||
if test -n "$keepBuildDirectory"; then
|
if test -n "$keepBuildDirectory"; then
|
||||||
KEEPBUILDDIR="$out/`basename $TMPDIR`"
|
KEEPBUILDDIR="$out/`basename $TMPDIR`"
|
||||||
header "Copying build directory to $KEEPBUILDDIR"
|
echo "Copying build directory to $KEEPBUILDDIR"
|
||||||
mkdir -p $KEEPBUILDDIR
|
mkdir -p $KEEPBUILDDIR
|
||||||
cp -R "$TMPDIR/"* $KEEPBUILDDIR
|
cp -R "$TMPDIR/"* $KEEPBUILDDIR
|
||||||
stopNest
|
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
'';
|
'';
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ auditTmpdir() {
|
|||||||
local dir="$1"
|
local dir="$1"
|
||||||
[ -e "$dir" ] || return 0
|
[ -e "$dir" ] || return 0
|
||||||
|
|
||||||
header "checking for references to $TMPDIR/ in $dir..."
|
echo "checking for references to $TMPDIR/ in $dir..."
|
||||||
|
|
||||||
local i
|
local i
|
||||||
find "$dir" -type f -print0 | while IFS= read -r -d $'\0' i; do
|
find "$dir" -type f -print0 | while IFS= read -r -d $'\0' i; do
|
||||||
@@ -36,6 +36,4 @@ auditTmpdir() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
done
|
done
|
||||||
|
|
||||||
stopNest
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,12 +6,11 @@ fixupOutputHooks+=('if [ -z "$dontCanonicalizeJars" -a -e "$prefix" ]; then cano
|
|||||||
|
|
||||||
canonicalizeJarsIn() {
|
canonicalizeJarsIn() {
|
||||||
local dir="$1"
|
local dir="$1"
|
||||||
header "canonicalizing jars in $dir"
|
echo "canonicalizing jars in $dir"
|
||||||
dir="$(realpath -sm -- "$dir")"
|
dir="$(realpath -sm -- "$dir")"
|
||||||
while IFS= read -rd '' f; do
|
while IFS= read -rd '' f; do
|
||||||
canonicalizeJar "$f"
|
canonicalizeJar "$f"
|
||||||
done < <(find -- "$dir" -type f -name '*.jar' -print0)
|
done < <(find -- "$dir" -type f -name '*.jar' -print0)
|
||||||
stopNest
|
|
||||||
}
|
}
|
||||||
|
|
||||||
source @canonicalize_jar@
|
source @canonicalize_jar@
|
||||||
|
|||||||
@@ -100,8 +100,6 @@ patchShebangs() {
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
done < <(find "$@" -type f -perm -0100 -print0)
|
done < <(find "$@" -type f -perm -0100 -print0)
|
||||||
|
|
||||||
stopNest
|
|
||||||
}
|
}
|
||||||
|
|
||||||
patchShebangsAuto () {
|
patchShebangsAuto () {
|
||||||
|
|||||||
@@ -53,7 +53,7 @@ EOF
|
|||||||
echo >&2 'initdb not found. Did you add postgresql to the checkInputs?'
|
echo >&2 'initdb not found. Did you add postgresql to the checkInputs?'
|
||||||
false
|
false
|
||||||
fi
|
fi
|
||||||
header 'initializing postgresql'
|
echo 'initializing postgresql'
|
||||||
initdb -U postgres
|
initdb -U postgres
|
||||||
|
|
||||||
# Move the socket
|
# Move the socket
|
||||||
@@ -65,15 +65,15 @@ EOF
|
|||||||
echo "listen_addresses = ''" >>"$PGDATA/postgresql.conf"
|
echo "listen_addresses = ''" >>"$PGDATA/postgresql.conf"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
header 'starting postgresql'
|
echo 'starting postgresql'
|
||||||
eval "${postgresqlStartCommands:-pg_ctl start}"
|
eval "${postgresqlStartCommands:-pg_ctl start}"
|
||||||
|
|
||||||
header 'setting up postgresql'
|
echo 'setting up postgresql'
|
||||||
eval "$postgresqlTestSetupCommands"
|
eval "$postgresqlTestSetupCommands"
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
postgresqlStop() {
|
postgresqlStop() {
|
||||||
header 'stopping postgresql'
|
echo 'stopping postgresql'
|
||||||
pg_ctl stop
|
pg_ctl stop
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -26,7 +26,7 @@ _separateDebugInfo() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Extract the debug info.
|
# Extract the debug info.
|
||||||
header "separating debug info from $i (build ID $id)"
|
echo "separating debug info from $i (build ID $id)"
|
||||||
mkdir -p "$dst/${id:0:2}"
|
mkdir -p "$dst/${id:0:2}"
|
||||||
|
|
||||||
# This may fail, e.g. if the binary is for a different
|
# This may fail, e.g. if the binary is for a different
|
||||||
|
|||||||
@@ -527,9 +527,8 @@ rec {
|
|||||||
echo "System/kernel: $(uname -a)"
|
echo "System/kernel: $(uname -a)"
|
||||||
if test -e /etc/fedora-release; then echo "Fedora release: $(cat /etc/fedora-release)"; fi
|
if test -e /etc/fedora-release; then echo "Fedora release: $(cat /etc/fedora-release)"; fi
|
||||||
if test -e /etc/SuSE-release; then echo "SUSE release: $(cat /etc/SuSE-release)"; fi
|
if test -e /etc/SuSE-release; then echo "SUSE release: $(cat /etc/SuSE-release)"; fi
|
||||||
header "installed RPM packages"
|
echo "installed RPM packages"
|
||||||
rpm -qa --qf "%{Name}-%{Version}-%{Release} (%{Arch}; %{Distribution}; %{Vendor})\n"
|
rpm -qa --qf "%{Name}-%{Version}-%{Release} (%{Arch}; %{Distribution}; %{Vendor})\n"
|
||||||
stopNest
|
|
||||||
'';
|
'';
|
||||||
|
|
||||||
buildPhase = ''
|
buildPhase = ''
|
||||||
@@ -559,9 +558,8 @@ rec {
|
|||||||
find $rpmout -name "*.rpm" -exec cp {} $out/$outDir \;
|
find $rpmout -name "*.rpm" -exec cp {} $out/$outDir \;
|
||||||
|
|
||||||
for i in $out/$outDir/*.rpm; do
|
for i in $out/$outDir/*.rpm; do
|
||||||
header "Generated RPM/SRPM: $i"
|
echo "Generated RPM/SRPM: $i"
|
||||||
rpm -qip $i
|
rpm -qip $i
|
||||||
stopNest
|
|
||||||
done
|
done
|
||||||
|
|
||||||
eval "$postInstall"
|
eval "$postInstall"
|
||||||
|
|||||||
@@ -1,10 +1,8 @@
|
|||||||
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
||||||
source $stdenv/setup
|
source $stdenv/setup
|
||||||
|
|
||||||
header "exporting egg ${eggName} (version $version) into $out"
|
echo "exporting egg ${eggName} (version $version) into $out"
|
||||||
|
|
||||||
mkdir -p $out
|
mkdir -p $out
|
||||||
chicken-install -r "${eggName}:${version}"
|
chicken-install -r "${eggName}:${version}"
|
||||||
cp -r ${eggName}/* $out/
|
cp -r ${eggName}/* $out/
|
||||||
|
|
||||||
stopNest
|
|
||||||
|
|||||||
@@ -1,11 +1,9 @@
|
|||||||
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
if [ -e .attrs.sh ]; then source .attrs.sh; fi
|
||||||
source $stdenv/setup
|
source $stdenv/setup
|
||||||
|
|
||||||
header "exporting egg ${eggName} (version $version) into $out"
|
echo "exporting egg ${eggName} (version $version) into $out"
|
||||||
|
|
||||||
mkdir -p $out
|
mkdir -p $out
|
||||||
CHICKEN_EGG_CACHE=. chicken-install -r "${eggName}:${version}"
|
CHICKEN_EGG_CACHE=. chicken-install -r "${eggName}:${version}"
|
||||||
rm ${eggName}/{STATUS,TIMESTAMP}
|
rm ${eggName}/{STATUS,TIMESTAMP}
|
||||||
cp -r ${eggName}/* $out/
|
cp -r ${eggName}/* $out/
|
||||||
|
|
||||||
stopNest
|
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ patchELF() {
|
|||||||
local dir="$1"
|
local dir="$1"
|
||||||
[ -e "$dir" ] || return 0
|
[ -e "$dir" ] || return 0
|
||||||
|
|
||||||
header "shrinking RPATHs of ELF executables and libraries in $dir"
|
echo "shrinking RPATHs of ELF executables and libraries in $dir"
|
||||||
|
|
||||||
local i
|
local i
|
||||||
while IFS= read -r -d $'\0' i; do
|
while IFS= read -r -d $'\0' i; do
|
||||||
@@ -17,6 +17,4 @@ patchELF() {
|
|||||||
echo "shrinking $i"
|
echo "shrinking $i"
|
||||||
patchelf --shrink-rpath "$i" || true
|
patchelf --shrink-rpath "$i" || true
|
||||||
done < <(find "$dir" -type f -print0)
|
done < <(find "$dir" -type f -print0)
|
||||||
|
|
||||||
stopNest
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -132,7 +132,7 @@ stdenv.mkDerivation rec {
|
|||||||
# NixOS module which is based on those files without relying on them. Still, it
|
# NixOS module which is based on those files without relying on them. Still, it
|
||||||
# is helpful to have properly patched versions for non-NixOS distributions.
|
# is helpful to have properly patched versions for non-NixOS distributions.
|
||||||
postFixup = ''
|
postFixup = ''
|
||||||
header "Fixing aesmd.service"
|
echo "Fixing aesmd.service"
|
||||||
substituteInPlace $out/lib/systemd/system/aesmd.service \
|
substituteInPlace $out/lib/systemd/system/aesmd.service \
|
||||||
--replace '@aesm_folder@' \
|
--replace '@aesm_folder@' \
|
||||||
"$out/aesm" \
|
"$out/aesm" \
|
||||||
@@ -149,7 +149,7 @@ stdenv.mkDerivation rec {
|
|||||||
--replace "/bin/kill" \
|
--replace "/bin/kill" \
|
||||||
"${coreutils}/bin/kill"
|
"${coreutils}/bin/kill"
|
||||||
|
|
||||||
header "Fixing remount-dev-exec.service"
|
echo "Fixing remount-dev-exec.service"
|
||||||
substituteInPlace $out/lib/systemd/system/remount-dev-exec.service \
|
substituteInPlace $out/lib/systemd/system/remount-dev-exec.service \
|
||||||
--replace '/bin/mount' \
|
--replace '/bin/mount' \
|
||||||
"${util-linux}/bin/mount"
|
"${util-linux}/bin/mount"
|
||||||
|
|||||||
@@ -109,7 +109,7 @@ stdenv.mkDerivation rec {
|
|||||||
};
|
};
|
||||||
in
|
in
|
||||||
''
|
''
|
||||||
header "Setting up IPP crypto build artifacts"
|
echo "Setting up IPP crypto build artifacts"
|
||||||
|
|
||||||
pushd 'external/ippcp_internal'
|
pushd 'external/ippcp_internal'
|
||||||
|
|
||||||
@@ -149,7 +149,7 @@ stdenv.mkDerivation rec {
|
|||||||
./linux/installer/bin/sgx_linux_x64_sdk_${version}.bin -prefix $installDir
|
./linux/installer/bin/sgx_linux_x64_sdk_${version}.bin -prefix $installDir
|
||||||
installDir=$installDir/sgxsdk
|
installDir=$installDir/sgxsdk
|
||||||
|
|
||||||
header "Move files created by installer"
|
echo "Move files created by installer"
|
||||||
|
|
||||||
mkdir -p $out/bin
|
mkdir -p $out/bin
|
||||||
pushd $out
|
pushd $out
|
||||||
@@ -206,15 +206,15 @@ stdenv.mkDerivation rec {
|
|||||||
|
|
||||||
|
|
||||||
preFixup = ''
|
preFixup = ''
|
||||||
header "Strip sgxsdk prefix"
|
echo "Strip sgxsdk prefix"
|
||||||
for path in "$out/share/bin/environment" "$out/bin/sgx-gdb"; do
|
for path in "$out/share/bin/environment" "$out/bin/sgx-gdb"; do
|
||||||
substituteInPlace $path --replace "$TMPDIR/sgxsdk" "$out"
|
substituteInPlace $path --replace "$TMPDIR/sgxsdk" "$out"
|
||||||
done
|
done
|
||||||
|
|
||||||
header "Fixing pkg-config files"
|
echo "Fixing pkg-config files"
|
||||||
sed -i "s|prefix=.*|prefix=$out|g" $out/lib/pkgconfig/*.pc
|
sed -i "s|prefix=.*|prefix=$out|g" $out/lib/pkgconfig/*.pc
|
||||||
|
|
||||||
header "Fixing SGX_SDK default in samples"
|
echo "Fixing SGX_SDK default in samples"
|
||||||
substituteInPlace $out/share/SampleCode/LocalAttestation/buildenv.mk \
|
substituteInPlace $out/share/SampleCode/LocalAttestation/buildenv.mk \
|
||||||
--replace '/opt/intel/sgxsdk' "$out"
|
--replace '/opt/intel/sgxsdk' "$out"
|
||||||
for file in $out/share/SampleCode/*/Makefile; do
|
for file in $out/share/SampleCode/*/Makefile; do
|
||||||
@@ -222,12 +222,12 @@ stdenv.mkDerivation rec {
|
|||||||
--replace '/opt/intel/sgxsdk' "$out"
|
--replace '/opt/intel/sgxsdk' "$out"
|
||||||
done
|
done
|
||||||
|
|
||||||
header "Fixing BINUTILS_DIR in buildenv.mk"
|
echo "Fixing BINUTILS_DIR in buildenv.mk"
|
||||||
substituteInPlace $out/share/bin/buildenv.mk \
|
substituteInPlace $out/share/bin/buildenv.mk \
|
||||||
--replace 'BINUTILS_DIR ?= /usr/local/bin' \
|
--replace 'BINUTILS_DIR ?= /usr/local/bin' \
|
||||||
'BINUTILS_DIR ?= ${BINUTILS_DIR}'
|
'BINUTILS_DIR ?= ${BINUTILS_DIR}'
|
||||||
|
|
||||||
header "Fixing GDB path in bin/sgx-gdb"
|
echo "Fixing GDB path in bin/sgx-gdb"
|
||||||
substituteInPlace $out/bin/sgx-gdb --replace '/usr/local/bin/gdb' '${gdb}/bin/gdb'
|
substituteInPlace $out/bin/sgx-gdb --replace '/usr/local/bin/gdb' '${gdb}/bin/gdb'
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
|||||||
@@ -47,10 +47,10 @@ pkgs.releaseTools.sourceTarball {
|
|||||||
opts=(--option build-users-group "")
|
opts=(--option build-users-group "")
|
||||||
nix-store --init
|
nix-store --init
|
||||||
|
|
||||||
header "checking eval-release.nix"
|
echo "checking eval-release.nix"
|
||||||
nix-instantiate --eval --strict --show-trace ./maintainers/scripts/eval-release.nix > /dev/null
|
nix-instantiate --eval --strict --show-trace ./maintainers/scripts/eval-release.nix > /dev/null
|
||||||
|
|
||||||
header "checking find-tarballs.nix"
|
echo "checking find-tarballs.nix"
|
||||||
nix-instantiate --readonly-mode --eval --strict --show-trace --json \
|
nix-instantiate --readonly-mode --eval --strict --show-trace --json \
|
||||||
./maintainers/scripts/find-tarballs.nix \
|
./maintainers/scripts/find-tarballs.nix \
|
||||||
--arg expr 'import ./maintainers/scripts/all-tarballs.nix' > $TMPDIR/tarballs.json
|
--arg expr 'import ./maintainers/scripts/all-tarballs.nix' > $TMPDIR/tarballs.json
|
||||||
@@ -61,7 +61,7 @@ pkgs.releaseTools.sourceTarball {
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
header "generating packages.json"
|
echo "generating packages.json"
|
||||||
mkdir -p $out/nix-support
|
mkdir -p $out/nix-support
|
||||||
echo -n '{"version":2,"packages":' > tmp
|
echo -n '{"version":2,"packages":' > tmp
|
||||||
nix-env -f . -I nixpkgs=$src -qa --meta --json --arg config 'import ${./packages-config.nix}' "''${opts[@]}" >> tmp
|
nix-env -f . -I nixpkgs=$src -qa --meta --json --arg config 'import ${./packages-config.nix}' "''${opts[@]}" >> tmp
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ pkgs.runCommand "nixpkgs-release-checks" { src = nixpkgs; buildInputs = [nix]; }
|
|||||||
|
|
||||||
# Check that all-packages.nix evaluates on a number of platforms without any warnings.
|
# Check that all-packages.nix evaluates on a number of platforms without any warnings.
|
||||||
for platform in ${pkgs.lib.concatStringsSep " " supportedSystems}; do
|
for platform in ${pkgs.lib.concatStringsSep " " supportedSystems}; do
|
||||||
header "checking Nixpkgs on $platform"
|
echo "checking Nixpkgs on $platform"
|
||||||
|
|
||||||
# To get a call trace; see https://nixos.org/manual/nixpkgs/stable/#function-library-lib.trivial.warn
|
# To get a call trace; see https://nixos.org/manual/nixpkgs/stable/#function-library-lib.trivial.warn
|
||||||
# Relies on impure eval
|
# Relies on impure eval
|
||||||
|
|||||||
Reference in New Issue
Block a user