From: Rainer M. <ra...@tb...> - 2006-06-14 16:54:22
|
Andrew great news! > Is there a way to have something like: > > #define SUNDIALS_INSTALLATION "/usr/local/" > #define SOSLIB_INSTALLATION "/usr/home/finney" i guess, all we need to do is add some lines like AC_DEFINE([USE_SUNDIALS_SUNDIALS], 1, [Define to 1 to use the SUNDIALS Library]) to the config/sundials.m4 file using the existing variables $SUNDIALS_CFLAGS, $SUNDIALS_LDFLAGS and $SUNDIALS_LIBS that we discussed earlier. Their value is printed as the final output of the configure process. They already contain the -L and -I switches. The $prefix variable should contain the SOSlib installation path. Maybe these variables could be used directly and you only need to add the following lines to config/sundials.m4 AC_DEFINE([SUNDIALS_CFLAGS], $SUNDIALS_CFLAGS, [SUNDIALS include directory]) AC_DEFINE([SUNDIALS_LDFLAGS], $SUNDIALS_LDFLAGS, [SUNDIALS lib directory]) AC_DEFINE([SUNDIALS_LIBS], $SUNDIALS_LIBS, [SUNDIALS lib switches]) If we don't want the -L, -I, or the specific include and lib subdirectories we could use sed to remove these and define new variables. For SOSlib directories, the line AC_DEFINE([SOSLIB_INSTALLATION], $prefix, [SSOSlib install directory]) should be in the configure.in file. I think that should do it, but i am also not an expert on this. Xtof, what do you think? Rainer On Wed, 14 Jun 2006, Andrew Finney wrote: > Rainer > > I have managed get SOSlib to build on AIX and > more importantly I have managed to implement dynamic compilation using > g++ and shared libraries the same way as I did for windows using tcc. > The performance seems to be in the same ball park as the compiled code > was achieving on windows. I assumed that tcc is i386 specific. > > I'm effectively working on my own branch as I have not resolved the > `bug` in the most recent checked in source that's caused our model to > fail. So I'll probably just email you the relevant source files. I'll > try to document all the hacks required to get SOSlib to build > on AIX. > > One issue: > > I need to get hold of the include directory for sundials and SOSlib for > the dynamic compilation, that is in the code and not in a build file. > All the files use temporary filenames > > Is there a way to have something like: > > #define SUNDIALS_INSTALLATION "/usr/local/" > #define SOSLIB_INSTALLATION "/usr/home/finney" > > or > > #define SUNDIALS_INCLUDE "/usr/local/include" > #define SOSLIB_INCLUDE "/usr/home/finney/include" > > inserted into config.h > > ? > > I assume this means some kind of configure.in hack > I'm not exactly a guru on that so guidance would be nice. > > Background: > > At the moment I have to hard code the include path which is not ideal. > I tried using the same technique as windows: locate the sos > shared/dynamic library and then locate the include directory relative to > that. I ran into a showstopper on that on AIX : missing struct > definition in the include files. Anyway that's not the ideal approach > using the above would be better in an open-source build to install > environment. > > yours Andrew > > > > > > > > _______________________________________________ > sbmlsolver-devel mailing list > sbm...@li... > https://lists.sourceforge.net/lists/listinfo/sbmlsolver-devel > |