cschwan / sage-on-gentoo

(Unofficial) Gentoo Overlay for Sage- and Sage-related ebuilds
84 stars 26 forks source link

dev-gap/GUAVA-3.13 - /bin/sh: line 0: cd: too many arguments #447

Closed devurandom closed 7 years ago

devurandom commented 7 years ago
make[1]: Entering directory '/var/tmp/portage/dev-gap/GUAVA-3.13/work/guava-3.13/src'
x86_64-pc-linux-gnu-gcc  -pipe -O2 -march=bdver3 -Wl,-O1 -Wl,--as-needed -Wl,--hash-style=gnu -o leonconv leonconv.c
cd leon make
/bin/sh: line 0: cd: too many arguments
make[1]: *** [Makefile:14: all] Error 1

build.log.zip

kiwifb commented 7 years ago

Funny, it doesn't fail here. What is your shell? I am guessing we are dealing with a bashism.

kiwifb commented 7 years ago

I am still being shocked at how inconsistent makefiles are for this kind of stuff. It is a big QA in any case. Fix coming when I get to work.

kiwifb commented 7 years ago

OK, that should fix the issue. I also did some clean up and fixed parallel make (removing emake -j1) while I was at it.

dimpase commented 7 years ago

I have seen this on my gentoo system. (Working with Sage from source).

Should we fix this in Sage (package gap_packages) too?

kiwifb commented 7 years ago

You are welcome to adopt it if you want. The commit does a lot more than fixing this particular issue, you may want to be a bit selective. I can review the ticket if you like.

dimpase commented 7 years ago

I must say I don't understand the issue, why cd leon make apparently works on other systems, but not on gentoo. (and there is a missing makefile in leon/?!)

kiwifb commented 7 years ago

That's a concern. cd leon make is certainly not portable. There are at least 2 QA problems with that statement - I don't understand that it works at all on a lot of systems.

There should be a Makefile.in in src/leon and configure in src/leon will generate your makefile as usual. Left on its own the top makefile will run configure in src/leon but there may be a few dependency issue to carefully look at in that top makefile.

In Gentoo the approach is to run src/leon/configure in the configure phase and not let the Makefile do it during building.

kiwifb commented 7 years ago

I should add that I didn't experience the problem on my own gentoo systems. I suspect the problem is linked to what is set as the default sh or possibly your default shell.

dimpase commented 7 years ago

my bin/sh is a link to bash. IMHO every shell I have is actually bash.

kiwifb commented 7 years ago

Well then I have currently no ideas what is causing the trouble on some system. I just know that I am not surprised at all that it fails. Ticket on trac?

dimpase commented 7 years ago

here you are: https://trac.sagemath.org/ticket/22116