Opeenurbs compile with GCC/12.3

Hello,

I am trying to compile the OpenNurbs for C++ using GCC/12.3 but it fails at some point with the following error:
rm libopenNURBS.a
rm: cannot remove ‘libopenNURBS.a’: No such file or directory
make[2]: [Makefile:485: libopenNURBS.a] Error 1 (ignored)
ar qvl libopenNURBS.a opennurbs_3dm_attributes.o opennurbs_3dm_properties.o opennurbs_3dm_settings.o opennurbs_annotation.o opennurbs_annotation2.o opennurbs_arc.o opennurbs_arccurve.o opennurbs_archive.o opennurbs_array.o opennurbs_base32.o opennurbs_base64.o opennurbs_beam.o opennurbs_bezier.o opennurbs_beziervolume.o opennurbs_bitmap.o opennurbs_bounding_box.o opennurbs_box.o opennurbs_brep.o opennurbs_brep_extrude.o opennurbs_brep_io.o opennurbs_brep_isvalid.o opennurbs_brep_region.o opennurbs_brep_tools.o opennurbs_brep_v2valid.o opennurbs_circle.o opennurbs_color.o opennurbs_compress.o opennurbs_cone.o opennurbs_crc.o opennurbs_curve.o opennurbs_curveonsurface.o opennurbs_curveproxy.o opennurbs_cylinder.o opennurbs_defines.o opennurbs_detail.o opennurbs_dimstyle.o opennurbs_ellipse.o opennurbs_embedded_file.o opennurbs_error.o opennurbs_error_message.o opennurbs_evaluate_nurbs.o opennurbs_extensions.o opennurbs_font.o opennurbs_fsp.o opennurbs_geometry.o opennurbs_group.o opennurbs_hatch.o opennurbs_instance.o opennurbs_intersect.o opennurbs_knot.o opennurbs_layer.o opennurbs_light.o opennurbs_line.o opennurbs_linecurve.o opennurbs_linetype.o opennurbs_lookup.o opennurbs_material.o opennurbs_math.o opennurbs_matrix.o opennurbs_memory.o opennurbs_memory_util.o opennurbs_mesh.o opennurbs_mesh_ngon.o opennurbs_mesh_tools.o opennurbs_morph.o opennurbs_nurbscurve.o opennurbs_nurbssurface.o opennurbs_nurbsvolume.o opennurbs_object.o opennurbs_object_history.o opennurbs_objref.o opennurbs_offsetsurface.o opennurbs_optimize.o opennurbs_plane.o opennurbs_planesurface.o opennurbs_pluginlist.o opennurbs_point.o opennurbs_pointcloud.o opennurbs_pointgeometry.o opennurbs_pointgrid.o opennurbs_polycurve.o opennurbs_polyedgecurve.o opennurbs_polyline.o opennurbs_polylinecurve.o opennurbs_rand.o opennurbs_revsurface.o opennurbs_rtree.o opennurbs_sort.o opennurbs_sphere.o opennurbs_string.o opennurbs_sum.o opennurbs_sumsurface.o opennurbs_surface.o opennurbs_surfaceproxy.o opennurbs_textlog.o opennurbs_torus.o opennurbs_unicode.o opennurbs_userdata.o opennurbs_uuid.o opennurbs_viewport.o opennurbs_workspace.o opennurbs_wstring.o opennurbs_xform.o opennurbs_zlib.o opennurbs_zlib_memory.o zlib/adler32.o zlib/compress.o zlib/crc32.o zlib/deflate.o zlib/infback.o zlib/inffast.o zlib/inflate.o zlib/inftrees.o zlib/trees.o zlib/uncompr.o zlib/zutil.o zlib/zlib.o
ar: opennurbs_3dm_attributes.o: file format not recognized
make[2]: *** [Makefile:486: libopenNURBS.a] Error 1
make[2]: Leaving directory ‘/scratch/babazado/StarPU/SRC/opennurbs’
make[1]: *** [Makefile:5: all] Error 2
make[1]: Leaving directory ‘/scratch/babazado/StarPU/SRC’
make: *** [Makefile:201: all] Error 2

Can anyone help me out? Thanks

Are you using CMake to compile? Also, are you compiling with gcc on Mac?

No, I am using Makefile on Linux. I can compile with gcc/9.3 but getting this error with gcc/12.3

Ok; this post somehow was tagged as Mac. I would recommend using cmake on Linux if possible. That is what we have been using lately for internal compiles on Linux. I will need to check the makefile to see if it is up to date.

Thanks for the reply @stevebaer . I can’t use CMake right now. I have to use Makefile to compile the code.