ZFFramework
 
Loading...
Searching...
No Matches
cmake

Requirement

you must have these settings being prepared:

  • cmake
  • proper make and compilers
  • nasm
  • OpenSSL
  • for Windows:
    • Desktop development with C++ via VisualStudioInstaller
    • ninja

once prepared, it's recommended to follow Quick setup for quick setup your project files

Manual Setup

if you really want to setup manually:

  1. build necessary libraries of ZFFramework, by one of these methods:
    • tools from ~/tools/release
    • manually build projects under ~/ZF
  2. create your own cmake project (CMakeLists.txt)
  3. have these lines in your CMakeLists.txt:
    add_compile_options("$<$<CONFIG:DEBUG>:-DDEBUG>")
  4. specify include path and lib search path in your CMakeLists.txt:
    include_directories(path_to_ZFFramework/_release/cmake/all/include)
    add_library(your_required_ZF_lib_name SHARED IMPORTED)
    set_target_properties(your_required_ZF_lib_name PROPERTIES IMPORTED_LOCATION path_to_ZFFramework/_release/cmake/all/lib/your_required_ZF_lib_name.dll)
  5. copy all res and libs to your product output or proper location according to your platform
    • for example
      ~/
      YourApp.exe
      ZFCore.dll
      zfauto zfres(const zfchar *resFilePath, const ZFPathInfo &pathInfo=(zft_zfnull))
      load resource by ZFObjectIOLoad
  6. create cpp files in your project and follow the Tutorial to code with ZFFramework, enjoy