Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 5 additions & 8 deletions pkgs/development/libraries/glib/setup-hook.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ glibPreInstallPhase() {
}
appendToVar preInstallPhases glibPreInstallPhase

glibPreFixupPhase() {
glibPostInstallHook() {
# Move gschemas in case the install flag didn't help
if [ -d "$prefix/share/glib-2.0/schemas" ]; then
mkdir -p "${!outputLib}/share/gsettings-schemas/$name/glib-2.0"
Expand All @@ -25,10 +25,7 @@ glibPreFixupPhase() {
}

# gappsWrapperArgsHook expects GSETTINGS_SCHEMAS_PATH variable to be set by this.
# Until we have dependency mechanism in generic builder, we need to use this ugly hack.
if [[ " ${preFixupPhases:-} " =~ " gappsWrapperArgsHook " ]]; then
preFixupPhases+=" "
preFixupPhases="${preFixupPhases/ gappsWrapperArgsHook / glibPreFixupPhase gappsWrapperArgsHook }"
else
preFixupPhases+=" glibPreFixupPhase"
fi
# Until we have dependency mechanism in generic builder, we need to use this hack.
# This relies on the fact that postInstallHooks are run *after* postInstall passed to
# mkDerivation.
postInstallHooks+=(glibPostInstallHook)
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,8 @@ giDiscoverSelf() {
}

# gappsWrapperArgsHook expects GI_TYPELIB_PATH variable to be set by this.
# Until we have dependency mechanism in generic builder, we need to use this ugly hack.
if [[ " ${preFixupPhases:-} " =~ " gappsWrapperArgsHook " ]]; then
preFixupPhases+=" "
preFixupPhases="${preFixupPhases/ gappsWrapperArgsHook / giDiscoverSelf gappsWrapperArgsHook }"
else
preFixupPhases+=" giDiscoverSelf"
fi
# Until we have dependency mechanism in generic builder, we need to use this hack.
postInstallHooks+=(giDiscoverSelf)

_multioutMoveGlibGir() {
moveToOutput share/gir-1.0 "${!outputDev}"
Expand Down
18 changes: 2 additions & 16 deletions pkgs/development/python-modules/pytest-forked/setup-hook.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,21 +12,7 @@ pytestForkedHook() {
fi
}

# the flags should be added before pytestCheckHook runs so
# until we have dependency mechanism in generic builder, we need to use this ugly hack.

if [ -z "${dontUsePytestForked-}" ] && [ -z "${dontUsePytestCheck-}" ]; then
if [[ " ${preDistPhases[*]:-} " =~ " pytestCheckPhase " ]]; then
_preDistPhases="${preDistPhases[*]} "
_preDistPhases="${_preDistPhases/ pytestCheckPhase / pytestForkedHook pytestCheckPhase }"
if [[ -n "${__structuredAttrs-}" ]]; then
preDistPhases=()
else
preDistPhases=""
fi
appendToVar preDistPhases $_preDistPhases
unset _preDistPhases
else
appendToVar preDistPhases pytestForkedHook
fi
# The flags should be added before pytestCheckHook runs in preDistPhases.
postInstallCheckHooks+=(pytestForkedHook)
fi
18 changes: 2 additions & 16 deletions pkgs/development/python-modules/pytest-xdist/setup-hook.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,7 @@ pytestXdistHook() {
)
}

# the flags should be added before pytestCheckHook runs so
# until we have dependency mechanism in generic builder, we need to use this ugly hack.

if [ -z "${dontUsePytestXdist-}" ] && [ -z "${dontUsePytestCheck-}" ]; then
if [[ " ${preDistPhases[*]:-} " =~ " pytestCheckPhase " ]]; then
_preDistPhases="${preDistPhases[*]} "
_preDistPhases="${_preDistPhases/ pytestCheckPhase / pytestXdistHook pytestCheckPhase }"
if [[ -n "${__structuredAttrs-}" ]]; then
preDistPhases=()
else
preDistPhases=""
fi
appendToVar preDistPhases $_preDistPhases
unset _preDistPhases
else
appendToVar preDistPhases pytestXdistHook
fi
# The flags should be added before pytestCheckHook runs in preDistPhases.
preInstallCheckHooks+=(pytestXdistHook)
fi