Compare commits
3 Commits
39eb82596b
...
e89751dd72
Author | SHA1 | Date | |
---|---|---|---|
e89751dd72 | |||
da27447a4a | |||
6166ab15db |
@ -24,6 +24,10 @@ else()
|
||||
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
|
||||
endif()
|
||||
|
||||
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
|
||||
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
|
||||
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
|
||||
|
||||
if(APPLE)
|
||||
set(CMAKE_MACOSX_RPATH OFF)
|
||||
set(CMAKE_INSTALL_NAME_DIR "@executable_path/../Library/nostalgia")
|
||||
@ -33,11 +37,14 @@ if(APPLE)
|
||||
set(NOSTALGIA_DIST_RESOURCES nostalgia-studio.app/Contents/Resources)
|
||||
set(NOSTALGIA_DIST_MAC_APP_CONTENTS nostalgia-studio.app/Contents)
|
||||
else()
|
||||
set(CMAKE_INSTALL_RPATH "$ORIGIN" "$ORIGIN/../lib/ox" "$ORIGIN/../lib/nostalgia" "$ORIGIN/../")
|
||||
if(UNIX)
|
||||
set(BUILD_SHARED_LIBS ON)
|
||||
endif()
|
||||
set(CMAKE_INSTALL_RPATH "$ORIGIN/../lib")
|
||||
set(CMAKE_BUILD_WITH_INSTALL_RPATH TRUE)
|
||||
set(NOSTALGIA_DIST_BIN bin)
|
||||
set(NOSTALGIA_DIST_LIB lib)
|
||||
set(NOSTALGIA_DIST_MODULE lib/nostalgia/modules)
|
||||
set(NOSTALGIA_DIST_MODULE lib)
|
||||
set(NOSTALGIA_DIST_RESOURCES share)
|
||||
endif()
|
||||
|
||||
|
8
Makefile
8
Makefile
@ -3,10 +3,10 @@ BUILDCORE_PATH=deps/buildcore
|
||||
include ${BUILDCORE_PATH}/base.mk
|
||||
|
||||
ifeq ($(OS),darwin)
|
||||
NOSTALGIA_STUDIO=./build/${HOST}/${CURRENT_BUILD}/src/nostalgia/studio/nostalgia-studio.app/Contents/MacOS/nostalgia-studio
|
||||
NOSTALGIA_STUDIO=./build/${CURRENT_BUILD}/src/nostalgia/studio/nostalgia-studio.app/Contents/MacOS/nostalgia-studio
|
||||
MGBA=/Applications/mGBA.app/Contents/MacOS/mGBA
|
||||
else
|
||||
NOSTALGIA_STUDIO=./build/${HOST}/${CURRENT_BUILD}/src/nostalgia/studio/nostalgia-studio
|
||||
NOSTALGIA_STUDIO=./build/${CURRENT_BUILD}/bin/nostalgia-studio
|
||||
MGBA=mgba-qt
|
||||
endif
|
||||
|
||||
@ -16,7 +16,7 @@ pkg-gba: install
|
||||
|
||||
.PHONY: run
|
||||
run: build
|
||||
./build/${HOST}/${CURRENT_BUILD}/src/nostalgia/player/nostalgia sample_project
|
||||
./build/${CURRENT_BUILD}/bin/nostalgia sample_project
|
||||
.PHONY: run-studio
|
||||
run-studio: build
|
||||
${NOSTALGIA_STUDIO}
|
||||
@ -25,7 +25,7 @@ gba-run: pkg-gba
|
||||
${MGBA} nostalgia.gba
|
||||
.PHONY: debug
|
||||
debug: build
|
||||
${DEBUGGER} ./build/${HOST}/${CURRENT_BUILD}/src/nostalgia/player/nostalgia sample_project
|
||||
${DEBUGGER} ./build/${CURRENT_BUILD}/bin/nostalgia sample_project
|
||||
.PHONY: debug-studio
|
||||
debug-studio: build
|
||||
${DEBUGGER} ${NOSTALGIA_STUDIO}
|
||||
|
8
deps/lodepng/CMakeLists.txt
vendored
8
deps/lodepng/CMakeLists.txt
vendored
@ -12,3 +12,11 @@ target_include_directories(
|
||||
lodepng PUBLIC SYSTEM
|
||||
include
|
||||
)
|
||||
|
||||
install(
|
||||
TARGETS
|
||||
lodepng
|
||||
DESTINATION
|
||||
LIBRARY DESTINATION lib
|
||||
ARCHIVE DESTINATION lib
|
||||
)
|
||||
|
8
deps/ox/src/ox/claw/test/CMakeLists.txt
vendored
8
deps/ox/src/ox/claw/test/CMakeLists.txt
vendored
@ -8,7 +8,7 @@ target_link_libraries(
|
||||
OxClaw
|
||||
)
|
||||
|
||||
add_test("[ox/claw] ClawTest ClawHeaderReader" ClawTest ClawHeaderReader)
|
||||
add_test("[ox/claw] ClawTest ClawHeaderReader2" ClawTest ClawHeaderReader2)
|
||||
add_test("[ox/claw] ClawTest ClawWriter" ClawTest ClawWriter)
|
||||
add_test("[ox/claw] ClawTest ClawReader" ClawTest ClawReader)
|
||||
add_test("[ox/claw] ClawHeaderReader" ${CMAKE_BINARY_DIR}/bin/ClawTest ClawHeaderReader)
|
||||
add_test("[ox/claw] ClawHeaderReader2" ${CMAKE_BINARY_DIR}/bin/ClawTest ClawHeaderReader2)
|
||||
add_test("[ox/claw] ClawWriter" ${CMAKE_BINARY_DIR}/bin/ClawTest ClawWriter)
|
||||
add_test("[ox/claw] ClawReader" ${CMAKE_BINARY_DIR}/bin/ClawTest ClawReader)
|
||||
|
2
deps/ox/src/ox/event/test/CMakeLists.txt
vendored
2
deps/ox/src/ox/event/test/CMakeLists.txt
vendored
@ -7,4 +7,4 @@ add_executable(
|
||||
|
||||
target_link_libraries(EventTest OxEvent)
|
||||
|
||||
add_test("[ox/event] Test 1" EventTest "test1")
|
||||
add_test("[ox/event] Test 1" ${CMAKE_BINARY_DIR}/bin/EventTest "test1")
|
||||
|
26
deps/ox/src/ox/fs/test/CMakeLists.txt
vendored
26
deps/ox/src/ox/fs/test/CMakeLists.txt
vendored
@ -10,20 +10,20 @@ target_link_libraries(
|
||||
OxMetalClaw
|
||||
)
|
||||
|
||||
add_test("[ox/fs] PtrArith::setSize" FSTests PtrArith::setSize)
|
||||
add_test("[ox/fs] PtrArith::setSize" ${CMAKE_BINARY_DIR}/bin/FSTests PtrArith::setSize)
|
||||
|
||||
add_test("[ox/fs] PathIterator::next1" FSTests PathIterator::next1)
|
||||
add_test("[ox/fs] PathIterator::next2" FSTests PathIterator::next2)
|
||||
add_test("[ox/fs] PathIterator::next3" FSTests PathIterator::next3)
|
||||
add_test("[ox/fs] PathIterator::next4" FSTests PathIterator::next4)
|
||||
add_test("[ox/fs] PathIterator::next5" FSTests PathIterator::next5)
|
||||
add_test("[ox/fs] PathIterator::hasNext" FSTests PathIterator::hasNext)
|
||||
add_test("[ox/fs] PathIterator::next1" ${CMAKE_BINARY_DIR}/bin/FSTests PathIterator::next1)
|
||||
add_test("[ox/fs] PathIterator::next2" ${CMAKE_BINARY_DIR}/bin/FSTests PathIterator::next2)
|
||||
add_test("[ox/fs] PathIterator::next3" ${CMAKE_BINARY_DIR}/bin/FSTests PathIterator::next3)
|
||||
add_test("[ox/fs] PathIterator::next4" ${CMAKE_BINARY_DIR}/bin/FSTests PathIterator::next4)
|
||||
add_test("[ox/fs] PathIterator::next5" ${CMAKE_BINARY_DIR}/bin/FSTests PathIterator::next5)
|
||||
add_test("[ox/fs] PathIterator::hasNext" ${CMAKE_BINARY_DIR}/bin/FSTests PathIterator::hasNext)
|
||||
|
||||
add_test("[ox/fs] PathIterator::dirPath" FSTests PathIterator::dirPath)
|
||||
add_test("[ox/fs] PathIterator::fileName" FSTests PathIterator::fileName)
|
||||
add_test("[ox/fs] PathIterator::dirPath" ${CMAKE_BINARY_DIR}/bin/FSTests PathIterator::dirPath)
|
||||
add_test("[ox/fs] PathIterator::fileName" ${CMAKE_BINARY_DIR}/bin/FSTests PathIterator::fileName)
|
||||
|
||||
add_test("[ox/fs] NodeBuffer::insert" FSTests "NodeBuffer::insert")
|
||||
add_test("[ox/fs] FileStore::readWrite" FSTests "FileStore::readWrite")
|
||||
add_test("[ox/fs] NodeBuffer::insert" ${CMAKE_BINARY_DIR}/bin/FSTests "NodeBuffer::insert")
|
||||
add_test("[ox/fs] FileStore::readWrite" ${CMAKE_BINARY_DIR}/bin/FSTests "FileStore::readWrite")
|
||||
|
||||
add_test("[ox/fs] Directory" FSTests "Directory")
|
||||
add_test("[ox/fs] FileSystem" FSTests "FileSystem")
|
||||
add_test("[ox/fs] Directory" ${CMAKE_BINARY_DIR}/bin/FSTests "Directory")
|
||||
add_test("[ox/fs] FileSystem" ${CMAKE_BINARY_DIR}/bin/FSTests "FileSystem")
|
||||
|
12
deps/ox/src/ox/mc/test/CMakeLists.txt
vendored
12
deps/ox/src/ox/mc/test/CMakeLists.txt
vendored
@ -8,9 +8,9 @@ target_link_libraries(
|
||||
OxMetalClaw
|
||||
)
|
||||
|
||||
add_test("[ox/mc] McTest Writer" McTest MetalClawWriter)
|
||||
add_test("[ox/mc] McTest Reader" McTest MetalClawReader)
|
||||
#add_test("[ox/mc] McTest MetalClawDef" McTest MetalClawDef)
|
||||
add_test("[ox/mc] McTest MetalClawModelValue" McTest MetalClawModelValue)
|
||||
add_test("[ox/mc] McTest encodeInteger" McTest encodeInteger)
|
||||
add_test("[ox/mc] McTest decodeInteger" McTest decodeInteger)
|
||||
add_test("[ox/mc] Writer" ${CMAKE_BINARY_DIR}/bin/McTest MetalClawWriter)
|
||||
add_test("[ox/mc] Reader" ${CMAKE_BINARY_DIR}/bin/McTest MetalClawReader)
|
||||
#add_test("[ox/mc] MetalClawDef" ${CMAKE_BINARY_DIR}/bin/McTest MetalClawDef)
|
||||
add_test("[ox/mc] MetalClawModelValue" ${CMAKE_BINARY_DIR}/bin/McTest MetalClawModelValue)
|
||||
add_test("[ox/mc] encodeInteger" ${CMAKE_BINARY_DIR}/bin/McTest encodeInteger)
|
||||
add_test("[ox/mc] decodeInteger" ${CMAKE_BINARY_DIR}/bin/McTest decodeInteger)
|
||||
|
6
deps/ox/src/ox/model/test/CMakeLists.txt
vendored
6
deps/ox/src/ox/model/test/CMakeLists.txt
vendored
@ -8,6 +8,6 @@ target_link_libraries(
|
||||
OxModel
|
||||
)
|
||||
|
||||
add_test("[ox/model] ModelTest ModelValue" ModelTest ModelValue)
|
||||
add_test("[ox/model] ModelTest getModelTypeName" ModelTest getModelTypeName)
|
||||
add_test("[ox/model] ModelTest getModelTypeVersion" ModelTest getModelTypeVersion)
|
||||
add_test("[ox/model] ModelValue" ${CMAKE_BINARY_DIR}/bin/ModelTest ModelValue)
|
||||
add_test("[ox/model] getModelTypeName" ${CMAKE_BINARY_DIR}/bin/ModelTest getModelTypeName)
|
||||
add_test("[ox/model] getModelTypeVersion" ${CMAKE_BINARY_DIR}/bin/ModelTest getModelTypeVersion)
|
||||
|
8
deps/ox/src/ox/oc/test/CMakeLists.txt
vendored
8
deps/ox/src/ox/oc/test/CMakeLists.txt
vendored
@ -8,7 +8,7 @@ target_link_libraries(
|
||||
OxOrganicClaw
|
||||
)
|
||||
|
||||
add_test("[ox/oc] OcTest Writer" OcTest OrganicClawWriter)
|
||||
add_test("[ox/oc] OcTest Reader" OcTest OrganicClawReader)
|
||||
add_test("[ox/oc] OcTest OrganicClawModelValue" OcTest OrganicClawModelValue)
|
||||
add_test("[ox/oc] OcTest OrganicClawDef" OcTest OrganicClawDef)
|
||||
add_test("[ox/oc] Writer" ${CMAKE_BINARY_DIR}/bin/OcTest OrganicClawWriter)
|
||||
add_test("[ox/oc] Reader" ${CMAKE_BINARY_DIR}/bin/OcTest OrganicClawReader)
|
||||
add_test("[ox/oc] OrganicClawModelValue" ${CMAKE_BINARY_DIR}/bin/OcTest OrganicClawModelValue)
|
||||
add_test("[ox/oc] OrganicClawDef" ${CMAKE_BINARY_DIR}/bin/OcTest OrganicClawDef)
|
||||
|
2
deps/ox/src/ox/preloader/CMakeLists.txt
vendored
2
deps/ox/src/ox/preloader/CMakeLists.txt
vendored
@ -1,6 +1,6 @@
|
||||
|
||||
add_library(
|
||||
OxPreloader STATIC
|
||||
OxPreloader
|
||||
preloader.cpp
|
||||
)
|
||||
|
||||
|
34
deps/ox/src/ox/std/test/CMakeLists.txt
vendored
34
deps/ox/src/ox/std/test/CMakeLists.txt
vendored
@ -7,20 +7,20 @@ add_executable(
|
||||
|
||||
target_link_libraries(StdTest OxStd)
|
||||
|
||||
add_test("[ox/std] ox_memcmp ABCDEFG != HIJKLMN" StdTest "ABCDEFG != HIJKLMN")
|
||||
add_test("[ox/std] ox_memcmp HIJKLMN != ABCDEFG" StdTest "HIJKLMN != ABCDEFG")
|
||||
add_test("[ox/std] ox_memcmp ABCDEFG == ABCDEFG" StdTest "ABCDEFG == ABCDEFG")
|
||||
add_test("[ox/std] ox_memcmp ABCDEFGHI == ABCDEFG" StdTest "ABCDEFGHI == ABCDEFG")
|
||||
add_test("[ox/std] itoa" StdTest "itoa")
|
||||
add_test("[ox/std] BString" StdTest "BString")
|
||||
add_test("[ox/std] String" StdTest "String")
|
||||
add_test("[ox/std] Vector" StdTest "Vector")
|
||||
add_test("[ox/std] HashMap" StdTest "HashMap")
|
||||
add_test("[ox/std] HeapMgr" StdTest malloc)
|
||||
add_test("[ox/std] Serialize-Int" StdTest "Serialize-Int")
|
||||
add_test("[ox/std] BufferWriter" StdTest "BufferWriter")
|
||||
add_test("[ox/std] StringSplit" StdTest "StringSplit")
|
||||
add_test("[ox/std] FromHex" StdTest "FromHex")
|
||||
add_test("[ox/std] ToHex" StdTest "ToHex")
|
||||
add_test("[ox/std] UUID" StdTest "UUID")
|
||||
add_test("[ox/std] UUID::generate" StdTest "UUID::generate")
|
||||
add_test("[ox/std] ox_memcmp ABCDEFG != HIJKLMN" ${CMAKE_BINARY_DIR}/bin/StdTest "ABCDEFG != HIJKLMN")
|
||||
add_test("[ox/std] ox_memcmp HIJKLMN != ABCDEFG" ${CMAKE_BINARY_DIR}/bin/StdTest "HIJKLMN != ABCDEFG")
|
||||
add_test("[ox/std] ox_memcmp ABCDEFG == ABCDEFG" ${CMAKE_BINARY_DIR}/bin/StdTest "ABCDEFG == ABCDEFG")
|
||||
add_test("[ox/std] ox_memcmp ABCDEFGHI == ABCDEFG" ${CMAKE_BINARY_DIR}/bin/StdTest "ABCDEFGHI == ABCDEFG")
|
||||
add_test("[ox/std] itoa" ${CMAKE_BINARY_DIR}/bin/StdTest "itoa")
|
||||
add_test("[ox/std] BString" ${CMAKE_BINARY_DIR}/bin/StdTest "BString")
|
||||
add_test("[ox/std] String" ${CMAKE_BINARY_DIR}/bin/StdTest "String")
|
||||
add_test("[ox/std] Vector" ${CMAKE_BINARY_DIR}/bin/StdTest "Vector")
|
||||
add_test("[ox/std] HashMap" ${CMAKE_BINARY_DIR}/bin/StdTest "HashMap")
|
||||
add_test("[ox/std] HeapMgr" ${CMAKE_BINARY_DIR}/bin/StdTest malloc)
|
||||
add_test("[ox/std] Serialize-Int" ${CMAKE_BINARY_DIR}/bin/StdTest "Serialize-Int")
|
||||
add_test("[ox/std] BufferWriter" ${CMAKE_BINARY_DIR}/bin/StdTest "BufferWriter")
|
||||
add_test("[ox/std] StringSplit" ${CMAKE_BINARY_DIR}/bin/StdTest "StringSplit")
|
||||
add_test("[ox/std] FromHex" ${CMAKE_BINARY_DIR}/bin/StdTest "FromHex")
|
||||
add_test("[ox/std] ToHex" ${CMAKE_BINARY_DIR}/bin/StdTest "ToHex")
|
||||
add_test("[ox/std] UUID" ${CMAKE_BINARY_DIR}/bin/StdTest "UUID")
|
||||
add_test("[ox/std] UUID::generate" ${CMAKE_BINARY_DIR}/bin/StdTest "UUID::generate")
|
||||
|
@ -8,4 +8,4 @@ target_link_libraries(
|
||||
Keel
|
||||
)
|
||||
|
||||
add_test("[keel] KeelTest writeUuidHeader" KeelTest writeUuidHeader)
|
||||
add_test("[keel] writeUuidHeader" ${CMAKE_BINARY_DIR}/bin/KeelTest writeUuidHeader)
|
||||
|
@ -8,7 +8,7 @@ add_subdirectory(scene)
|
||||
|
||||
# Keel
|
||||
add_library(
|
||||
NostalgiaKeelModules OBJECT
|
||||
NostalgiaKeelModules STATIC
|
||||
keelmodules.cpp
|
||||
)
|
||||
target_link_libraries(
|
||||
@ -27,7 +27,7 @@ install(
|
||||
# Studio
|
||||
if(TURBINE_BUILD_TYPE STREQUAL "Native")
|
||||
add_library(
|
||||
NostalgiaStudioModules
|
||||
NostalgiaStudioModules STATIC
|
||||
studiomodules.cpp
|
||||
)
|
||||
target_link_libraries(
|
||||
|
@ -8,7 +8,7 @@ add_library(
|
||||
)
|
||||
|
||||
add_library(
|
||||
NostalgiaCore-Studio-ImGui OBJECT
|
||||
NostalgiaCore-Studio-ImGui
|
||||
studiomodule.cpp
|
||||
paletteeditor-imgui.cpp
|
||||
tilesheeteditor-imgui.cpp
|
||||
|
@ -19,3 +19,11 @@ add_subdirectory(keel)
|
||||
if(NOSTALGIA_BUILD_STUDIO)
|
||||
add_subdirectory(studio)
|
||||
endif()
|
||||
|
||||
install(
|
||||
TARGETS
|
||||
NostalgiaScene
|
||||
DESTINATION
|
||||
LIBRARY DESTINATION lib
|
||||
ARCHIVE DESTINATION lib
|
||||
)
|
||||
|
@ -1,5 +1,5 @@
|
||||
add_library(
|
||||
NostalgiaScene-Studio OBJECT
|
||||
NostalgiaScene-Studio
|
||||
studiomodule.cpp
|
||||
sceneeditor-imgui.cpp
|
||||
sceneeditor.cpp
|
||||
|
Loading…
x
Reference in New Issue
Block a user