Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to use tmxlite on Windows and CLion #137

Closed
SenhorLime opened this issue Jul 29, 2023 · 3 comments
Closed

How to use tmxlite on Windows and CLion #137

SenhorLime opened this issue Jul 29, 2023 · 3 comments

Comments

@SenhorLime
Copy link

I'm new at using libraries and I didn't understand how to use the tmxlite. I tried to link the library in my IDE with many different ways, but none of them worked, and I didn't find any tutorial or issue that solved my problem.

@fallahn
Copy link
Owner

fallahn commented Jul 30, 2023

I've never used CLion but according to this post it uses CMake files directly. In which case you can use the included example CMake files as a basis for adding tmxlite to your project:

https://github.com/fallahn/tmxlite/blob/master/SFMLExample/CMakeLists.txt#L25 for SFML projects or
https://github.com/fallahn/tmxlite/blob/master/OpenGLExample/CMakeLists.txt#L24 for SDL2 projects

@SenhorLime
Copy link
Author

I cloned the repository and tried to open the SFML Example in CLion, but it returned the following error:

CMake Error at C:/Program Files/JetBrains/CLion 2023.2/bin/cmake/win/x64/share/cmake-3.26/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
  Could NOT find tmxlite (missing: TMXLITE_LIBRARIES)
Call Stack (most recent call first):
  C:/Program Files/JetBrains/CLion 2023.2/bin/cmake/win/x64/share/cmake-3.26/Modules/FindPackageHandleStandardArgs.cmake:600 (_FPHSA_FAILURE_MESSAGE)
  cmake/modules/FindTMXLITE.cmake:10 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  CMakeLists.txt:26 (find_package)

@fallahn
Copy link
Owner

fallahn commented Jul 30, 2023

You need to build the tmxlite library first and install it somewhere that CMake can find it. You can do this with the CMake file in the tmxlite directory.

Repository owner locked and limited conversation to collaborators Sep 13, 2023
@fallahn fallahn converted this issue into discussion #142 Sep 13, 2023

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Projects
None yet
Development

No branches or pull requests

2 participants