@@ -2,7 +2,22 @@ if(NOT ENABLE_PLAYLIST)
22 return ()
33endif ()
44
5+ set (PROJECTM_PLAYLIST_EXPORT_HEADER "${CMAKE_CURRENT_BINARY_DIR} /include/projectM-4/projectM_playlist_export.h" )
6+
7+ set (PROJECTM_PLAYLIST_PUBLIC_HEADERS
8+ "${PROJECTM_PLAYLIST_EXPORT_HEADER} "
9+ api/projectM-4/playlist.h
10+ api/projectM-4/playlist_callbacks.h
11+ api/projectM-4/playlist_core.h
12+ api/projectM-4/playlist_filter.h
13+ api/projectM-4/playlist_items.h
14+ api/projectM-4/playlist_memory.h
15+ api/projectM-4/playlist_playback.h
16+ api/projectM-4/playlist_types.h
17+ )
18+
519add_library (projectM_playlist_main OBJECT
20+ ${PROJECTM_PLAYLIST_PUBLIC_HEADERS}
621 Filter .cpp
722 Filter .hpp
823 Item.cpp
@@ -11,14 +26,6 @@ add_library(projectM_playlist_main OBJECT
1126 Playlist.hpp
1227 PlaylistCWrapper.cpp
1328 PlaylistCWrapper.hpp
14- api/projectM-4/playlist.h
15- api/projectM-4/playlist_callbacks.h
16- api/projectM-4/playlist_core.h
17- api/projectM-4/playlist_filter.h
18- api/projectM-4/playlist_items.h
19- api/projectM-4/playlist_memory.h
20- api/projectM-4/playlist_playback.h
21- api/projectM-4/playlist_types.h
2229 )
2330
2431target_include_directories (projectM_playlist_main
@@ -45,6 +52,7 @@ set_target_properties(projectM_playlist PROPERTIES
4552 EXPORT_NAME playlist
4653 FOLDER libprojectM
4754 OUTPUT_NAME ${PROJECTM_LIBRARY_BASE_OUTPUT_NAME} -playlist
55+ PUBLIC_HEADER "${PROJECTM_PLAYLIST_PUBLIC_HEADERS} "
4856 )
4957
5058target_include_directories (projectM_playlist
@@ -88,8 +96,6 @@ endif()
8896
8997include (GenerateExportHeader)
9098
91- set (PROJECTM_PLAYLIST_EXPORT_HEADER "${CMAKE_CURRENT_BINARY_DIR} /include/projectM-4/projectM_playlist_export.h" )
92-
9399generate_export_header(projectM_playlist
94100 BASE_NAME projectM_playlist
95101 EXPORT_FILE_NAME "${PROJECTM_PLAYLIST_EXPORT_HEADER} "
@@ -107,17 +113,6 @@ if(ENABLE_INSTALL)
107113 PUBLIC_HEADER DESTINATION "${PROJECTM_INCLUDE_DIR} /projectM-4" COMPONENT Devel
108114 )
109115
110- install (FILES
111- "${CMAKE_CURRENT_BINARY_DIR} /include/projectM-4/projectM_playlist_export.h"
112- DESTINATION "${PROJECTM_INCLUDE_DIR} /projectM-4"
113- COMPONENT Devel
114- )
115-
116- install (DIRECTORY api/projectM-4
117- DESTINATION "${PROJECTM_INCLUDE_DIR} "
118- COMPONENT Devel
119- )
120-
121116
122117 # For use from an installed package (system install, vcpkg, homebrew etc.)
123118 include (CMakePackageConfigHelpers)
0 commit comments