You are not using a clean svn version (see the output of your "svn st" command). Just start over. Remove the install directory. Check out a clean version from SVN and try to get that to build. There's no point trying to write a plugin until you can successfully run Open Babel from SVN.
- Noel On 15 September 2012 00:08, joaquin peralta <jperal...@gmail.com> wrote: > Hello, > > Before I put all the text, just allow me to explain : > > I'm not compiling with my plugin, it is just a clean svn version. I tried > with make clean and make and the problem still, I just set all environment > variables and the problem still. > > The problem is running : babel -H (that single command send me a segfault) > so I did this with gdb : > > =================================================================================== > jperaltac@baco:~/buildob$ gdb "/home/jperaltac/local/bin/babel" > .......... > Reading symbols from /home/jperaltac/local/bin/babel...done. > (gdb) run -H > Starting program: /home/jperaltac/local/bin/babel -H > Open Babel converts chemical structures from one file format to another > > Usage: babel <input spec> <output spec> [Options] > > Each spec can be a file whose extension decides the format. > Optionally the format can be specified by preceding the file by > -i<format-type> e.g. -icml, for input and -o<format-type> for output > > See below for available format-types, which are the same as the > file extensions and are case independent. > If no input or output file is given stdin or stdout are used instead. > > More than one input file can be specified and their names can contain > wildcard chars (* and ?).The molecules are aggregated in the output file. > > Conversion options > -f <#> Start import at molecule # specified > -l <#> End import at molecule # specified > -e Continue with next object after error, if possible > -z Compress the output with gzip > -k Attempt to translate keywords > -H Outputs this help text > -V Outputs version number > -L <category> Lists plugin classes of this category, e.g. <formats> > Use just -L for a list of plugin categories. > Use -L <ID> e.g. -L sdf for details of a format or other plugin. > -m Produces multiple output files, to allow: > Splitting: e.g. babel infile.mol new.smi -m > puts each molecule into new1.smi new2.smi etc > Batch conversion: e.g. babel *.mol -osmi -m > converts each input file to a .smi file > > Program received signal SIGSEGV, Segmentation fault. > 0x000000000040769f in std::vector<std::string, std::allocator<std::string> >>::max_size (this=0x7fffff7ff130) at > /usr/include/c++/4.6/bits/stl_vector.h:576 > 576 { return _M_get_Tp_allocator().max_size(); } > (gdb) > > =================================================================================== > > then looking with 'where' in gdb I have : > > =================================================================================== > > #0 0x000000000040769f in std::vector<std::string, > std::allocator<std::string> >::max_size (this=0x7fffff7ff130) at > /usr/include/c++/4.6/bits/stl_vector.h:576 > #1 0x00000000004072c9 in std::vector<std::string, > std::allocator<std::string> >::_M_check_len (this=0x7fffff7ff130, __n=1, > __s=0x4083da "vector::_M_insert_aux") > at /usr/include/c++/4.6/bits/stl_vector.h:1241 > #2 0x0000000000406d43 in std::vector<std::string, > std::allocator<std::string> >::_M_insert_aux (this=0x7fffff7ff130, > __position=..., __x=...) at /usr/include/c++/4.6/bits/vector.tcc:325 > #3 0x000000000040694a in std::vector<std::string, > std::allocator<std::string> >::push_back (this=0x7fffff7ff130, __x=...) at > /usr/include/c++/4.6/bits/stl_vector.h:834 > #4 0x00007ffff7704c33 in DLHandler::findFiles (file_list=..., pattern=..., > path=...) at /home/jperaltac/Projects/openbabel/src/dlhandler_unix.cpp:82 > #5 0x00007ffff76c1fc4 in OpenBabel::OBPlugin::LoadAllPlugins () at > /home/jperaltac/Projects/openbabel/src/plugin.cpp:61 > #6 0x00007ffff76c1ed6 in OpenBabel::OBPlugin::GetTypeMap > (PluginID=0x7ffff7762d07 "loaders") at > /home/jperaltac/Projects/openbabel/src/plugin.cpp:34 > #7 0x00007ffff76c23b9 in OpenBabel::OBPlugin::GetPlugin > (Type=0x7ffff7762d07 "loaders", ID=0x7ffff7762d00 "define") at > /home/jperaltac/Projects/openbabel/src/plugin.cpp:110 > #8 0x00007ffff76c207b in OpenBabel::OBPlugin::LoadAllPlugins () at > /home/jperaltac/Projects/openbabel/src/plugin.cpp:80 > > ... The lines #6,#7, and #8 are repeated a lot after that ... > =================================================================================== > > Now the document that I attahced before about the process : > > =================================================================================== > My installation process from svn. > > jperaltac@baco:~/Projects/openbabel$ sudo find / -iname "abinitformat.so" > jperaltac@baco:~/Projects/openbabel$ svn st > ? test/files/prueba.xyz > ? test/files/Au.lpmd > A src/formats/lpmdformat.cpp > jperaltac@baco:~/Projects/openbabel$ svn up > At revision 5011. > jperaltac@baco:~/Projects/openbabel$ > > Compiling > > jperaltac@baco:~/Projects/openbabel$ export > BABEL_LIBDIR=/home/jperaltac/local/lib/openbabel/ > jperaltac@baco:~/Projects/openbabel$ > > Then > jperaltac@baco:~/Projects/openbabel$ cd ~/buildob/ > jperaltac@baco:~/buildob$ ls > jperaltac@baco:~/buildob$ cmake -DCMAKE_BUILD_TYPE=Debug > -DCMAKE_INSTALL_PREFIX=/home/jperaltac/local/ ~/Projects/openbabel/ > -- The C compiler identification is GNU > -- The CXX compiler identification is GNU > -- Check for working C compiler: /usr/bin/gcc > -- Check for working C compiler: /usr/bin/gcc -- works > -- Detecting C compiler ABI info > -- Detecting C compiler ABI info - done > -- Check for working CXX compiler: /usr/bin/c++ > -- Check for working CXX compiler: /usr/bin/c++ -- works > -- Detecting CXX compiler ABI info > -- Detecting CXX compiler ABI info - done > -- Using included inchi library. > -- Could NOT find LibXml2 (missing: LIBXML2_LIBRARIES LIBXML2_INCLUDE_DIR) > CMake Warning at CMakeLists.txt:152 (message): > libxml2 not found - disabling CML support! > > > -- Found ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found version "1.2.3.4") > -- Could NOT find wxWidgets (missing: wxWidgets_FOUND) > -- Looking for conio.h > -- Looking for conio.h - not found > -- Looking for sys/time.h > -- Looking for sys/time.h - found > -- Looking for time.h > -- Looking for time.h - found > -- Looking for strings.h > -- Looking for strings.h - found > -- Looking for rpc/xdr.h > -- Looking for rpc/xdr.h - found > -- Looking for regex.h > -- Looking for regex.h - found > -- Looking for C++ include sstream > -- Looking for C++ include sstream - found > -- Looking for rint > -- Looking for rint - not found. > -- Looking for snprintf > -- Looking for snprintf - found > -- Looking for sranddev > -- Looking for sranddev - not found. > -- Looking for strcasecmp > -- Looking for strcasecmp - found > -- Looking for strncasecmp > -- Looking for strncasecmp - found > -- Looking for dlopen in dl > -- Looking for dlopen in dl - found > -- Looking for sys/types.h > -- Looking for sys/types.h - found > -- Looking for stdint.h > -- Looking for stdint.h - found > -- Looking for stddef.h > -- Looking for stddef.h - found > -- Check size of clock_t > -- Check size of clock_t - done > -- Performing Test SCANDIR_NEEDS_CONST > -- Performing Test SCANDIR_NEEDS_CONST - Failed > -- Performing Test HAVE_GCC_VISIBILITY > -- Performing Test HAVE_GCC_VISIBILITY - Success > -- Could NOT find Eigen3 (missing: EIGEN3_INCLUDE_DIR EIGEN3_VERSION_OK) > (Required is at least version "2.91.0") > -- Could NOT find Eigen2 (missing: EIGEN2_INCLUDE_DIR EIGEN2_VERSION_OK) > (Required is at least version "2.0.0") > -- checking for module 'cairo' > -- package 'cairo' not found > -- Could NOT find Cairo. PNG output will NOT be supported. > -- Looking for getopt > -- Looking for getopt - found > -- Attempting to build the GUI > -- wxWidgets not found => GUI will not be built > -- Found PythonInterp: /usr/bin/python (found version "2.7.3") > -- Configuring done > -- Generating done > -- Build files have been written to: /home/jperaltac/buildob > > Compiling > > make ; make instal > > Work finw without error message nor suspissious warnings. Then : > > jperaltac@baco:~/buildob$ babel > No output file or format spec! > Open Babel 2.3.2 -- Sep 14 2012 -- 17:07:39 > Usage: babel [-i<input-type>] <name> [-o<output-type>] <name> > Try -H option for more information. > jperaltac@baco:~/buildob$ babel -H > Open Babel converts chemical structures from one file format to another > > Usage: babel <input spec> <output spec> [Options] > > Each spec can be a file whose extension decides the format. > Optionally the format can be specified by preceding the file by > -i<format-type> e.g. -icml, for input and -o<format-type> for output > > See below for available format-types, which are the same as the > file extensions and are case independent. > If no input or output file is given stdin or stdout are used instead. > > More than one input file can be specified and their names can contain > wildcard chars (* and ?).The molecules are aggregated in the output file. > > Conversion options > -f <#> Start import at molecule # specified > -l <#> End import at molecule # specified > -e Continue with next object after error, if possible > -z Compress the output with gzip > -k Attempt to translate keywords > -H Outputs this help text > -V Outputs version number > -L <category> Lists plugin classes of this category, e.g. <formats> > Use just -L for a list of plugin categories. > Use -L <ID> e.g. -L sdf for details of a format or other plugin. > -m Produces multiple output files, to allow: > Splitting: e.g. babel infile.mol new.smi -m > puts each molecule into new1.smi new2.smi etc > Batch conversion: e.g. babel *.mol -osmi -m > converts each input file to a .smi file > Segmentation fault (core dumped) > jperaltac@baco:~/buildob$ > > Looks like somethings is wrong here, I don't know why the segmentation > fault!. Any hint now with this ? > > And my environments variables : > > jperaltac@baco:~/buildob$ env | grep bab > BABEL_LIBDIR=/home/jperaltac/local/lib/openbabel/ > OLDPWD=/home/jperaltac/Projects/openbabel > jperaltac@baco:~/buildob$ > > Finallym the valgrind output : > > ==1485== Stack overflow in thread 1: can't grow stack to 0x7fe801ff8 > ==1485== > ==1485== Process terminating with default action of signal 11 (SIGSEGV) > ==1485== Access not within mapped region at address 0x7FE801FF8 > ==1485== at 0x40790A: std::string* > std::__uninitialized_copy<false>::__uninit_copy<std::string*, > std::string*>(std::string*, std::string*, std::string*) > (stl_uninitialized.h:70) > ==1485== If you believe this happened as a result of a stack > ==1485== overflow in your program's main thread (unlikely but > ==1485== possible), you can try to increase the size of the > ==1485== main thread stack using the --main-stacksize= flag. > ==1485== The main thread stack size used in this run was 8388608. > ==1485== Stack overflow in thread 1: can't grow stack to 0x7fe801fe8 > ==1485== > ==1485== Process terminating with default action of signal 11 (SIGSEGV) > ==1485== Access not within mapped region at address 0x7FE801FE8 > ==1485== at 0x4A255A0: _vgnU_freeres (in > /usr/lib/valgrind/vgpreload_core-amd64-linux.so) > ==1485== If you believe this happened as a result of a stack > ==1485== overflow in your program's main thread (unlikely but > ==1485== possible), you can try to increase the size of the > ==1485== main thread stack using the --main-stacksize= flag. > ==1485== The main thread stack size used in this run was 8388608. > ==1485== > ==1485== HEAP SUMMARY: > ==1485== in use at exit: 1,813,622 bytes in 28,223 blocks > ==1485== total heap usage: 288,894 allocs, 260,671 frees, 866,039,001 > bytes allocated > ==1485== > ==1485== LEAK SUMMARY: > ==1485== definitely lost: 0 bytes in 0 blocks > ==1485== indirectly lost: 0 bytes in 0 blocks > ==1485== possibly lost: 1,758,118 bytes in 26,375 blocks > ==1485== still reachable: 55,504 bytes in 1,848 blocks > ==1485== suppressed: 0 bytes in 0 blocks > ==1485== Rerun with --leak-check=full to see details of leaked memory > ==1485== > ==1485== For counts of detected and suppressed errors, rerun with: -v > ==1485== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 2 from 2) > Segmentation fault (core dumped) > > =================================================================================== > > that's it! > > Thanks for all the help, and sorry about the long e-mail. > > Regards > Joaquin > > On Fri, Sep 14, 2012 at 5:45 PM, My Th <rei4...@gmail.com> wrote: >> >> Pk, 2012-09-14 17:17 -0500, joaquin peralta rakstīja: >> > Hello, >> >> > >> > Thanks very much for the answer but the problem looks worse now :( ... >> > I assign the environment variable, but still there. >> > >> > >> > I don't have any other version of openbabel in the system, and I'm >> > using the last subversion. My Os is ubuntu 12.04 and g++ versin is >> > 4.6.3. I'm installing in my home folder, and the PATH are well >> > defined. >> > >> > >> > I attached a file with all the detail, because is to much to put it in >> > the e-mail (and probably unnecessary). >> >> It is ok to put that much into the email. >> >> > Any hint about this segfault ? >> >> Try cleaning the build dir and recompile without installing: >> make clean ; make >> >> and then try to run it from your build dir setting environment >> appropriately. >> >> Did you try also setting LD_LIBRARY_PATH to point to were >> libopenbabel.so is located? In general you need to set all three >> variables mentioned in the docs and make sure you are running babel >> binary you just compiled. >> >> If still getting segfault try compiling with debug symbols and getting >> backtrace using gdb: >> gdb bin/babel core-file >> (gdb) bt full >> >> Posting your code would make much easier to help. >> >> >> Reinis >> >> >> >> ------------------------------------------------------------------------------ >> Got visibility? >> Most devs has no idea what their production app looks like. >> Find out how fast your code is with AppDynamics Lite. >> http://ad.doubleclick.net/clk;262219671;13503038;y? >> http://info.appdynamics.com/FreeJavaPerformanceDownload.html >> _______________________________________________ >> OpenBabel-discuss mailing list >> OpenBabel-discuss@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/openbabel-discuss > > > > > -- > Joaquín Peralta C. > Postdoctoral Research Associate > Materials Science and Engineering > Iowa State University > 3326 Hoover Hall > Ames, IA 50011 > Phone Lab: 515-294-9547 > http://www.lpmd.cl/jperalta > http://www.gnm.cl > ----------------------------------------------- > In a world without frontiers, > who needs Gates and Windows?. > > > ------------------------------------------------------------------------------ > Got visibility? > Most devs has no idea what their production app looks like. > Find out how fast your code is with AppDynamics Lite. > http://ad.doubleclick.net/clk;262219671;13503038;y? > http://info.appdynamics.com/FreeJavaPerformanceDownload.html > _______________________________________________ > OpenBabel-discuss mailing list > OpenBabel-discuss@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/openbabel-discuss > ------------------------------------------------------------------------------ How fast is your code? 3 out of 4 devs don\\\'t know how their code performs in production. Find out how slow your code is with AppDynamics Lite. http://ad.doubleclick.net/clk;262219672;13503038;z? http://info.appdynamics.com/FreeJavaPerformanceDownload.html _______________________________________________ OpenBabel-discuss mailing list OpenBabel-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openbabel-discuss