#21434 closed defect (fixed)
NcursesW will not build universal -- solution
Reported by: | michael-macports@… | Owned by: | imajes@… |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 1.8.0 |
Keywords: | Cc: | martijn@…, MarcusCalhoun-Lopez (Marcus Calhoun-Lopez) | |
Port: | ncursesw |
Description
Ncursesw will not build universal.
On a PPC machine, building i386, you need the following:
Nope, turns out it needs CFLAGS='-arch i386' CXXFLAGS='-arch i386'
To clarify: The old build was specifying the cross compiler flags correctly, but was NOT specifying the build arch. Hence, the cross compiler test did not come out correct, and the program does not build.
=== This might not solve the issue for building universal on x86. The build script assumes that if you can run an executable produced by the compiler, then it is not a cross compile. I know x86 can run ppc applications; I don't know if they can run ppc unix programs.
Attachments (2)
Change History (21)
comment:1 Changed 15 years ago by michael-macports@…
comment:2 Changed 15 years ago by jmroot (Joshua Root)
Owner: | changed from macports-tickets@… to imajes@… |
---|
Please use either attachments or WikiFormatting...
comment:5 Changed 15 years ago by martijn@…
Can anyone be so kind to explain where I should put this?
"Nope, turns out it needs CFLAGS='-arch i386' CXXFLAGS='-arch i386'
comment:6 Changed 15 years ago by drechsel@…
Will somebody please be so kind and give a step-for-step instruction for the CFLAGS='-arch i386' CXXFLAGS='-arch i386' thing? - I came into the same problem.
comment:7 Changed 15 years ago by ak@…
Yep, would be nice to move this forward - having the same issue here.
Maybe we should just give up the pretense that macports is universal?
comment:8 Changed 15 years ago by drechsel@…
BTW.: Sorry, I forgot: I tried to build Ncursesw as +universal variant on a PPC (G4), Mac OS X 10.4
comment:9 Changed 15 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
Cc: | mcalhoun@… added |
---|
Cc Me!
comment:10 follow-up: 11 Changed 15 years ago by ryandesign (Ryan Carsten Schmidt)
Marcus, maybe you have some idea? I'm afraid I don't have time to try to understand everything your universal changes from r47312 are doing.
comment:11 follow-up: 12 Changed 15 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
Replying to ryandesign@…:
Marcus, maybe you have some idea? I'm afraid I don't have time to try to understand everything your universal changes from r47312 are doing.
I am at a bit of a loss.
Universal ncursesw (both ppc/i386 and i386/x86_64) build fine on my machine (10.6.2).
Perhaps someone could post the config.log for the failing build architecture.
comment:12 Changed 15 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
Replying to mcalhoun@…:
Replying to ryandesign@…:
Marcus, maybe you have some idea? I'm afraid I don't have time to try to understand everything your universal changes from r47312 are doing.
I am at a bit of a loss.
Universal ncursesw (both ppc/i386 and i386/x86_64) build fine on my machine (10.6.2).Perhaps someone could post the config.log for the failing build architecture.
Can you build it for PPC and i386 on a 10.5.8 PPC host machine? That's where I wasn't able to build it.
Unfortunately, I do not have access to a PPC machine to test on.
I would be happy to try to get it working, but someone with a PPC machine will have to help me out.
Sending the config.log might be a good place to start.
Changed 15 years ago by drechsel@…
Attachment: | ncurses-5.7-i386-config.log added |
---|
comment:13 Changed 15 years ago by drechsel@…
I attached a config.log from /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_ncursesw/work/ncurses-5.7-i386/ - I hope, that is what you folks need. If not - please let me know where to look. NB.: G4 PPC, Mac OS X 10.4.11
The error message is the same as in the initial post. Yours, Wolf
comment:14 Changed 15 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
For cross-compiling, the configure script requires two compilers: one for the build architecture
and one for the run architecture.
It assumes that if they are they same, then there must be an error.
On MacPorts, -arch is set in CFLAGS, so the compilers are the same.
I think that the attached patch will fix the problem.
Would someone mind confirming this?
Changed 15 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
Attachment: | Portfile.diff added |
---|
comment:16 Changed 15 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
Resolution: | → fixed |
---|---|
Status: | new → closed |
Fixed in r64168.
comment:17 follow-up: 18 Changed 15 years ago by martijn@…
Nice. When can we expect this fix in the repos? Just update?
comment:18 Changed 15 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
Replying to martijn@…:
Nice. When can we expect this fix in the repos? Just update?
Yes, the fix is already in the repository.
comment:19 Changed 15 years ago by martijn@…
Confirmed. Gtk still fails to build though. I created a new ticket: #23851
Here is a complete output of attempting to build from scratch.