diff options
author | Lluís Batlle i Rossell <viric@viric.name> | 2016-05-20 17:17:10 +0200 |
---|---|---|
committer | Lluís Batlle i Rossell <viric@viric.name> | 2016-05-20 17:17:10 +0200 |
commit | f6f5c185ca533e52b6f0e4042971e039775dd970 (patch) | |
tree | 48d97a2bb6998ff0c3235e6289b83296118d5a4c /pkgs/stdenv/cygwin/rebase-i686.sh | |
parent | a6b6f6e049a48160258ffd4e949754153dd071e0 (diff) | |
download | nixlib-f6f5c185ca533e52b6f0e4042971e039775dd970.tar nixlib-f6f5c185ca533e52b6f0e4042971e039775dd970.tar.gz nixlib-f6f5c185ca533e52b6f0e4042971e039775dd970.tar.bz2 nixlib-f6f5c185ca533e52b6f0e4042971e039775dd970.tar.lz nixlib-f6f5c185ca533e52b6f0e4042971e039775dd970.tar.xz nixlib-f6f5c185ca533e52b6f0e4042971e039775dd970.tar.zst nixlib-f6f5c185ca533e52b6f0e4042971e039775dd970.zip |
Allow not rebasing in cygwin stdenv.
This changes cygwin stdenv, but I don't think it will hurt much people. This allows mkDerivation to get "dontRebase=true" to skip the usual cygwin rebase. This is required, if we are using this stdenv to build DLLs for win32 inside x86_64-cygwin, because /bin/rebase crashes at finding an arch mismatch. Additionally, we don't need any rebase for libraries built by visual studio and meant for visual studio (my use case). I'm using nix in x86_64-cygwin to build libraries with visual studio, both for x86_64 and x86.
Diffstat (limited to 'pkgs/stdenv/cygwin/rebase-i686.sh')
-rw-r--r-- | pkgs/stdenv/cygwin/rebase-i686.sh | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/pkgs/stdenv/cygwin/rebase-i686.sh b/pkgs/stdenv/cygwin/rebase-i686.sh index e5695c75a967..e97dc66c0ad6 100644 --- a/pkgs/stdenv/cygwin/rebase-i686.sh +++ b/pkgs/stdenv/cygwin/rebase-i686.sh @@ -1,6 +1,9 @@ postFixupHooks+=(_cygwinFixAutoImageBase) _cygwinFixAutoImageBase() { + if [ "$dontRebase" == 1 ]; then + return + fi find $out -name "*.dll" | while read DLL; do if [ -f /etc/rebasenix.nextbase ]; then NEXTBASE="$(</etc/rebasenix.nextbase)" |