Michael Jackson wrote:
> Linux really wants to have -fPIC for some of my code and I am trying to
> detect linux and then add this flag for my project but I am having no
> luck.
>
> if (LINUX)
> set(CMAKE_CXX_FLAGS ${CMAKE_CSS_FLAGS} "-fPIC")
> endif()
>
> Is this NOT the way I should be doing th
Hi Michael,
To apply the flag on a specific target, consider looking at:
https://github.com/commontk/Log4Qt/blob/patched/CMakeLists.txt#L116
Hth
Jc
On Mon, Jun 18, 2012 at 8:23 PM, Michael Jackson <
mike.jack...@bluequartz.net> wrote:
> Thanks everyone for the help. I really have a typo in my C
Thanks everyone for the help. I really have a typo in my CMake code so thanks
for every one for finding that. Basically we build a few libraries which other
parts of our code depend on. One particular library has to be a shared library
but links statically to the other libraries in order to avoi
On 18/06/2012 23:09, Michael Jackson wrote:
Linux really wants to have -fPIC for some of my code and I am trying to detect
linux and then add this flag for my project but I am having no luck.
if (LINUX)
set(CMAKE_CXX_FLAGS ${CMAKE_CSS_FLAGS} "-fPIC")
endif()
Is this NOT the way I shoul
Starting to dislike the gmail program.
So here's a corrected message , to the list this time:
===
This is how I've been doing for years. Doesn't mean it's the right way :)
Here -O3 and -DLINUX don't apply to your case, and ${SRC_FILES} has been
assigned wi
I'm not a Linux guy, so hopefully someone else more knowledgeable
can chime in here, but if you want to add to your CMAKE_CXX_FLAGS,
you need to avoid creating a semi-colon-separated list by moving the
quote mark:
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC")
Linux really wants to have -fPIC for some of my code and I am trying to detect
linux and then add this flag for my project but I am having no luck.
if (LINUX)
set(CMAKE_CXX_FLAGS ${CMAKE_CSS_FLAGS} "-fPIC")
endif()
Is this NOT the way I should be doing this? It doesn't really "fell" corr