grumpyhome / grumpy

Grumpy is a Python to Go source code transcompiler and runtime.
Apache License 2.0
420 stars 18 forks source link

Fix 32bit compilation #98

Closed alanjds closed 6 years ago

alanjds commented 6 years ago

google/grumpy#399 opened on Mar 7 by @alanjds

Related to https://github.com/golang/go/issues/23086#issuecomment-371017565

When trying to compile on 32bit CPU, the import of __go__.math fails:

$ echo 'print "Hello"' | make run --debug
...
Must remake target 'build/pkg/android_arm/__python__/__go__/math.a'.
 # __python__/__go__/math
build/src/__python__/__go__/math/module.go:273:54: constant 9223372036854775807 overflows int
build/src/__python__/__go__/math/module.go:288:54: constant 4294967295 overflows int
build/src/__python__/__go__/math/module.go:318:54: constant -9223372036854775808 overflows int 
make: *** [Makefile:260: build/pkg/android_arm/__python__/__go__/math.a] Error 2
$

Had not included a test as Travis CI have no such machines available

alanjds commented 6 years ago

Comment by alanjds Wednesday Mar 28, 2018 at 15:00 GMT


@trotterdylan Can you please take a look on this one? As most of my development time is on Android, all my development bases on this branch.

Travis have no 32bit machines and this math thing is a Golang issue to be fixed only on Go 2

alanjds commented 6 years ago

Comment by alanjds Wednesday Mar 28, 2018 at 15:03 GMT


Is there other committers available so I can round-robin instead of keep poking @trotterdylan every time? Wondering when he will get tired :P

alanjds commented 6 years ago

Comment by alanjds Monday Apr 09, 2018 at 23:08 GMT


I am forking away my master branch.

As said before, on my main spare time I only have a 32bit CPU available. Keeping on a stale master only slows down Grumpy development.

I hope to get able to have my master merged back. I hope the project to succeed. But it will not occur if people willing to contribute will wait >30d for feedback, even a "No time - will read later" one. This is not a good way to build a community, in my humble opinion.

If the committers have no bandwith available anymore, please make it clear. I do hearty thanks the ones that could bring Grumpy up and published it, my sincere admiration and kudos for you. But the effort will be gone if nothing changes here.

alanjds commented 6 years ago

Already merged manually.