Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
hoffstadt committed Nov 17, 2024
1 parent 0df4e9f commit dc8221c
Show file tree
Hide file tree
Showing 70 changed files with 7,674 additions and 7,332 deletions.
126 changes: 108 additions & 18 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ jobs:
run: |
cd scripts
python gen_build.py
python gen_deploy.py
- name: Build Pilot Light (DEBUG)
shell: cmd
Expand All @@ -63,9 +64,7 @@ jobs:
if not exist ../out/example_8.dll exit 1
if not exist ../out/example_9.dll exit 1
if not exist ../out/pilot_light.exe exit 1
if not exist ../out/pl_ext.dll exit 1
if not exist ../out/pl_ext_os.dll exit 1
if not exist ../out/pl_ext_proto.dll exit 1
if not exist ../out/pl_unity_ext.dll exit 1
if not exist ../out/pl_script_camera.dll exit 1
cd ..
Expand Down Expand Up @@ -93,11 +92,40 @@ jobs:
if not exist ../out/example_8.dll exit 1
if not exist ../out/example_9.dll exit 1
if not exist ../out/pilot_light.exe exit 1
if not exist ../out/pl_ext.dll exit 1
if not exist ../out/pl_ext_os.dll exit 1
if not exist ../out/pl_ext_proto.dll exit 1
if not exist ../out/pl_unity_ext.dll exit 1
if not exist ../out/pl_script_camera.dll exit 1
- name: Prep 3
shell: cmd
run: |
rmdir /s /q out
- name: Build Pilot Light Deployment (RELEASE)
shell: cmd
run: |
set VULKAN_SDK=D:/a/VulkanSDK
cd src
call deployment_build.bat -c release
if not exist ../out/pl_debug_ext.dll exit 1
if not exist ../out/pl_draw_backend_ext.dll exit 1
if not exist ../out/pl_draw_ext.dll exit 1
if not exist ../out/pl_ecs_ext.dll exit 1
if not exist ../out/pl_gpu_allocators_ext.dll exit 1
if not exist ../out/pl_graphics_ext.dll exit 1
if not exist ../out/pl_image_ext.dll exit 1
if not exist ../out/pl_job_ext.dll exit 1
if not exist ../out/pl_model_loader_ext.dll exit 1
if not exist ../out/pl_rect_pack_ext.dll exit 1
if not exist ../out/pl_renderer_ext.dll exit 1
if not exist ../out/pl_resource_ext.dll exit 1
if not exist ../out/pl_shader_ext.dll exit 1
if not exist ../out/pl_stats_ext.dll exit 1
if not exist ../out/pl_string_intern_ext.dll exit 1
if not exist ../out/pl_ui_ext.dll exit 1
if not exist ../out/pilot_light.exe exit 1
if not exist ../out/pl_script_camera.dll exit 1
cd ..
- name: Package Pilot Light
shell: cmd
run: |
Expand Down Expand Up @@ -136,6 +164,7 @@ jobs:
cd $GITHUB_WORKSPACE
cd scripts
python3 gen_build.py
python3 gen_deploy.py
- name: Build Pilot Light (DEBUG)
run: |
Expand All @@ -161,9 +190,7 @@ jobs:
test -f ./out/example_6.dylib || exit 1
test -f ./out/example_8.dylib || exit 1
test -f ./out/example_9.dylib || exit 1
test -f ./out/pl_ext.dylib || exit 1
test -f ./out/pl_ext_os.dylib || exit 1
test -f ./out/pl_ext_proto.dylib || exit 1
test -f ./out/pl_unity_ext.dylib || exit 1
test -f ./out/pl_script_camera.dylib || exit 1
- name: Prep 2
Expand Down Expand Up @@ -195,9 +222,41 @@ jobs:
test -f ./out/example_6.dylib || exit 1
test -f ./out/example_8.dylib || exit 1
test -f ./out/example_9.dylib || exit 1
test -f ./out/pl_ext.dylib || exit 1
test -f ./out/pl_ext_os.dylib || exit 1
test -f ./out/pl_ext_proto.dylib || exit 1
test -f ./out/pl_unity_ext.dylib || exit 1
test -f ./out/pl_script_camera.dylib || exit 1
- name: Prep 3
run: |
cd $GITHUB_WORKSPACE
rm -r out
- name: Build Pilot Light Deployment (RELEASE)
run: |
cd $GITHUB_WORKSPACE
cd src
chmod +x deployment_build.sh
./deployment_build.sh -c release
cd ..
cd out
chmod +x pilot_light
cd ..
test -f ./out/pilot_light || exit 1
test -f ./out/pl_debug_ext.dylib || exit 1
test -f ./out/pl_draw_backend_ext.dylib || exit 1
test -f ./out/pl_draw_ext.dylib || exit 1
test -f ./out/pl_ecs_ext.dylib || exit 1
test -f ./out/pl_gpu_allocators_ext.dylib || exit 1
test -f ./out/pl_graphics_ext.dylib || exit 1
test -f ./out/pl_image_ext.dylib || exit 1
test -f ./out/pl_job_ext.dylib || exit 1
test -f ./out/pl_model_loader_ext.dylib || exit 1
test -f ./out/pl_rect_pack_ext.dylib || exit 1
test -f ./out/pl_renderer_ext.dylib || exit 1
test -f ./out/pl_resource_ext.dylib || exit 1
test -f ./out/pl_shader_ext.dylib || exit 1
test -f ./out/pl_stats_ext.dylib || exit 1
test -f ./out/pl_string_intern_ext.dylib || exit 1
test -f ./out/pl_ui_ext.dylib || exit 1
test -f ./out/pl_script_camera.dylib || exit 1
- name: Package Pilot Light
Expand Down Expand Up @@ -245,6 +304,7 @@ jobs:
cd $GITHUB_WORKSPACE
cd scripts
python3 gen_build.py
python3 gen_deploy.py
- name: Build Pilot Light (DEBUG)
run: |
Expand All @@ -270,9 +330,7 @@ jobs:
test -f ./out/example_6.so || exit 1
test -f ./out/example_8.so || exit 1
test -f ./out/example_9.so || exit 1
test -f ./out/pl_ext.so || exit 1
test -f ./out/pl_ext_os.so || exit 1
test -f ./out/pl_ext_proto.so || exit 1
test -f ./out/pl_unity_ext.so || exit 1
test -f ./out/pl_script_camera.so || exit 1
- name: Prep 2
Expand Down Expand Up @@ -304,9 +362,41 @@ jobs:
test -f ./out/example_6.so || exit 1
test -f ./out/example_8.so || exit 1
test -f ./out/example_9.so || exit 1
test -f ./out/pl_ext.so || exit 1
test -f ./out/pl_ext_os.so || exit 1
test -f ./out/pl_ext_proto.so || exit 1
test -f ./out/pl_unity_ext.so || exit 1
test -f ./out/pl_script_camera.so || exit 1
- name: Prep 3
run: |
cd $GITHUB_WORKSPACE
rm -r out
- name: Build Pilot Light Deployment (RELEASE)
run: |
cd $GITHUB_WORKSPACE
cd src
chmod +x deployment_build.sh
./deployment_build.sh -c release
cd ..
cd out
chmod +x pilot_light
cd ..
test -f ./out/pilot_light || exit 1
test -f ./out/pl_debug_ext.so || exit 1
test -f ./out/pl_draw_backend_ext.so || exit 1
test -f ./out/pl_draw_ext.so || exit 1
test -f ./out/pl_ecs_ext.so || exit 1
test -f ./out/pl_gpu_allocators_ext.so || exit 1
test -f ./out/pl_graphics_ext.so || exit 1
test -f ./out/pl_image_ext.so || exit 1
test -f ./out/pl_job_ext.so || exit 1
test -f ./out/pl_model_loader_ext.so || exit 1
test -f ./out/pl_rect_pack_ext.so || exit 1
test -f ./out/pl_renderer_ext.so || exit 1
test -f ./out/pl_resource_ext.so || exit 1
test -f ./out/pl_shader_ext.so || exit 1
test -f ./out/pl_stats_ext.so || exit 1
test -f ./out/pl_string_intern_ext.so || exit 1
test -f ./out/pl_ui_ext.so || exit 1
test -f ./out/pl_script_camera.so || exit 1
- name: Package Pilot Light
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ examples/build.bat
examples/build.sh
tests/build.bat
tests/build.sh
src/build_deploy.bat
src/build_deploy.sh

# custom or user or mod
src/*_user.*
Expand Down
2 changes: 1 addition & 1 deletion examples/build_linux.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash

# Auto Generated by:
# "pl_build.py" version: 1.0.11
# "pl_build.py" version: 1.0.12

# Project: pilotlight_examples

Expand Down
2 changes: 1 addition & 1 deletion examples/build_macos.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

# Auto Generated by:
# "pl_build.py" version: 1.0.11
# "pl_build.py" version: 1.0.12

# Project: pilotlight_examples

Expand Down
2 changes: 1 addition & 1 deletion examples/build_win32.bat
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

:: Project: pilotlight_examples
:: Auto Generated by:
:: "pl_build.py" version: 1.0.11
:: "pl_build.py" version: 1.0.12

:: Project: pilotlight_examples

Expand Down
1 change: 1 addition & 0 deletions examples/example_1.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ Index of this file:
#include <stdio.h>
#include <string.h> // memset
#include "pl.h"
#include "pl_window_ext.h"

//-----------------------------------------------------------------------------
// [SECTION] structs
Expand Down
8 changes: 4 additions & 4 deletions examples/example_2.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ Index of this file:
#include "pl_math.h"

// extensions
#include "pl_window_ext.h"
#include "pl_draw_ext.h"
#include "pl_shader_ext.h"
#include "pl_graphics_ext.h"
Expand Down Expand Up @@ -95,8 +96,8 @@ pl_app_load(plApiRegistryI* ptApiRegistry, plAppData* ptAppData)
const plDataRegistryI* ptDataRegistry = pl_get_api_latest(ptApiRegistry, plDataRegistryI);

// set log & profile contexts
pl_set_log_context(ptDataRegistry->get_data("log"));
pl_set_profile_context(ptDataRegistry->get_data("profile"));
pl_set_log_context(ptDataRegistry->get_data(PL_LOG_CONTEXT_NAME));
pl_set_profile_context(ptDataRegistry->get_data(PL_PROFILE_CONTEXT_NAME));

// if "ptAppData" is a valid pointer, then this function is being called
// during a hot reload.
Expand Down Expand Up @@ -124,8 +125,7 @@ pl_app_load(plApiRegistryI* ptApiRegistry, plAppData* ptAppData)
const plExtensionRegistryI* ptExtensionRegistry = pl_get_api_latest(ptApiRegistry, plExtensionRegistryI);

// load extensions
ptExtensionRegistry->load("pl_ext", NULL, NULL, true);
ptExtensionRegistry->load("pl_ext_os", NULL, NULL, false);
ptExtensionRegistry->load("pl_unity_ext", NULL, NULL, true);

// load required apis (NULL if not available)
gptIO = pl_get_api_latest(ptApiRegistry, plIOI);
Expand Down
Loading

0 comments on commit dc8221c

Please sign in to comment.