certi-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [certi-dev] Problem building CERTI on Mac OS X


From: Eric Noulard
Subject: Re: [certi-dev] Problem building CERTI on Mac OS X
Date: Wed, 27 Apr 2011 09:15:47 +0200

2011/4/27 Mark Brown <address@hidden>:
> Thanks for investigating Eric.
>
> I tried the "-undefined suppress" and the linker complains:
>>
>> ld: can't use -undefined warning or suppress with -twolevel_namespace
>
> I then tried with the "-flat_namespace -undefined suppress" flags. That
> seems to fix the original problem (insofar that it now links, at least)!
>
> However, it then fails linking the test program:
>
> Scanning dependencies of target CertiProcessus_A
> [ 98%] Building CXX object
> test/utility/CMakeFiles/CertiProcessus_A.dir/Main_SocketSHM.o
> Linking CXX executable CertiProcessus_A
> ld: library not found for -lrt
> collect2: ld returned 1 exit status
> make[2]: *** [test/utility/CertiProcessus_A] Error 1
> make[1]: *** [test/utility/CMakeFiles/CertiProcessus_A.dir/all] Error 2
> make: *** [all] Error 2

Yes ok, lib "rt" is not available on MacOS.
You could try to edit the certi/test/utility/CMakeLists.txt and replace

IF(WIN32)
    TARGET_LINK_LIBRARIES(CertiProcessus_B CERTI HLA)
ELSE(WIN32)
    TARGET_LINK_LIBRARIES(CertiProcessus_B CERTI HLA rt)
ENDIF(WIN32)

with something like

TARGET_LINK_LIBRARIES(CertiProcessus_B CERTI HLA)

IF (NOT APPLE)
    TARGET_LINK_LIBRARIES(CertiProcessus_B rt)
ENDIF(NOT APPLE)

If it works I'll try a better fix using something like

find_library(RT_LIBRARY rt) etc...

-- 
Erk
Membre de l'April - « promouvoir et défendre le logiciel libre » -
http://www.april.org



reply via email to

[Prev in Thread] Current Thread [Next in Thread]