2024-10-28 13:32:39 +00:00
|
|
|
|
{
|
|
|
|
|
lib,
|
|
|
|
|
stdenv,
|
|
|
|
|
runCommand,
|
|
|
|
|
getent,
|
|
|
|
|
xcbuild,
|
|
|
|
|
}:
|
2024-10-28 01:57:16 +00:00
|
|
|
|
|
|
|
|
|
# Prints information about the state of the build environment for
|
|
|
|
|
# assistance debugging Hydra. Feel free to add anything you would find
|
|
|
|
|
# useful to this.
|
2024-10-28 13:32:39 +00:00
|
|
|
|
runCommand "build-environment-info"
|
|
|
|
|
{
|
|
|
|
|
nativeBuildInputs = [ getent ] ++ lib.optionals stdenv.buildPlatform.isDarwin [ xcbuild ];
|
|
|
|
|
}
|
|
|
|
|
''
|
|
|
|
|
# It’s useful to get more info even if a command fails.
|
|
|
|
|
set +e
|
2024-10-28 01:57:16 +00:00
|
|
|
|
|
2024-10-28 13:32:39 +00:00
|
|
|
|
run() {
|
|
|
|
|
echoCmd : "$@"
|
|
|
|
|
"$@"
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
run uname -a
|
|
|
|
|
|
|
|
|
|
${lib.optionalString stdenv.buildPlatform.isDarwin ''
|
|
|
|
|
run env SYSTEM_VERSION_COMPAT=0 plutil -p /System/Library/CoreServices/SystemVersion.plist
|
|
|
|
|
''}
|
|
|
|
|
|
|
|
|
|
run id
|
|
|
|
|
|
|
|
|
|
run getent passwd "$(id -un)"
|
|
|
|
|
|
|
|
|
|
run ulimit -a
|
|
|
|
|
|
|
|
|
|
# Always fail so that this job can easily be restarted.
|
|
|
|
|
run exit 1
|
|
|
|
|
''
|