Point CMake to using the subtree copy of Ox
This commit is contained in:
parent
56fb5595f9
commit
a243a38d4d
@ -30,4 +30,7 @@ endif()
|
||||
|
||||
enable_testing()
|
||||
|
||||
add_subdirectory(deps/ox)
|
||||
include_directories(deps/ox/src)
|
||||
|
||||
add_subdirectory(src)
|
||||
|
34
Dockerfile
34
Dockerfile
@ -4,37 +4,3 @@ ENV DEVKITPRO /opt/devkitPro
|
||||
ENV DEVKITARM ${DEVKITPRO}/devkitARM
|
||||
|
||||
RUN dnf install -y qt5-devel llvm libasan
|
||||
|
||||
###############################################################################
|
||||
# Install Ox
|
||||
|
||||
RUN git clone https://github.com/wombatant/ox.git /usr/local/src/ox && \
|
||||
cd /usr/local/src/ox && \
|
||||
git checkout -b install a5166e03bbaea2f200cfc730c69579c3d50ae2a7
|
||||
|
||||
# setup build dirs
|
||||
RUN mkdir -p \
|
||||
/usr/local/src/ox/build/release \
|
||||
/usr/local/src/ox/build/windows \
|
||||
/usr/local/src/ox/build/gba;
|
||||
|
||||
# install Ox for native environment
|
||||
RUN cd /usr/local/src/ox/build/release && \
|
||||
cmake -DCMAKE_EXPORT_COMPILE_COMMANDS=ON ../../ && \
|
||||
make -j install
|
||||
|
||||
# install Ox for GBA
|
||||
RUN cd /usr/local/src/ox/build/gba && \
|
||||
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_EXPORT_COMPILE_COMMANDS=ON \
|
||||
-DCMAKE_TOOLCHAIN_FILE=cmake/Modules/GBA.cmake \
|
||||
-DCMAKE_INSTALL_PREFIX=/opt/devkitPro/devkitARM \
|
||||
-DOX_USE_STDLIB=OFF ../../ && \
|
||||
make -j install
|
||||
|
||||
# install Ox for Windows
|
||||
RUN cd /usr/local/src/ox/build/windows && \
|
||||
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_EXPORT_COMPILE_COMMANDS=ON \
|
||||
-DCMAKE_TOOLCHAIN_FILE=cmake/Modules/Mingw.cmake \
|
||||
-DCMAKE_INSTALL_PREFIX=/usr/x86_64-w64-mingw32 \
|
||||
-DOX_BUILD_EXEC=OFF ../../ && \
|
||||
make -j install
|
||||
|
@ -10,7 +10,7 @@ BUILD_TYPE=$2
|
||||
if [[ $TARGET == windows ]]; then
|
||||
toolchain="-DCMAKE_TOOLCHAIN_FILE=cmake/Modules/Mingw.cmake"
|
||||
elif [[ $TARGET == gba ]]; then
|
||||
toolchain="-DCMAKE_TOOLCHAIN_FILE=cmake/Modules/GBA.cmake -DWOMBAT_BUILD_TYPE=GBA"
|
||||
toolchain="-DCMAKE_TOOLCHAIN_FILE=cmake/Modules/GBA.cmake -DWOMBAT_BUILD_TYPE=GBA -DOX_USE_STDLIB=OFF -DCMAKE_INSTALL_PREFIX=$DEVKITARM"
|
||||
fi
|
||||
|
||||
if [[ $BUILD_TYPE == debug ]]; then
|
||||
|
@ -6,10 +6,6 @@ if(NOT WOMBAT_BUILD_TYPE STREQUAL "GBA")
|
||||
find_package(Qt5Widgets)
|
||||
endif()
|
||||
|
||||
find_package(Ox REQUIRED)
|
||||
include_directories(${Ox_INCLUDE_DIRS})
|
||||
|
||||
|
||||
#project packages
|
||||
|
||||
include_directories(".")
|
||||
|
@ -21,7 +21,7 @@ typedef uint16_t Pallete[256];
|
||||
typedef Tile CharBlock[512];
|
||||
typedef Tile8 CharBlock8[256];
|
||||
|
||||
struct __attribute__((aligned(4))) GbaImageData {
|
||||
struct __attribute__((packed)) GbaImageData {
|
||||
Pallete pal;
|
||||
uint16_t tileCount;
|
||||
uint8_t bpp;
|
||||
|
@ -21,6 +21,6 @@ endif()
|
||||
target_link_libraries(
|
||||
nostalgia
|
||||
NostalgiaCore
|
||||
${OxStd_LIBRARY}
|
||||
${OxFS_LIBRARY}
|
||||
OxStd
|
||||
OxFS
|
||||
)
|
||||
|
@ -15,9 +15,9 @@ target_link_libraries(
|
||||
nostalgia-studio
|
||||
Qt5::Core
|
||||
Qt5::Widgets
|
||||
${OxClArgs_LIBRARY}
|
||||
${OxFS_LIBRARY}
|
||||
${OxStd_LIBRARY}
|
||||
OxClArgs
|
||||
OxFS
|
||||
OxStd
|
||||
NostalgiaCommon
|
||||
NostalgiaCore
|
||||
NostalgiaStudioStatic
|
||||
|
@ -22,8 +22,8 @@ target_link_libraries(
|
||||
NostalgiaStudioStatic
|
||||
Qt5::Core
|
||||
Qt5::Widgets
|
||||
${OxFS_LIBRARY}
|
||||
${OxStd_LIBRARY}
|
||||
OxFS
|
||||
OxStd
|
||||
)
|
||||
|
||||
add_library(
|
||||
@ -36,8 +36,8 @@ target_link_libraries(
|
||||
Qt5::Core
|
||||
Qt5::Widgets
|
||||
NostalgiaStudioStatic
|
||||
${OxFS_LIBRARY}
|
||||
${OxStd_LIBRARY}
|
||||
OxFS
|
||||
OxStd
|
||||
)
|
||||
|
||||
install(
|
||||
|
@ -10,9 +10,9 @@ add_executable(nost-pack pack.cpp)
|
||||
target_link_libraries(
|
||||
nost-pack
|
||||
Qt5::Widgets
|
||||
${OxClArgs_LIBRARY}
|
||||
${OxFS_LIBRARY}
|
||||
${OxStd_LIBRARY}
|
||||
OxClArgs
|
||||
OxFS
|
||||
OxStd
|
||||
NostalgiaCommon
|
||||
NostalgiaCore
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user