Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Community > Team MacNN > Nano-Hive

Nano-Hive
Thread Tools
Fresh-Faced Recruit
Join Date: Jan 2005
Status: Offline
Reply With Quote
Jan 17, 2005, 03:28 PM
 
Nano-Hive will theoretically compile and run on MacOS X, but we don't know of anyone trying it yet. It would be great if you gave it a shot with the old ./configure; make; here's the link to our download page: http://www.nano-hive.org/download.shtml A log of the build would be helpful to us as well. After it's built, try the Quick Start Tutorial in the Readme and let us know how it went! (Probably post results and any problems/questions to one of the resources here: http://www.nano-hive.org/support.shtml since we're getting a bit off-topic for a Nano@Home forum.)

From nano@home forum..
     
Junior Member
Join Date: May 2003
Location: Santa Cruz, CA
Status: Offline
Reply With Quote
Jan 17, 2005, 10:03 PM
 
Originally posted by Sune:
Nano-Hive will theoretically compile and run on MacOS X, but we don't know of anyone trying it yet. It would be great if you gave it a shot with the old ./configure; make; here's the link to our download page: http://www.nano-hive.org/download.shtml A log of the build would be helpful to us as well. After it's built, try the Quick Start Tutorial in the Readme and let us know how it went! (Probably post results and any problems/questions to one of the resources here: http://www.nano-hive.org/support.shtml since we're getting a bit off-topic for a Nano@Home forum.)

From nano@home forum..
I tried running ./configure and got this error:

checking for ccgnu2-config... no
checking for Common C++ version >= 0.99.0... not found
*** The ccgnu2-config script installed by Common C++
*** 0.99.0 or later could not be found. Adjust your PATH
*** environment variable so that it can be found and re-run
*** ./configure

-David
     
Senior User
Join Date: Feb 2002
Location: Silly Valley, Ca
Status: Offline
Reply With Quote
Jan 18, 2005, 02:04 AM
 
First you have to build and install:
Common C++ Libraries
Log for C++
Xerces C++ XML Parser

They are listed on their download page.

After you get all those built and installed you can try building nano-hive.
     
Senior User
Join Date: Feb 2002
Location: Silly Valley, Ca
Status: Offline
Reply With Quote
Jan 20, 2005, 02:34 AM
 
So I built and installed all the supporting libs and then NanoHive successfully built.
It need some more tweaking to get it working though as it can't find some symbols.
/usr/local/bin/NanoHive
dyld: /usr/local/bin/NanoHive Undefined symbols:
__ZNSs20_S_empty_rep_storageE
__ZNSs4_Rep11_S_max_sizeE
__ZNSs4_Rep11_S_terminalE
__ZNSt24__default_alloc_templateILb1ELi0EE12_S_for ce_newE
__ZNSt24__default_alloc_templateILb1ELi0EE12_S_fre e_listE
__ZNSt24__default_alloc_templateILb1ELi0EE22_S_nod e_allocator_lockE
__ZTVN10__cxxabiv117__class_type_infoE
__ZTVN10__cxxabiv120__si_class_type_infoE
__ZTVN10__cxxabiv121__vmi_class_type_infoE
___cxa_pure_virtual
___gxx_personality_v0
__ZNSs20_S_empty_rep_storageE
__ZNSs4_Rep11_S_max_sizeE
__ZNSs4_Rep11_S_terminalE
__ZNSt24__default_alloc_templateILb1ELi0EE12_S_for ce_newE
__ZNSt24__default_alloc_templateILb1ELi0EE12_S_fre e_listE
__ZNSt24__default_alloc_templateILb1ELi0EE22_S_nod e_allocator_lockE
__ZSt4cerr
__ZSt4cout
__ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamI T_T0_ES6_
__ZTIi
__ZTTSt14basic_ifstreamIcSt11char_traitsIcEE
__ZTVN10__cxxabiv117__class_type_infoE
__ZTVN10__cxxabiv119__pointer_type_infoE
__ZTVN10__cxxabiv120__si_class_type_in__ZTVN10__cx xabiv121__vmi_class_type_infoE
__ZTVSt13basic_filebufIcSt11char_traitsIcEE
__ZTVSt14basic_ifstreamIcSt11char_traitsIcEE
__ZTVSt15basic_streambufIcSt11char_traitsIcEE
__ZTVSt9basic_iosIcSt11char_traitsIcEE
___cxa_pure_virtual
___gxx_personality_v0
Trace/BPT trap
     
Sune  (op)
Fresh-Faced Recruit
Join Date: Jan 2005
Status: Offline
Reply With Quote
Jan 20, 2005, 08:58 AM
 
You don't already have those installed? Seriously though - I think we'll roll some RPMs for various platforms with those libraries compiled-in statically for our next release.

Was this on a G5? If so, it would be a big help to us if you built and installed those necessary libraries, and N-H ofcourse, and reported any problems or errors.

Thanks.


PS. You forgot to add TCL to your list, unless OS X already has it installed which it probably does.
     
Sune  (op)
Fresh-Faced Recruit
Join Date: Jan 2005
Status: Offline
Reply With Quote
Jan 21, 2005, 04:06 PM
 
All these symbols are likely defined in the standard C++ library. Try re-./configure;make'ing with forced libstdc++ linkage, ie, LDFLAGS=-lstdc++

You can give ./configure initial values for configuration parameters by setting variables in the command line or in the environment. Here's how to do it on the command line:

./configure LDFLAGS=-lstdc++ <any other options you used>

Let me know how that works..

Thanks!
     
Junior Member
Join Date: May 2003
Location: Santa Cruz, CA
Status: Offline
Reply With Quote
Jan 21, 2005, 10:58 PM
 
Originally posted by Sune:
All these symbols are likely defined in the standard C++ library. Try re-./configure;make'ing with forced libstdc++ linkage, ie, LDFLAGS=-lstdc++

You can give ./configure initial values for configuration parameters by setting variables in the command line or in the environment. Here's how to do it on the command line:

./configure LDFLAGS=-lstdc++ <any other options you used>

Let me know how that works..

Thanks!
I got as far as mikkyo, but I notice in my make install :

make install-data-hook
mkdir -p /usr/local/share/Nano-Hive
cp -r ./../bin/linux-x86 /usr/local/share/Nano-Hive/scripts
sed s\\NH_SHARE_HOME\\/usr/local/share/Nano-Hive\\g ./../bin/linux-x86/install-examples > /usr/local/share/Nano-Hive/scripts/install-examples
sed: 1: "s\NH_SHARE_HOME\/usr/lo ...": substitute pattern can not be delimited by newline or backslash
make[3]: *** [install-data-hook] Error 1
make[2]: *** [install-data-am] Error 2
make[1]: *** [install-am] Error 2
make: *** [install-recursive] Error 1
./configure LDFLAGS=-lstdc++ made no difference

-David
     
Senior User
Join Date: Feb 2002
Location: Silly Valley, Ca
Status: Offline
Reply With Quote
Jan 22, 2005, 12:33 PM
 
Yeah there is a sed error in the install-examples portion.

It should have already install the binary at that point.
try /usr/local/bin/NanoHive
(Last edited by mikkyo; Jan 22, 2005 at 03:21 PM. )
     
Sune  (op)
Fresh-Faced Recruit
Join Date: Jan 2005
Status: Offline
Reply With Quote
Jan 30, 2005, 04:31 PM
 
The good news is that I found out that Sourceforge, where Nano-Hive development is hosted, has a compile farm with various platforms including OS X, so we can do some compiling and testing on the various platforms to resolve issues like those above.

The bad news is that we haven't done it yet - we'll definitely do it for the next release though (due this quarter.)

If you're still game to help getting N-H successfully built on OS X, I suggest running 'ldd /usr/local/bin/NanoHive' or 'otool -L /usr/local/bin/NanoHive' to check whether the installed binary is linked against libstdc++, I suspect it is not. If it is you'll see something like:

[bh@nosecandy src]$ ldd /usr/local/bin/NanoHive
libtcl8.4.so => /usr/local/lib/libtcl8.4.so (0x40013000)
libxerces-c.so.25 => /usr/local/lib/libxerces-c.so.25 (0x400ac000)
...
libstdc++.so.5 => /usr/lib/libstdc++.so.5 (0x40502000)

It also appears that BSD sed doesn't like backslashes as substitute pattern delimiters (they work fine for GNU sed.) If you get the runtime error solved, you can fix the sed problems by replacing the \\ delimeters with semi-colon delimeters in the install-data-hook target in the Makefile:

Code:

install-data-hook:
mkdir -p $(pkgdatadir)
cp -r $(top_builddir)/../bin/linux-x86 $(pkgdatadir)/scripts
sed 's;NH_SHARE_HOME;$(pkgdatadir);g' $(top_builddir)/...



And also replace the delimiters in the bin/linux-x86/install-examples script, and run make install again. Or you can just wait for the next release which will have already been tested on OS X for you.

Thanks a bunch for trying the build on OS X.
     
Junior Member
Join Date: May 2003
Location: Santa Cruz, CA
Status: Offline
Reply With Quote
Jan 30, 2005, 06:34 PM
 
Originally posted by Sune:
If you're still game to help getting N-H successfully built on OS X, I suggest running 'ldd /usr/local/bin/NanoHive' or 'otool -L /usr/local/bin/NanoHive' to check whether the installed binary is linked against libstdc++, I suspect it is not.
It appears that you are correct that it isn't linked against libstdc++

here is the output of otool:

/usr/local/bin/NanoHive:
/usr/local/lib/libtcl8.4.dylib (compatibility version 8.4.0, current version 8.4.0)
libxerces-c.26.dylib (compatibility version 0.0.0, current version 0.0.0)
/usr/local/lib/libNanoHiveUtil.0.dylib (compatibility version 2.0.0, current version 2.0.0)
/usr/local/lib/libNanoHiveInterface.0.dylib (compatibility version 2.0.0, current version 2.0.0)
/usr/local/lib/libccgnu2-1.3.0.dylib (compatibility version 1.0.0, current version 1.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 71.1.1)
/usr/local/lib/liblog4cpp.3.dylib (compatibility version 5.0.0, current version 5.3.0)
It is the same even when explicitedly added as a paramater to ./configure per your earlier instructions

-David
     
Sune  (op)
Fresh-Faced Recruit
Join Date: Jan 2005
Status: Offline
Reply With Quote
Jan 31, 2005, 08:34 AM
 
     
Senior User
Join Date: Feb 2002
Location: Silly Valley, Ca
Status: Offline
Reply With Quote
Jan 31, 2005, 01:29 PM
 
Replacing \\ with semi colon doesn't work either.

make install-data-hook
mkdir -p /usr/local/share/Nano-Hive
cp -r ./../bin/linux-x86 /usr/local/share/Nano-Hive/scripts
sed s;NH_SHARE_HOME;/usr/local/share/Nano-Hive;g ./../bin/linux-x86/install-examples > /usr/local/share/Nano-Hive/scripts/install-examples
sed: 1: "s": substitute pattern can not be delimited by newline or backslash
/bin/sh: line 1: NH_SHARE_HOME: command not found
/bin/sh: line 1: /usr/local/share/Nano-Hive: is a directory
/bin/sh: line 1: g: command not found
make[3]: *** [install-data-hook] Error 127
make[2]: *** [install-data-am] Error 2
make[1]: *** [install-am] Error 2
make: *** [install-recursive] Error 1
     
Senior User
Join Date: Feb 2002
Location: Silly Valley, Ca
Status: Offline
Reply With Quote
Jan 31, 2005, 02:37 PM
 
replacing \\ with \; works though.
I got it to install now.
I linked it with libstc++ and it runs the 5x5 nanotube simulation.
     
Sune  (op)
Fresh-Faced Recruit
Join Date: Jan 2005
Status: Offline
Reply With Quote
Feb 1, 2005, 03:18 PM
 
The replacement I suggested actually had single quotes around the sed expression - which does work , but that's moot because you got it to install all the same.

I'm glad you got the binary to work! How did you do to get it linked against libstdc++?

Brian says hello
     
Senior User
Join Date: Feb 2002
Location: Silly Valley, Ca
Status: Offline
Reply With Quote
Feb 1, 2005, 10:49 PM
 
I added -lstdc++ to the Makefile.
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 02:54 AM.
All contents of these forums © 1995-2011 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.7 © 2000-2011, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2