Compare commits
33 Commits
9145e739ba
...
v0.0.1
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9005863300 | ||
|
|
60a1683255 | ||
|
|
e85781c29e | ||
|
|
580c05c37b | ||
|
|
2c7bb51658 | ||
|
|
3f80057682 | ||
|
|
8f868529f8 | ||
|
|
8e6da66609 | ||
|
|
ae4e81c937 | ||
|
|
ed1dc1eed9 | ||
|
|
50dc6c8195 | ||
|
|
bbbe7adb3a | ||
|
|
09a70ab98d | ||
|
|
84c0733a77 | ||
|
|
2f1bb884d7 | ||
|
|
9d36bfd13f | ||
|
|
734caada6c | ||
|
|
3ae209819a | ||
|
|
e3678118b4 | ||
|
|
d654c99a8e | ||
|
|
ee4729d31e | ||
|
|
32746e7f95 | ||
|
|
dac1551039 | ||
|
|
9a395bd741 | ||
|
|
e106427ebc | ||
|
|
6a858f49e6 | ||
|
|
87af2e752e | ||
|
|
959728aee3 | ||
|
|
ad63b7d9ed | ||
|
|
d898960494 | ||
|
|
073bb47586 | ||
|
|
0abc3dbfab | ||
|
|
820442c4d6 |
@@ -9,6 +9,7 @@ jobs:
|
||||
force: false
|
||||
condition: SUCCESSFUL
|
||||
optional: false
|
||||
jobExecutor: terra-executor
|
||||
triggers:
|
||||
- type: BranchUpdateTrigger
|
||||
branches: main
|
||||
@@ -23,6 +24,15 @@ jobs:
|
||||
timeout: 14400
|
||||
- name: Compile for Linux
|
||||
steps:
|
||||
- type: SetupCacheStep
|
||||
name: conan-cache
|
||||
key: conan-cache-@file:conanfile.txt@
|
||||
paths:
|
||||
- /root/.conan2
|
||||
uploadStrategy: UPLOAD_IF_CHANGED
|
||||
changeDetectionExcludes: /root/.conan2/p/*/dl /root/.conan2/logs
|
||||
condition: SUCCESSFUL
|
||||
optional: true
|
||||
- type: CheckoutStep
|
||||
name: Checkout
|
||||
cloneCredential:
|
||||
@@ -38,19 +48,21 @@ jobs:
|
||||
interpreter:
|
||||
type: DefaultInterpreter
|
||||
commands: |
|
||||
conan profile detect --force
|
||||
#git clone --depth 1 https://github.com/dotnet/runtime.git
|
||||
#cd runtime
|
||||
#./build.sh -c Release -subset host
|
||||
|
||||
#cp artifacts/bin/native/net10.0-linux-Release-x64/nethost/libnethost.a /onedev-build/workspace/lib/
|
||||
|
||||
git submodule update --init --recursive
|
||||
|
||||
conan profile detect --force
|
||||
conan install . -c tools.system.package_manager:mode=install --output-folder=build --build=missing -s build_type=${BUILD_TYPE}
|
||||
|
||||
cmake -S . -G Ninja -B build -DCMAKE_BUILD_TYPE=${BUILD_TYPE} -DCMAKE_TOOLCHAIN_FILE=conan_toolchain.cmake
|
||||
|
||||
echo ====== Building =============================
|
||||
cmake --build build --config ${BUILD_TYPE}
|
||||
|
||||
echo ====== ls ===================================
|
||||
ls -la
|
||||
|
||||
echo ====== ls build =============================
|
||||
ls build -la
|
||||
envVars:
|
||||
- name: BUILD_TYPE
|
||||
value: Debug
|
||||
@@ -67,6 +79,57 @@ jobs:
|
||||
artifacts: editor/* open_engine/*
|
||||
condition: SUCCESSFUL
|
||||
optional: false
|
||||
jobExecutor: luna-executor
|
||||
triggers:
|
||||
- type: BranchUpdateTrigger
|
||||
branches: main
|
||||
userMatch: anyone
|
||||
projects: OpenEngine
|
||||
retryCondition: never
|
||||
maxRetries: 3
|
||||
retryDelay: 30
|
||||
timeout: 14400
|
||||
- name: Release to Gitea
|
||||
steps:
|
||||
- type: CommandStep
|
||||
name: Release to Gitea
|
||||
runInContainer: true
|
||||
image: erriss/erris-build_tools:V0.8
|
||||
interpreter:
|
||||
type: DefaultInterpreter
|
||||
commands: |
|
||||
# 1. Create the Release metadata
|
||||
RELEASE_JSON=$(printf '{"tag_name":"v1.0.%s","target_commitish":"main","name":"Release v1.0.%s","body":"Automated build from OneDev","draft":false,"prerelease":false}' "$ONEDEV_BUILD_NUMBER" "$ONEDEV_BUILD_NUMBER")
|
||||
|
||||
curl -X 'POST' \
|
||||
"https://gitea.anfer.fr/api/v1/repos/anfer/OpenEngine/releases" \
|
||||
-H "Authorization: token @secret:Gitea@" \
|
||||
-H "Content-Type: application/json" \
|
||||
-d "$RELEASE_JSON" > release_info.json
|
||||
|
||||
# 2. Extract the Release ID (using jq)
|
||||
RELEASE_ID=$(jq '.id' release_info.json)
|
||||
|
||||
# 3. Upload your binary (oe_editor)
|
||||
curl -X 'POST' \
|
||||
"https://gitea.anfer.fr/api/v1/repos/anfer/OpenEngine/releases/$RELEASE_ID/assets?name=oe_editor" \
|
||||
-H "Authorization: token @secret:Gitea@" \
|
||||
-H "Content-Type: application/octet-stream" \
|
||||
--data-binary=build/editor/oe_editor
|
||||
envVars:
|
||||
- name: ONEDEV_BUILD_NUMBER
|
||||
value: '1'
|
||||
useTTY: true
|
||||
condition: SUCCESSFUL
|
||||
optional: false
|
||||
jobExecutor: terra-executor
|
||||
triggers:
|
||||
- type: DependencyFinishedTrigger
|
||||
projects: OpenEngine
|
||||
jobDependencies:
|
||||
- jobName: Compile for Linux
|
||||
requireSuccessful: true
|
||||
artifacts: '**'
|
||||
retryCondition: never
|
||||
maxRetries: 3
|
||||
retryDelay: 30
|
||||
|
||||
@@ -7,6 +7,8 @@ joltphysics/5.2.0
|
||||
fastgltf/0.9.0
|
||||
glm/1.0.1
|
||||
glfw/3.4
|
||||
shaderc/2025.3
|
||||
spirv-cross/1.4.321.0
|
||||
|
||||
[generators]
|
||||
CMakeDeps
|
||||
|
||||
@@ -19,10 +19,25 @@ add_executable(${PROJECT_EXECUTABLE_NAME}
|
||||
${SRC_FILES}
|
||||
)
|
||||
|
||||
file(GLOB NETHOST_DIR_CANDIDATES
|
||||
"/usr/share/dotnet/packs/Microsoft.NETCore.App.Host.*-x64/*/runtimes/linux-x64/native"
|
||||
"/usr/share/dotnet/packs/Microsoft.NETCore.App.Host.*-x64/*/runtimes/arch-x64/native"
|
||||
)
|
||||
|
||||
# Pick the first match
|
||||
list(GET NETHOST_DIR_CANDIDATES 0 NETHOST_DIR)
|
||||
|
||||
if(NOT NETHOST_DIR)
|
||||
message(FATAL_ERROR "Could not find NETCore native directory")
|
||||
else()
|
||||
message(STATUS "Found nethost dir: ${NETHOST_DIR}")
|
||||
endif()
|
||||
|
||||
target_include_directories(${PROJECT_EXECUTABLE_NAME} PRIVATE
|
||||
"${PROJECT_SOURCE_DIR}/include"
|
||||
"${PROJECT_SOURCE_DIR}/editor/include"
|
||||
"/usr/include/freetype2/"
|
||||
"${NETHOST_DIR}"
|
||||
)
|
||||
|
||||
target_link_libraries(${PROJECT_EXECUTABLE_NAME} PRIVATE
|
||||
@@ -30,12 +45,12 @@ target_link_libraries(${PROJECT_EXECUTABLE_NAME} PRIVATE
|
||||
imgui::imgui
|
||||
open_engine
|
||||
dl
|
||||
nethost
|
||||
freetype
|
||||
EnTT::EnTT
|
||||
nethost
|
||||
)
|
||||
|
||||
target_link_directories(${PROJECT_EXECUTABLE_NAME} PRIVATE
|
||||
${PROJECT_SOURCE_DIR}/lib
|
||||
/usr/share/dotnet/packs/Microsoft.NETCore.App.Host.arch-x64/10.0.3/runtimes/arch-x64/native
|
||||
${CMAKE_SOURCE_DIR}/lib
|
||||
${NETHOST_DIR}
|
||||
)
|
||||
|
||||
@@ -5,9 +5,9 @@
|
||||
#include <open_engine.hpp>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "/usr/share/dotnet/packs/Microsoft.NETCore.App.Host.arch-x64/10.0.3/runtimes/arch-x64/native/nethost.h"
|
||||
#include "/usr/share/dotnet/packs/Microsoft.NETCore.App.Host.arch-x64/10.0.3/runtimes/arch-x64/native/hostfxr.h"
|
||||
#include "/usr/share/dotnet/packs/Microsoft.NETCore.App.Host.arch-x64/10.0.3/runtimes/arch-x64/native/coreclr_delegates.h"
|
||||
#include <nethost.h>
|
||||
#include <hostfxr.h>
|
||||
#include <coreclr_delegates.h>
|
||||
|
||||
class Modding : public OpenEngine::Layer
|
||||
{
|
||||
|
||||
@@ -18,6 +18,8 @@ find_package(fastgltf REQUIRED)
|
||||
find_package(spdlog REQUIRED)
|
||||
find_package(glm REQUIRED)
|
||||
find_package(glfw3 REQUIRED)
|
||||
find_package(shaderc REQUIRED)
|
||||
find_package(spirv-cross REQUIRED)
|
||||
|
||||
file(GLOB_RECURSE SRC_FILES "src/*.cpp")
|
||||
file(GLOB IMGUIZMO_SRC_FILES "${CMAKE_SOURCE_DIR}/vendor/ImGuizmo/*.cpp")
|
||||
@@ -38,7 +40,7 @@ target_include_directories(${PROJECT_EXECUTABLE_NAME} PRIVATE
|
||||
|
||||
target_include_directories(${PROJECT_EXECUTABLE_NAME} PUBLIC
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/include"
|
||||
"/home/erris/.conan2/p/b/imguic69fe98538919/p/include"
|
||||
#"/home/erris/.conan2/p/b/imguic69fe98538919/p/include"
|
||||
"vendor/nativefiledialog-extended/src/include"
|
||||
"${CMAKE_SOURCE_DIR}/vendor/ImGuizmo"
|
||||
)
|
||||
@@ -57,7 +59,7 @@ target_link_libraries(${PROJECT_EXECUTABLE_NAME} PUBLIC
|
||||
X11
|
||||
yaml-cpp::yaml-cpp
|
||||
nfd
|
||||
shaderc_combined
|
||||
shaderc::shaderc
|
||||
glslang
|
||||
glslang-default-resource-limits
|
||||
SPIRV
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
#ifndef PCH_HPP
|
||||
#define PCH_HPP
|
||||
|
||||
#include "open_engine/logging.hpp"
|
||||
#include <open_engine/logging.hpp>
|
||||
#include <shaderc/shaderc.hpp>
|
||||
|
||||
#include <functional>
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
#define SHADER_HPP
|
||||
|
||||
#include <open_engine/ref_scope.hpp>
|
||||
|
||||
#include <glm/glm.hpp>
|
||||
#include <string>
|
||||
|
||||
|
||||
@@ -6,14 +6,12 @@
|
||||
#include <core/time.hpp>
|
||||
#include <logging.hpp>
|
||||
|
||||
#include <shaderc/shaderc.hpp>
|
||||
#include <spirv_cross/spirv_cross.hpp>
|
||||
#include <spirv_cross/spirv_glsl.hpp>
|
||||
#include <glm/gtc/type_ptr.hpp>
|
||||
#include <glm/glm.hpp>
|
||||
#include <filesystem>
|
||||
#include <glad/glad.h>
|
||||
//#include <alloca.h>
|
||||
|
||||
namespace OpenEngine {
|
||||
|
||||
@@ -30,7 +28,7 @@ namespace OpenEngine {
|
||||
return 0;
|
||||
}
|
||||
|
||||
static shaderc_shader_kind GLShaderStageToShaderC(GLenum stage)
|
||||
static ::shaderc_shader_kind GLShaderStageToShaderC(GLenum stage)
|
||||
{
|
||||
switch (stage)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user