Skip to content
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

add CMakeLists.txt for editors such as CLion #121

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

alextwothousand
Copy link

I added a CMakeLists for editors such as CLion, or for those who may use vscode / sublime text.

To enable SA/VC/3, just use

option(GTA_SAN_ANDREAS ON)
# and/or
option(GTA_VICE_CITY ON)
# and/or
option(GTA_III ON)

in your project parent path's CMakeLists.txt, before your add_subdirectory line.

@alextwothousand
Copy link
Author

no merge?

@imring
Copy link
Contributor

imring commented Jul 27, 2021

as for me, the project file isn't ready yet:

  • no way to build examples with cmake;
  • not all macros are written (e.g. for sa):
target_compile_definitions(plugin_sdk PUBLIC
  _CRT_SECURE_NO_WARNINGS
  _DX9_SDK_INSTALLED
  _CRT_NON_CONFORMING_SWPRINTFS

  GTASA
  GTAGAME_NAME="San Andreas"
  GTAGAME_ABBR="SA"
  GTAGAME_ABBRLOW="sa"
  GTAGAME_PROTAGONISTNAME="CJ"
  GTAGAME_CITYNAME="San Andreas"
  PLUGIN_SGV_10US
)

all macros can be found in premake.lua

i would also like:

  • install library (cmake --build . --target install ...);
  • use namespace (e.g. target_link_libraries(project PRIVATE pluginsdk::sa)).

@alextwothousand
Copy link
Author

as for me, the project file isn't ready yet:

* no way to build examples with cmake;

* not all macros are written (e.g. for sa):
target_compile_definitions(plugin_sdk PUBLIC
  _CRT_SECURE_NO_WARNINGS
  _DX9_SDK_INSTALLED
  _CRT_NON_CONFORMING_SWPRINTFS

  GTASA
  GTAGAME_NAME="San Andreas"
  GTAGAME_ABBR="SA"
  GTAGAME_ABBRLOW="sa"
  GTAGAME_PROTAGONISTNAME="CJ"
  GTAGAME_CITYNAME="San Andreas"
  PLUGIN_SGV_10US
)

all macros can be found in premake.lua

i would also like:

* install library (`cmake --build . --target install ...`);

* use namespace (e.g. `target_link_libraries(project PRIVATE pluginsdk::sa)`).

Will look into it at some point.

@Izzotop
Copy link

Izzotop commented Jun 14, 2022

@imring
Copy link
Contributor

imring commented Jun 14, 2022

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants