about summary refs log tree commit diff
path: root/nixpkgs/pkgs/servers/x11/xorg/imake-setup-hook.sh
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/servers/x11/xorg/imake-setup-hook.sh')
-rw-r--r--nixpkgs/pkgs/servers/x11/xorg/imake-setup-hook.sh19
1 files changed, 19 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/servers/x11/xorg/imake-setup-hook.sh b/nixpkgs/pkgs/servers/x11/xorg/imake-setup-hook.sh
new file mode 100644
index 000000000000..10f54198f7fb
--- /dev/null
+++ b/nixpkgs/pkgs/servers/x11/xorg/imake-setup-hook.sh
@@ -0,0 +1,19 @@
+export IMAKECPP="@tradcpp@/bin/tradcpp"
+
+imakeConfigurePhase() {
+    runHook preConfigure
+
+    echoCmd 'configuring with imake'
+
+    if [ -z "${imakefile:-}" -a ! -e Imakefile ]; then
+        echo "no Imakefile, doing nothing"
+    else
+        xmkmf -a
+    fi
+
+    runHook postConfigure
+}
+
+if [ -z "$dontUseImakeConfigure" -a -z "$configurePhase" ]; then
+    configurePhase=imakeConfigurePhase
+fi