On Wed, Mar 11, 2015 at 10:10 AM, Roy Stogner <royst...@ices.utexas.edu> wrote:
> > On Wed, 11 Mar 2015, Manav Bhatia wrote: > > > It is not getting called. I put a breakpoint there (actually, in the > > constructor of Singleton::Setup::Setup()) and the code does not get > > to it. > > This is looking more and more like a compiler bug, then. You must be > linking in remote_elem.C or you'd be missing the remote_elem symbol; > but if you're linking in remote_elem.C then you should be getting > the... > > Wait a minute. Is it possible you're using something other than icpc > for the final link step? IIRC you need to do the linking with a C++ > compiler for it to get the global constructors right. > This is a good point. Your application Makefile should use $(LIBMESH_DIR)/contrib/bin/libtool --tag=CXX --mode=link (...args...) $(LIBMESH_DIR)/contrib/bin/libtool --tag=CXX --mode=install (...args...) for creating end-user shared libraries and executables. Here are some example make targets used by MOOSE. I haven't included all the variables but hopefully you get the idea... $(app_LIB): @$(libmesh_LIBTOOL) --tag=CXX $(LIBTOOLFLAGS) --mode=link --quiet $(libmesh_CXX) $(libmesh_CXXFLAGS) -o $@ $(curr_objs) $(libmesh_LDFLAGS) $(EXTERNAL_FLAGS) -rpath $(curr_dir)/lib $(curr_libs) @$(libmesh_LIBTOOL) --mode=install --quiet install -c $@ $(curr_dir)/lib $(app_EXEC): @$(libmesh_LIBTOOL) --tag=CXX $(LIBTOOLFLAGS) --mode=link --quiet $(libmesh_CXX) $(libmesh_CXXFLAGS) -o $@ $(main_object) $(app_LIBS) $(libmesh_LIBS) $(libmesh_LDFLAGS) $(EXTERNAL_FLAGS) $(ADDITIONAL_LIBS) -- John ------------------------------------------------------------------------------ Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ _______________________________________________ Libmesh-users mailing list Libmesh-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libmesh-users