Opennurbs Compiling Issues

Hi,

I can compile opennurbs latest version and my src code as well, but at the end when it tries to link opennurbs to my src code I get following error:
error ON_COMPILING_OPENNURBS must be defined when compiling opennurbs
22 | error ON_COMPILING_OPENNURBS must be defined when compiling opennurbs

I added definition to my Cmake file in opennurbs directory but nothing changed.

add_definitions(-DON_COMPILING_OPENNURBS)

target_compile_definitions(opennurbsStatic PRIVATE ON_COMPILING_OPENNURBS Z_PREFIX MY_ZCALLOC ON_COMPILING_OPENNURBS)

target_compile_definitions(OpenNURBS PRIVATE OPENNURBS_EXPORTS Z_PREFIX MY_ZCALLOC ON_COMPILING_OPENNURBS)

Any idea?Thanks

Can you share your CMake file(s)? That will help in trying to reproduce the problem you are experiencing.