Skip to content

Commit

Permalink
build sample with cmake on Linux
Browse files Browse the repository at this point in the history
  • Loading branch information
seoyoungjin authored and madebr committed Jun 22, 2021
1 parent 6f5e6fe commit 36f9529
Show file tree
Hide file tree
Showing 9 changed files with 75 additions and 0 deletions.
9 changes: 9 additions & 0 deletions README.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
Build with cmake
================

Linux

mkdir build
cd build
cmake .. -DLIBRW_PLATFORM=GL3 -DLIBRW_GL3_GFXLIB=SDL2
make
10 changes: 10 additions & 0 deletions tools/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,13 @@ endif()
if(LIBRW_PLATFORM_PS2)
add_subdirectory(ps2test)
endif()

if(NOT LIBRW_PLATFORM_PS2)
add_subdirectory(playground)
add_subdirectory(lights)
add_subdirectory(subrast)
add_subdirectory(camera)
add_subdirectory(im2d)
add_subdirectory(im3d)
add_subdirectory(ska2anm)
endif()
8 changes: 8 additions & 0 deletions tools/camera/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
add_executable(camera
main.cpp camexamp.cpp viewer.cpp
)

target_link_libraries(camera
PUBLIC
librw librw_skeleton librw_skeleton_imgui
)
8 changes: 8 additions & 0 deletions tools/im2d/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
add_executable(im2d
im2d.cpp linelist.cpp main.cpp polyline.cpp trifan.cpp trilist.cpp tristrip.cpp
)

target_link_libraries(im2d
PUBLIC
librw librw_skeleton librw_skeleton_imgui
)
8 changes: 8 additions & 0 deletions tools/im3d/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
add_executable(im3d
im3d.cpp linelist.cpp main.cpp polyline.cpp trifan.cpp trilist.cpp tristrip.cpp
)

target_link_libraries(im3d
PUBLIC
librw librw_skeleton librw_skeleton_imgui
)
8 changes: 8 additions & 0 deletions tools/lights/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
add_executable(lights
main.cpp lights.cpp
)

target_link_libraries(lights
PUBLIC
librw librw_skeleton librw_skeleton_imgui
)
8 changes: 8 additions & 0 deletions tools/playground/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
add_executable(playgound
camera.cpp font.cpp main.cpp ras_test.cpp splines.cpp tl_tests.cpp
)

target_link_libraries(playgound
PUBLIC
librw librw_skeleton
)
8 changes: 8 additions & 0 deletions tools/ska2anm/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
add_executable(ska2anm
ska2anm.cpp
)

target_link_libraries(ska2anm
PUBLIC
librw
)
8 changes: 8 additions & 0 deletions tools/subrast/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
add_executable(subrast
main.cpp subrast.cpp
)

target_link_libraries(subrast
PUBLIC
librw librw_skeleton librw_skeleton_imgui
)

0 comments on commit 36f9529

Please sign in to comment.