<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Fri, Feb 9, 2018 at 12:52 AM, AmigaBlitter <span dir="ltr"><<a href="mailto:amiblit@gmail.com" target="_blank">amiblit@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
Hello everyone,<br>
<br>
i'm new to this forum.<br>
<br>
I'm trying to port Commander-Genius<br>
(<a href="https://github.com/gerstrong/Commander-Genius" rel="noreferrer" target="_blank">https://github.com/gerstrong/<wbr>Commander-Genius</a>) to an exotic platform -<br>
AmigaOS 4.1 PPC.<br>
<br>
I created a toolchain file to specify what compiler i'm using as follow:<br>
<br>
ToolChain files<br>
# this one is important<br>
SET(CMAKE_SYSTEM_NAME AmigaOS)<br>
#this one not so much<br>
SET(CMAKE_SYSTEM_VERSION 1)<br>
<br>
# specify the cross compiler<br>
SET(CMAKE_C_COMPILER<br>
/usr/local/amiga/adtools-ppc-<wbr>uwin64-20170623-404/bin/ppc-<wbr>amigaos-gcc)<br>
SET(CMAKE_CXX_COMPILER<br>
/usr/local/amiga/adtools-ppc-<wbr>uwin64-20170623-404/bin/ppc-<wbr>amigaos-g++)<br>
<br>
# where is the target environment<br>
SET(CMAKE_FIND_ROOT_PATH  /usr/local/amiga/adtools-ppc-<wbr>uwin64-20170623-404)<br></blockquote><div><br></div><div>Try setting CMAKE_SYSROOT instead of <span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">CMAKE_FIND_ROOT_PATH.  The find_*() functions check CMAKE_SYSROOT first if set, and cmake will also pass "--sysroot=${CMAKE_SYSROOT}" for you.  With clang, I also set CMAKE_<lang>_COMPILER_TARGET for each language I need, e.g., C, CXX, and ASM, but that's probably not necessary with gcc.</span><br></div><div><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><br></span></div><div><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">hth...</span></div><div><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">don</span></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
# search for programs in the build host directories<br>
SET(CMAKE_FIND_ROOT_PATH_MODE_<wbr>PROGRAM NEVER)<br>
# for libraries and headers in the target directories<br>
SET(CMAKE_FIND_ROOT_PATH_MODE_<wbr>LIBRARY ONLY)<br>
SET(CMAKE_FIND_ROOT_PATH_MODE_<wbr>INCLUDE ONLY)<br>
<br>
Issuing cmake -DCMAKE_TOOLCHAIN_FILE=./<wbr>Toolchain-ppc-amigaos.cmake<br>
-DUSE_SDL2=yes<br>
<br>
Compilations starts, but at the end i get some messages as follow:<br>
usr/bin/ld: /SDK/local/newlib/lib/libSDL2.<wbr>so: Relocations in generic ELF<br>
(EM: 20)<br>
<br>
Could someone give me an hint?<br>
<br>
Kind regards<br>
<br>
<br>
<br>
<br>
--<br>
Sent from: <a href="http://cmake.3232098.n2.nabble.com/" rel="noreferrer" target="_blank">http://cmake.3232098.n2.<wbr>nabble.com/</a><br>
--<br>
<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Please keep messages on-topic and check the CMake FAQ at: <a href="http://www.cmake.org/Wiki/CMake_FAQ" rel="noreferrer" target="_blank">http://www.cmake.org/Wiki/<wbr>CMake_FAQ</a><br>
<br>
Kitware offers various services to support the CMake community. For more information on each offering, please visit:<br>
<br>
CMake Support: <a href="http://cmake.org/cmake/help/support.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/<wbr>support.html</a><br>
CMake Consulting: <a href="http://cmake.org/cmake/help/consulting.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/<wbr>consulting.html</a><br>
CMake Training Courses: <a href="http://cmake.org/cmake/help/training.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/<wbr>training.html</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/<wbr>opensource/opensource.html</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="https://cmake.org/mailman/listinfo/cmake" rel="noreferrer" target="_blank">https://cmake.org/mailman/<wbr>listinfo/cmake</a><br>
</blockquote></div><br></div></div>