Change:
fails to build while cross-compiling on a host from . Steps to reproduce the behavior: from on a host Maintainer information:
I don't have any problems building , the tests are disabled in a cross compilation build. Are you doing anything extra to enable them? It seems like the failure can be fixed by replacing with , but I'm not sure how you've enabled the tests, so I can't verify if it works.
Yes, I'm surprised the tests are running at all in a cross-compilation scenario. Maybe you are already on a 32-bit build machine, but forcing the cross-compilation pathway with pkgsCross? Also, unrelated to this specific issue, if you are trying to build 32-bit binaries on an x86 host you may have better luck with , which tends to be more reliable as it builds natively.
Well, I did a quick test using in this configuration. I am not using it anymore and, as you mentioned, it probably was some kind of misconfiguration on my side. I will re-open the issue in case this is actually an issue. As a side note, that's what I was doing but I had to cross-compile in the end. Thanks for the suggestion! Sorry for bothering you and thank you for your prompt response!
I've encountered the same issue - not with , but with , more precisely (ccache wrapper correctly uses buildPackages). Edit: fixed

Discussion:
# Linux it uses objdump. We don't have dwarfdump packaged for # Darwin, so this patch updates the test to also use objdump on # Darwin. <ins> # Additionally, when cross compiling, the correct target prefix # needs to be set. </ins> (substituteAll { <del> src = ./force-objdump-on-darwin.patch; objdump = "${binutils.bintools}/bin/objdump"; </del> <ins> src = ./fix-objdump-path.patch; objdump = "${binutils.bintools}/bin/${binutils.targetPrefix}objdump"; </ins> }) ];

<ins> diff --git a/test/run b/test/run index 43a57312..398be8d8 100755 --- a/test/run +++ b/test/run @@ -148,21 +148,17 @@ file_size() { objdump_cmd() { local file="$1" -    if $HOST_OS_APPLE; then -        xcrun dwarfdump -r 0 "$file" -    elif $HOST_OS_WINDOWS || $HOST_OS_CYGWIN; then +    if $HOST_OS_WINDOWS || $HOST_OS_CYGWIN; then # For some reason objdump only shows the basename of the file, so fall # back to brute force and ignorance. strings "$1" else -        objdump -W "$file" +        @objdump@ -W "$file" fi } objdump_grep_cmd() { -    if $HOST_OS_APPLE; then -        grep -Fq ""$1"" -    elif $HOST_OS_WINDOWS || $HOST_OS_CYGWIN; then +    if $HOST_OS_WINDOWS || $HOST_OS_CYGWIN; then grep -Fq "$1" else grep -Fq ": $1" </ins>

<del> diff --git a/test/run b/test/run index 43a57312..398be8d8 100755 --- a/test/run +++ b/test/run @@ -148,21 +148,17 @@ file_size() { objdump_cmd() { local file="$1" -    if $HOST_OS_APPLE; then -        xcrun dwarfdump -r 0 "$file" -    elif $HOST_OS_WINDOWS || $HOST_OS_CYGWIN; then +    if $HOST_OS_WINDOWS || $HOST_OS_CYGWIN; then # For some reason objdump only shows the basename of the file, so fall # back to brute force and ignorance. strings "$1" else -        objdump -W "$file" +        @objdump@ -W "$file" fi } objdump_grep_cmd() { -    if $HOST_OS_APPLE; then -        grep -Fq ""$1"" -    elif $HOST_OS_WINDOWS || $HOST_OS_CYGWIN; then +    if $HOST_OS_WINDOWS || $HOST_OS_CYGWIN; then grep -Fq "$1" else grep -Fq ": $1" </del>