pspdev / psp-packages

https://pspdev.github.io/psp-packages/
The Unlicense
19 stars 13 forks source link

add yaml-cpp #111

Closed humbertodias closed 4 months ago

humbertodias commented 4 months ago

Would be possible to add the library yaml-cpp? https://github.com/jbeder/yaml-cpp.git

Thanks

sharkwouter commented 4 months ago

It would be and it wouldn't be too hard. yaml-cpp needs a small change to get it to build:

--- CMakeLists.txt  2024-02-21 09:55:58.709903787 +0100
+++ yaml-cpp-0.8.0/CMakeLists.txt   2023-08-10 21:27:56.000000000 +0200
@@ -84,7 +84,7 @@
   PROPERTY
     CXX_STANDARD_REQUIRED ON)

-if (NOT YAML_BUILD_SHARED_LIBS AND NOT PSP)
+if (NOT YAML_BUILD_SHARED_LIBS)
   set_property(TARGET yaml-cpp PROPERTY POSITION_INDEPENDENT_CODE ON)
 endif()

With that it builds just fine using psp-cmake.

You can find some documentation on how to make packages here: https://github.com/pspdev/psp-packages/blob/master/CONTRIBUTING.md

Feel free to make a PR, otherwise I can see if I can get to this somewhere next week.

humbertodias commented 4 months ago

Thanks. I have submitted a fix https://github.com/jbeder/yaml-cpp/pull/1271