Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: cmake dependecies link  (Read 3080 times)

0 Members and 1 Guest are viewing this topic.

ILikeSfml

  • Newbie
  • *
  • Posts: 2
    • View Profile
cmake dependecies link
« on: July 06, 2021, 12:28:46 pm »
Hello I got as here https://en.sfml-dev.org/forums/index.php?topic=27663.0 but I dont know totally anything about cmake and I just cant link as described in that topic. This is this

Code: [Select]
set(CMAKE_INCLUDE_PATH ${CMAKE_INCLUDE_PATH} "SFML-2.5.1\\extlibs\\headers")   
set(CMAKE_LIBRARY_PATH ${CMAKE_LIBRARY_PATH} "SFML-2.5.1\\extlibs\\libs-msvc\\x86")   

Can sb tell me how to add this to cmake call?

Code: [Select]
   cmake -DCMAKE_SYSTEM_NAME=Android -DCMAKE_ANDROID_NDK=I_know_here_is_my_path -DCMAKE_ANDROID_ARCH_ABI=armeabi-v7a -DCMAKE_ANDROID_STL_TYPE=c++_static -DCMAKE_BUILD_TYPE=Debug ../..

which is from here https://github.com/SFML/SFML/wiki/Tutorial:-Building-SFML-for-Android

Thanks in advance  :)

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11030
    • View Profile
    • development blog
    • Email
Re: cmake dependecies link
« Reply #1 on: July 06, 2021, 03:53:28 pm »
See the basic example in the following thread: https://en.sfml-dev.org/forums/index.php?topic=24070.0

If you don't know anything about CMake, then it's time to learn some ;)
- Official CMake
- It's Time To Do CMake Right
- Better CMake
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

ILikeSfml

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: cmake dependecies link
« Reply #2 on: July 07, 2021, 10:33:43 am »
Thanks for nice sources! But could you help me with this?
Exact error I get is:
Code: [Select]
CMake Error at D:/path_to_cmake/cmake-3.21.0-rc2-windows-x86_64/share/cmake-3.21/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
  Could NOT find OpenAL (missing: OPENAL_LIBRARY OPENAL_INCLUDE_DIR)

But when I call cmake without parameters, cmake (so I just call "-cmake ../..") builds fine but it isnt usable, what's strange is that it sees openal and other dependiences. I looked for linking libraries and includes in cmake's documentation but it doesnt do anything at all. Cmake seems to ignore it  :(
Could you help what should I write and where (in cmd or in cmakelists.txt)?
« Last Edit: July 07, 2021, 10:36:51 am by ILikeSfml »

 

anything