[GRASS-dev] [GRASS-user] Compiling under OSX Mountain Lion

On Thu, Nov 29, 2012 at 3:12 AM, William Kyngesburye
<woklist@kyngchaos.com> wrote:

On Nov 28, 2012, at 12:27 PM, Markus Neteler wrote:

On Wed, Nov 28, 2012 at 6:35 PM, Carlos Grohmann
<carlos.grohmann@gmail.com> wrote:

Hi

so, all modules under guy/wxpython that didn't compile show the same error:

/usr/local/lib/wxPython-unicode-2.8.12.1/lib/python2.7/site-packages/wx-2.8-mac-unicode/wx/_core_.so:
no matching architecture in universal wrapper
make: *** [g.gui.animation.tmp.html] Error 1

and both modules under visualization also have a common problem

"_wxEVT_ERASE_BACKGROUND", referenced from:
     __static_initialization_and_destruction_0(int, int)in gui.o
"_wxEVT_IDLE", referenced from:
     __static_initialization_and_destruction_0(int, int)in main.o
"_wxEVT_NULL", referenced from:
     __static_initialization_and_destruction_0(int, int)in gui.o
     __static_initialization_and_destruction_0(int, int)in main.o
"_wxEmptyString", referenced from:
     wxStringBase::Init() in gui.o
"_wxFrameNameStr", referenced from:
     MyFrame::MyFrame(wxString const&, int, int, gui_data*)in gui.o
     MyFrame::MyFrame(wxString const&, int, int, gui_data*)in gui.o
"_wxPanelNameStr", referenced from:
     MyCanvas::MyCanvas(wxWindow*, int, wxSize const&)in gui.o
     MyCanvas::MyCanvas(wxWindow*, int, wxSize const&)in gui.o
"_wxStaticTextNameStr", referenced from:
     MyFrame::MyFrame(wxString const&, int, int, gui_data*)in gui.o
     MyFrame::MyFrame(wxString const&, int, int, gui_data*)in gui.o
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
lipo: can't open input file:
/var/folders/gf/8bwpz0412gs7706j57hdyb4h0000gn/T//ccTJ28Cm.out (No such file
or directory)
make: ***
[/Volumes/HDD/Users/guano/Documents/installs/GIS/grass/grass_trunk/dist.x86_64-apple-darwin12.2.0/bin/xganim]
Error 1

WxPython 2.8 can only be built 32bit (aka Carbon). GRASS configuration will detect if wxPython is 64bit-ready, and force compilation in 32bits if not, but that only works if you configure GRASS at least 32bit. ie 32bit only, or 32+64bit. The default on Mt Lion is 64bit-only if you don't set any arch options.

This is why compilation with WxPython 2.9 works, because it can use 64bit Cocoa. But then there is the runtime problem that has yet to be solved.

What about the fix r40523 from the discussion mentioned by Markus?
Could it be helpful in this case?

Anna

-----
William Kyngesburye <kyngchaos*at*kyngchaos*dot*com>
http://www.kyngchaos.com/

"I ache, therefore I am. Or in my case - I am, therefore I ache."

- Marvin

_______________________________________________
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user

Just a note that when compiling trunk on

MacOSX 10.6.8, running python2.6

I get Errors in:
/Users/helena/grassdev7/grass_trunk/general/g.version
/Users/helena/grassdev7/grass_trunk/gui/wxpython/animation
/Users/helena/grassdev7/grass_trunk/gui/wxpython/mapswipe
/Users/helena/grassdev7/grass_trunk/gui/wxpython/gmodeler
/Users/helena/grassdev7/grass_trunk/gui/wxpython/rlisetup

but mapswipe and gmodeler works anyway,
unfortunately animation does not although they all show the same error (see below).

Helena

Traceback (most recent call last):
  File "/Users/helena/grassdev7/grass_trunk/dist.x86_64-apple-darwin10.8.0/scripts/g.gui.animation", line 42, in <module>
    import wx
  File "/var/tmp/wxWidgets/wxWidgets-13~231/2.6/DSTROOT/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode/wx/__init__.py", line 45, in <module>
  File "/var/tmp/wxWidgets/wxWidgets-13~231/2.6/DSTROOT/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode/wx/_core.py", line 4, in <module>
ImportError: /System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode/wx/_core_.so: no appropriate 64-bit architecture (see "man python" for running in 32-bit mode)
make: *** [g.gui.animation.tmp.html] Error 1

Traceback (most recent call last):
  File "/Users/helena/grassdev7/grass_trunk/dist.x86_64-apple-darwin10.8.0/scripts/g.gui.mapswipe", line 40, in <module>
    import wx
  File "/var/tmp/wxWidgets/wxWidgets-13~231/2.6/DSTROOT/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode/wx/__init__.py", line 45, in <module>
  File "/var/tmp/wxWidgets/wxWidgets-13~231/2.6/DSTROOT/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode/wx/_core.py", line 4, in <module>
ImportError: /System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode/wx/_core_.so: no appropriate 64-bit architecture (see "man python" for running in 32-bit mode)
make: *** [g.gui.mapswipe.tmp.html] Error 1

Helena Mitasova
Associate Professor
Department of Marine, Earth, and Atmospheric Sciences
2800 Faucette Drive, Rm. 1125 Jordan Hall
North Carolina State University
Raleigh, NC 27695-8208
hmitaso@ncsu.edu

"All electronic mail messages in connection with State business which are sent to or received by this account are subject to the NC Public Records Law and may be disclosed to third parties.”

On Nov 29, 2012, at 3:09 PM, Anna Kratochvílová wrote:

On Thu, Nov 29, 2012 at 3:12 AM, William Kyngesburye
<woklist@kyngchaos.com> wrote:

On Nov 28, 2012, at 12:27 PM, Markus Neteler wrote:

On Wed, Nov 28, 2012 at 6:35 PM, Carlos Grohmann
<carlos.grohmann@gmail.com> wrote:

Hi

so, all modules under guy/wxpython that didn't compile show the same error:

/usr/local/lib/wxPython-unicode-2.8.12.1/lib/python2.7/site-packages/wx-2.8-mac-unicode/wx/_core_.so:
no matching architecture in universal wrapper
make: *** [g.gui.animation.tmp.html] Error 1

and both modules under visualization also have a common problem

"_wxEVT_ERASE_BACKGROUND", referenced from:
    __static_initialization_and_destruction_0(int, int)in gui.o
"_wxEVT_IDLE", referenced from:
    __static_initialization_and_destruction_0(int, int)in main.o
"_wxEVT_NULL", referenced from:
    __static_initialization_and_destruction_0(int, int)in gui.o
    __static_initialization_and_destruction_0(int, int)in main.o
"_wxEmptyString", referenced from:
    wxStringBase::Init() in gui.o
"_wxFrameNameStr", referenced from:
    MyFrame::MyFrame(wxString const&, int, int, gui_data*)in gui.o
    MyFrame::MyFrame(wxString const&, int, int, gui_data*)in gui.o
"_wxPanelNameStr", referenced from:
    MyCanvas::MyCanvas(wxWindow*, int, wxSize const&)in gui.o
    MyCanvas::MyCanvas(wxWindow*, int, wxSize const&)in gui.o
"_wxStaticTextNameStr", referenced from:
    MyFrame::MyFrame(wxString const&, int, int, gui_data*)in gui.o
    MyFrame::MyFrame(wxString const&, int, int, gui_data*)in gui.o
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
lipo: can't open input file:
/var/folders/gf/8bwpz0412gs7706j57hdyb4h0000gn/T//ccTJ28Cm.out (No such file
or directory)
make: ***
[/Volumes/HDD/Users/guano/Documents/installs/GIS/grass/grass_trunk/dist.x86_64-apple-darwin12.2.0/bin/xganim]
Error 1

WxPython 2.8 can only be built 32bit (aka Carbon). GRASS configuration will detect if wxPython is 64bit-ready, and force compilation in 32bits if not, but that only works if you configure GRASS at least 32bit. ie 32bit only, or 32+64bit. The default on Mt Lion is 64bit-only if you don't set any arch options.

This is why compilation with WxPython 2.9 works, because it can use 64bit Cocoa. But then there is the runtime problem that has yet to be solved.

What about the fix r40523 from the discussion mentioned by Markus?
Could it be helpful in this case?

Anna

-----
William Kyngesburye <kyngchaos*at*kyngchaos*dot*com>
http://www.kyngchaos.com/

"I ache, therefore I am. Or in my case - I am, therefore I ache."

- Marvin

_______________________________________________
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user

_______________________________________________
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

This could happen if you configured for wxPython 2.9 64bit, but didn't bundle it so it finds the old 32bit wxPython 2.8 in the system at runtime. If you configure for wxPython 2.8 you should not get arch errors, at least if you make sure to configure 32+64bit.

On Nov 29, 2012, at 11:03 PM, Helena Mitasova wrote:

Just a note that when compiling trunk on

MacOSX 10.6.8, running python2.6

I get Errors in:
/Users/helena/grassdev7/grass_trunk/general/g.version
/Users/helena/grassdev7/grass_trunk/gui/wxpython/animation
/Users/helena/grassdev7/grass_trunk/gui/wxpython/mapswipe
/Users/helena/grassdev7/grass_trunk/gui/wxpython/gmodeler
/Users/helena/grassdev7/grass_trunk/gui/wxpython/rlisetup

but mapswipe and gmodeler works anyway,
unfortunately animation does not although they all show the same error (see below).

Helena

Traceback (most recent call last):
File "/Users/helena/grassdev7/grass_trunk/dist.x86_64-apple-darwin10.8.0/scripts/g.gui.animation", line 42, in <module>
   import wx
File "/var/tmp/wxWidgets/wxWidgets-13~231/2.6/DSTROOT/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode/wx/__init__.py", line 45, in <module>
File "/var/tmp/wxWidgets/wxWidgets-13~231/2.6/DSTROOT/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode/wx/_core.py", line 4, in <module>
ImportError: /System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode/wx/_core_.so: no appropriate 64-bit architecture (see "man python" for running in 32-bit mode)
make: *** [g.gui.animation.tmp.html] Error 1

Traceback (most recent call last):
File "/Users/helena/grassdev7/grass_trunk/dist.x86_64-apple-darwin10.8.0/scripts/g.gui.mapswipe", line 40, in <module>
   import wx
File "/var/tmp/wxWidgets/wxWidgets-13~231/2.6/DSTROOT/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode/wx/__init__.py", line 45, in <module>
File "/var/tmp/wxWidgets/wxWidgets-13~231/2.6/DSTROOT/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode/wx/_core.py", line 4, in <module>
ImportError: /System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode/wx/_core_.so: no appropriate 64-bit architecture (see "man python" for running in 32-bit mode)
make: *** [g.gui.mapswipe.tmp.html] Error 1

-----
William Kyngesburye <kyngchaos*at*kyngchaos*dot*com>
http://www.kyngchaos.com/

"I ache, therefore I am. Or in my case - I am, therefore I ache."

- Marvin

Hi Helena,

2012/11/30 Helena Mitasova <hmitaso@ncsu.edu>:

/Users/helena/grassdev7/grass_trunk/general/g.version

what concretely fails?

cd /Users/helena/grassdev7/grass_trunk/general/g.version
make

?

Probably related to [1]. Try `svn up` first.

Martin

[1] http://lists.osgeo.org/pipermail/grass-dev/2012-November/060985.html

--
Martin Landa <landa.martin gmail.com> * http://geo.fsv.cvut.cz/~landa

On Nov 30, 2012, at 10:08 AM, William Kyngesburye wrote:

This could happen if you configured for wxPython 2.9 64bit, but didn't bundle it so it finds the old 32bit wxPython 2.8 in the system at runtime. If you configure for wxPython 2.8 you should not get arch errors, at least if you make sure to configure 32+64bit.

I am pretty sure this is my case - can you please look at my configure and if possible give my some hints
on what should I do differently?

Thank you, Helena

(attachments)

configurehela.sh (3.9 KB)

when I need to display 3D vector points as 3D points (not draped over a surface), is this supposed to happen automatically
when I switch off the display on surface button or it is not supported yet?
I get that the vector map is 3D but there is no button to tell it that the points should be displayed using their z-coordinate.
maybe I am missing something?

Thank you, Helena

On Fri, Nov 30, 2012 at 7:56 PM, Helena Mitasova <hmitaso@ncsu.edu> wrote:

when I need to display 3D vector points as 3D points (not draped over a surface), is this supposed to happen automatically
when I switch off the display on surface button or it is not supported yet?
I get that the vector map is 3D but there is no button to tell it that the points should be displayed using their z-coordinate.
maybe I am missing something?

Currently, 3D points should be drawn with z coordinate by default. The
'display on surface' is misleading, now you can't drape them over any
surface.
This option is present in the library, so it must be added to the gui.
I will try to look at it later.

Anna

Thank you, Helena

On Nov 30, 2012, at 10:30 AM, Helena Mitasova wrote:

On Nov 30, 2012, at 10:08 AM, William Kyngesburye wrote:

This could happen if you configured for wxPython 2.9 64bit, but didn't bundle it so it finds the old 32bit wxPython 2.8 in the system at runtime. If you configure for wxPython 2.8 you should not get arch errors, at least if you make sure to configure 32+64bit.

I am pretty sure this is my case - can you please look at my configure and if possible give my some hints
on what should I do differently?

Thank you, Helena

Well, you're configuring OK - 32+64bit, system wxpython 2.8 (32bit). Though the system wxpython is technically within the minimum version, it's a bit old, but it shouldn't have an affect on the architectures.

The "enable-64bit" option is meaningless on OS X, the archs option handles all we need for 64bit.

I do recall issues with the debug flag (not sure if it was GRASS or something else). Try removing -g from CFLAGS, or change it to -Os.

One way to check if it configured correctly for wxpython archs is to look at platform.make, MACOSX_ARCHS_WXPYTHON. There should be only i386 there.

-----
William Kyngesburye <kyngchaos*at*kyngchaos*dot*com>
http://www.kyngchaos.com/

"I ache, therefore I am. Or in my case - I am, therefore I ache."

- Marvin