On 02/27/2014 10:33 AM, Ed Maste wrote:
> It's not FreeBSD-specific; here it is in the GNU ld manual:
> https://sourceware.org/binutils/docs/ld/Options.html#Options
> 
> -z keyword
> `origin'  Marks the object may contain $ORIGIN.
> 
> and it turns up in some Solaris references from the early 2000s as well.

Also w.r.t. the patch:

> +  if( ${CMAKE_SYSTEM_NAME} MATCHES FreeBSD )
> +    set(CMAKE_EXE_LINKER_FLAGS "-Wl,-zorigin")
> +  endif()

CMAKE_EXE_LINKER_FLAGS is a user-settable value in the local cache
so instead of setting it outright you should prepend or append:

  set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-zorigin")

-Brad

_______________________________________________
lldb-dev mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/lldb-dev

Reply via email to