Base refactor
This commit is contained in:
28
src/dawnlinux/CMakeLists.txt
Normal file
28
src/dawnlinux/CMakeLists.txt
Normal file
@ -0,0 +1,28 @@
|
||||
# Copyright (c) 2023 Dominic Masters
|
||||
#
|
||||
# This software is released under the MIT License.
|
||||
# https://opensource.org/licenses/MIT
|
||||
|
||||
# Libraries
|
||||
target_link_libraries(${DAWN_TARGET_NAME}
|
||||
PUBLIC
|
||||
m
|
||||
)
|
||||
|
||||
# Includes
|
||||
target_include_directories(${DAWN_TARGET_NAME}
|
||||
PUBLIC
|
||||
${CMAKE_CURRENT_LIST_DIR}
|
||||
)
|
||||
|
||||
# Platform variables
|
||||
# target_compile_definitions(${DAWN_TARGET_NAME}
|
||||
# PUBLIC
|
||||
# DAWN_ASSET_LOCATION="../../assets.tar"
|
||||
# )
|
||||
|
||||
# Sources
|
||||
target_sources(${DAWN_TARGET_NAME}
|
||||
PRIVATE
|
||||
main.cpp
|
||||
)
|
21
src/dawnlinux/main.cpp
Normal file
21
src/dawnlinux/main.cpp
Normal file
@ -0,0 +1,21 @@
|
||||
// Copyright (c) 2023 Dominic Masters
|
||||
//
|
||||
// This software is released under the MIT License.
|
||||
// https://opensource.org/licenses/MIT
|
||||
|
||||
#include "main.hpp"
|
||||
#include "display/RenderHost.hpp"
|
||||
#include "game/Game.hpp"
|
||||
|
||||
using namespace Dawn;
|
||||
|
||||
int32_t main() {
|
||||
auto game = std::make_shared<Game>();
|
||||
game->init();
|
||||
|
||||
while(!game->isCloseRequested()) {
|
||||
game->update();
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
14
src/dawnlinux/main.hpp
Normal file
14
src/dawnlinux/main.hpp
Normal file
@ -0,0 +1,14 @@
|
||||
// Copyright (c) 2023 Dominic Masters
|
||||
//
|
||||
// This software is released under the MIT License.
|
||||
// https://opensource.org/licenses/MIT
|
||||
|
||||
#pragma once
|
||||
#include "dawnlibs.hpp"
|
||||
|
||||
/**
|
||||
* The main entry point for the program.
|
||||
*
|
||||
* @return 0 for success, anything else for failure.
|
||||
*/
|
||||
int32_t main();
|
Reference in New Issue
Block a user