NanoComp / libctl

Guile-based library implementing flexible control files for scientific simulations
GNU General Public License v2.0
18 stars 22 forks source link

Meep doesn't build #16

Closed martinkielhorneffect closed 6 years ago

martinkielhorneffect commented 6 years ago

When trying to build meep I get this error: bend-flux-ll.o: In function create_structure_by_hand(bool, bool, meep::volume&, meep::volume&, meep::volume&)': bend-flux-ll.cpp:(.text+0x120a): undefined reference tomake_prism' bend-flux-ll.cpp:(.text+0x136d): undefined reference to `make_prism'

I tracked this down to this change: https://github.com/stevengj/libctl/pull/13

I fixed this by downcasing two types in line 2423 in utils/geom.c: geometric_object make_prism(material_type material,

stevengj commented 6 years ago

You need to have the latest version of libctl to build the latest Meep.

Not sure what you mean by "downcasing".

martinkielhorneffect commented 6 years ago

By downcasing I mean that I convert this line: GEOMETRIC_OBJECT make_prism(MATERIAL_TYPE material, into that line: geometric_object make_prism(material_type material, in https://github.com/stevengj/libctl/blob/master/utils/geom.c

stevengj commented 6 years ago

GEOMETRIC_OBJECT is already #defined to geometric_object in ctlgeom.h, so I'm not sure what is going on here...

stevengj commented 6 years ago

Oh, I think maybe the problem is that geom.c does #include <ctlgeom.h> instead of #include "ctlgeom.h", and maybe it is using an old version of ctlgeom.h on your machine instead of the one in the same directory?

stevengj commented 6 years ago

That being said, there is no reason to use the uppercase versions in this file, so I will change that too.