2020-08-22 22:30:12 -04:00
|
|
|
# We define our own compilation flags here.
|
2020-10-03 18:36:02 -04:00
|
|
|
set(CMAKE_CXX_STANDARD 17)
|
2020-08-26 20:02:44 -04:00
|
|
|
|
2020-08-22 22:30:12 -04:00
|
|
|
enable_language(ASM_NASM)
|
2020-08-28 20:26:27 -04:00
|
|
|
set(CMAKE_ASM_NASM_SOURCE_FILE_EXTENSIONS ${CMAKE_ASM_NASM_SOURCE_FILE_EXTENSIONS} asm)
|
2020-10-09 00:39:12 -04:00
|
|
|
set(CMAKE_ASM_NASM_COMPILE_OBJECT "<CMAKE_ASM_NASM_COMPILER> <INCLUDES> -f ${CMAKE_ASM_NASM_OBJECT_FORMAT} -o <OBJECT> <SOURCE>")
|
2020-08-28 20:26:27 -04:00
|
|
|
set_source_files_properties(kernel/asm_funcs.asm PROPERTIES COMPILE_FLAGS "-g")
|
2020-08-22 22:30:12 -04:00
|
|
|
set(RUNTIME_SOURCE
|
|
|
|
runtime.cpp
|
2022-02-07 23:53:36 -05:00
|
|
|
discord.cpp
|
2020-08-22 22:30:12 -04:00
|
|
|
system/SystemThread.cpp
|
|
|
|
system/IOP_Kernel.cpp
|
|
|
|
system/iop_thread.cpp
|
|
|
|
system/Deci2Server.cpp
|
2021-08-14 16:00:50 -04:00
|
|
|
system/newpad.cpp
|
2020-08-22 22:30:12 -04:00
|
|
|
sce/libcdvd_ee.cpp
|
|
|
|
sce/libscf.cpp
|
2021-02-21 11:02:28 -05:00
|
|
|
sce/libdma.cpp
|
2021-02-22 09:36:30 -05:00
|
|
|
sce/libpad.cpp
|
2021-02-21 11:02:28 -05:00
|
|
|
sce/libgraph.cpp
|
2020-08-22 22:30:12 -04:00
|
|
|
sce/deci2.cpp
|
|
|
|
sce/sif_ee.cpp
|
2021-10-01 23:12:34 -04:00
|
|
|
sce/sif_ee_memcard.cpp
|
2020-08-22 22:30:12 -04:00
|
|
|
sce/iop.cpp
|
|
|
|
sce/stubs.cpp
|
2022-06-26 18:17:11 -04:00
|
|
|
kernel/common/fileio.cpp
|
|
|
|
kernel/common/kboot.cpp
|
|
|
|
kernel/common/kdgo.cpp
|
|
|
|
kernel/common/kdsnetm.cpp
|
|
|
|
kernel/common/klink.cpp
|
|
|
|
kernel/common/klisten.cpp
|
|
|
|
kernel/common/kmachine.cpp
|
|
|
|
kernel/common/kmalloc.cpp
|
|
|
|
kernel/common/kmemcard.cpp
|
|
|
|
kernel/common/kprint.cpp
|
|
|
|
kernel/common/kscheme.cpp
|
|
|
|
kernel/common/ksocket.cpp
|
|
|
|
kernel/common/ksound.cpp
|
|
|
|
kernel/jak1/fileio.cpp
|
|
|
|
kernel/jak1/kboot.cpp
|
|
|
|
kernel/jak1/kdgo.cpp
|
|
|
|
kernel/jak1/klink.cpp
|
|
|
|
kernel/jak1/klisten.cpp
|
|
|
|
kernel/jak1/kmachine.cpp
|
|
|
|
kernel/jak1/kprint.cpp
|
|
|
|
kernel/jak1/kscheme.cpp
|
|
|
|
kernel/jak1/ksound.cpp
|
|
|
|
kernel/jak2/fileio.cpp
|
|
|
|
kernel/jak2/kboot.cpp
|
|
|
|
kernel/jak2/kdgo.cpp
|
|
|
|
kernel/jak2/klink.cpp
|
|
|
|
kernel/jak2/klisten.cpp
|
|
|
|
kernel/jak2/kmachine.cpp
|
|
|
|
kernel/jak2/kmalloc.cpp
|
|
|
|
kernel/jak2/kprint.cpp
|
|
|
|
kernel/jak2/kscheme.cpp
|
|
|
|
kernel/jak2/ksound.cpp
|
2020-08-28 20:26:27 -04:00
|
|
|
kernel/asm_funcs.asm
|
2021-09-11 20:52:35 -04:00
|
|
|
mips2c/mips2c_table.cpp
|
2022-08-26 18:03:48 -04:00
|
|
|
mips2c/jak1_functions/bones.cpp
|
|
|
|
mips2c/jak1_functions/collide_cache.cpp
|
|
|
|
mips2c/jak1_functions/collide_edge_grab.cpp
|
|
|
|
mips2c/jak1_functions/collide_func.cpp
|
|
|
|
mips2c/jak1_functions/collide_mesh.cpp
|
|
|
|
mips2c/jak1_functions/collide_probe.cpp
|
|
|
|
mips2c/jak1_functions/draw_string.cpp
|
|
|
|
mips2c/jak1_functions/generic_effect.cpp
|
|
|
|
mips2c/jak1_functions/generic_effect2.cpp
|
|
|
|
mips2c/jak1_functions/generic_merc.cpp
|
|
|
|
mips2c/jak1_functions/generic_tie.cpp
|
|
|
|
mips2c/jak1_functions/joint.cpp
|
|
|
|
mips2c/jak1_functions/merc_blend_shape.cpp
|
|
|
|
mips2c/jak1_functions/ocean.cpp
|
|
|
|
mips2c/jak1_functions/ocean_vu0.cpp
|
|
|
|
mips2c/jak1_functions/ripple.cpp
|
|
|
|
mips2c/jak1_functions/shadow.cpp
|
|
|
|
mips2c/jak1_functions/sky_tng.cpp
|
|
|
|
mips2c/jak1_functions/sparticle.cpp
|
|
|
|
mips2c/jak1_functions/sparticle_launcher.cpp
|
|
|
|
mips2c/jak1_functions/test_func.cpp
|
|
|
|
mips2c/jak1_functions/texture.cpp
|
|
|
|
mips2c/jak1_functions/tfrag.cpp
|
|
|
|
mips2c/jak1_functions/tie_methods.cpp
|
|
|
|
mips2c/jak1_functions/time_of_day.cpp
|
2022-11-30 22:36:09 -05:00
|
|
|
mips2c/jak2_functions/bones.cpp
|
2022-11-20 11:32:29 -05:00
|
|
|
mips2c/jak2_functions/collide_cache.cpp
|
2022-10-30 15:54:10 -04:00
|
|
|
mips2c/jak2_functions/collide_edge_grab.cpp
|
2022-08-26 18:03:48 -04:00
|
|
|
mips2c/jak2_functions/collide_func.cpp
|
2022-10-29 20:32:03 -04:00
|
|
|
mips2c/jak2_functions/collide_hash.cpp
|
2022-10-30 15:54:10 -04:00
|
|
|
mips2c/jak2_functions/collide_mesh.cpp
|
2022-10-01 13:39:56 -04:00
|
|
|
mips2c/jak2_functions/debug.cpp
|
2022-09-05 20:29:12 -04:00
|
|
|
mips2c/jak2_functions/font.cpp
|
2022-11-30 22:36:09 -05:00
|
|
|
mips2c/jak2_functions/foreground.cpp
|
2023-04-16 18:05:35 -04:00
|
|
|
mips2c/jak2_functions/generic_merc.cpp
|
|
|
|
mips2c/jak2_functions/generic_effect.cpp
|
2022-08-28 16:38:58 -04:00
|
|
|
mips2c/jak2_functions/joint.cpp
|
2022-12-02 10:02:13 -05:00
|
|
|
mips2c/jak2_functions/lights.cpp
|
2023-01-01 12:11:18 -05:00
|
|
|
mips2c/jak2_functions/nav_control.cpp
|
|
|
|
mips2c/jak2_functions/nav_mesh.cpp
|
2022-10-08 17:02:40 -04:00
|
|
|
mips2c/jak2_functions/sky.cpp
|
2022-10-09 19:56:07 -04:00
|
|
|
mips2c/jak2_functions/sparticle.cpp
|
|
|
|
mips2c/jak2_functions/sparticle_launcher.cpp
|
2022-11-11 16:23:26 -05:00
|
|
|
mips2c/jak2_functions/spatial_hash.cpp
|
2022-09-11 14:17:55 -04:00
|
|
|
mips2c/jak2_functions/texture.cpp
|
2023-03-29 20:28:48 -04:00
|
|
|
mips2c/jak2_functions/vortex.cpp
|
2022-10-30 19:09:35 -04:00
|
|
|
mips2c/jak2_functions/ocean.cpp
|
|
|
|
mips2c/jak2_functions/ocean_vu0.cpp
|
2023-01-28 16:02:58 -05:00
|
|
|
mips2c/jak2_functions/merc_blend_shape.cpp
|
|
|
|
mips2c/jak2_functions/ripple.cpp
|
2023-01-28 18:44:10 -05:00
|
|
|
mips2c/jak2_functions/squid.cpp
|
2020-08-22 22:30:12 -04:00
|
|
|
overlord/dma.cpp
|
|
|
|
overlord/fake_iso.cpp
|
|
|
|
overlord/iso.cpp
|
|
|
|
overlord/iso_api.cpp
|
|
|
|
overlord/iso_cd.cpp
|
|
|
|
overlord/iso_queue.cpp
|
|
|
|
overlord/isocommon.cpp
|
|
|
|
overlord/overlord.cpp
|
|
|
|
overlord/ramdisk.cpp
|
|
|
|
overlord/sbank.cpp
|
|
|
|
overlord/soundcommon.cpp
|
|
|
|
overlord/srpc.cpp
|
|
|
|
overlord/ssound.cpp
|
2021-03-09 23:51:28 -05:00
|
|
|
overlord/stream.cpp
|
|
|
|
graphics/gfx.cpp
|
2023-03-21 19:41:14 -04:00
|
|
|
graphics/jak2_texture_remap.cpp
|
2021-05-01 00:32:19 -04:00
|
|
|
graphics/display.cpp
|
2021-08-04 21:30:08 -04:00
|
|
|
graphics/sceGraphicsInterface.cpp
|
2022-03-06 19:56:43 -05:00
|
|
|
graphics/opengl_renderer/background/background_common.cpp
|
2022-03-29 21:38:48 -04:00
|
|
|
graphics/opengl_renderer/background/Shrub.cpp
|
2022-03-06 19:56:43 -05:00
|
|
|
graphics/opengl_renderer/background/Tfrag3.cpp
|
|
|
|
graphics/opengl_renderer/background/TFragment.cpp
|
|
|
|
graphics/opengl_renderer/background/Tie3.cpp
|
2022-05-28 19:28:19 -04:00
|
|
|
graphics/opengl_renderer/foreground/Merc2.cpp
|
2022-03-06 19:56:43 -05:00
|
|
|
graphics/opengl_renderer/foreground/Generic2.cpp
|
|
|
|
graphics/opengl_renderer/foreground/Generic2_DMA.cpp
|
|
|
|
graphics/opengl_renderer/foreground/Generic2_Build.cpp
|
|
|
|
graphics/opengl_renderer/foreground/Generic2_OpenGL.cpp
|
2023-02-20 20:25:45 -05:00
|
|
|
graphics/opengl_renderer/sprite/GlowRenderer.cpp
|
|
|
|
graphics/opengl_renderer/sprite/Sprite3.cpp
|
|
|
|
graphics/opengl_renderer/sprite/Sprite3_Distort.cpp
|
|
|
|
graphics/opengl_renderer/sprite/Sprite3_Glow.cpp
|
2022-03-17 21:59:10 -04:00
|
|
|
graphics/opengl_renderer/ocean/CommonOceanRenderer.cpp
|
2022-03-14 19:47:29 -04:00
|
|
|
graphics/opengl_renderer/ocean/OceanMid.cpp
|
|
|
|
graphics/opengl_renderer/ocean/OceanMid_PS2.cpp
|
2022-03-11 22:27:11 -05:00
|
|
|
graphics/opengl_renderer/ocean/OceanMidAndFar.cpp
|
2022-03-15 23:12:40 -04:00
|
|
|
graphics/opengl_renderer/ocean/OceanNear.cpp
|
|
|
|
graphics/opengl_renderer/ocean/OceanNear_PS2.cpp
|
2022-03-11 22:27:11 -05:00
|
|
|
graphics/opengl_renderer/ocean/OceanTexture.cpp
|
|
|
|
graphics/opengl_renderer/ocean/OceanTexture_PC.cpp
|
2022-05-28 20:12:33 -04:00
|
|
|
graphics/opengl_renderer/loader/Loader.cpp
|
|
|
|
graphics/opengl_renderer/loader/LoaderStages.cpp
|
2021-08-07 18:57:13 -04:00
|
|
|
graphics/opengl_renderer/BucketRenderer.cpp
|
2022-04-25 21:53:23 -04:00
|
|
|
graphics/opengl_renderer/CollideMeshRenderer.cpp
|
2021-09-26 11:41:58 -04:00
|
|
|
graphics/opengl_renderer/debug_gui.cpp
|
2023-04-16 18:05:35 -04:00
|
|
|
graphics/opengl_renderer/DepthCue.cpp
|
2021-08-07 18:57:13 -04:00
|
|
|
graphics/opengl_renderer/DirectRenderer.cpp
|
2022-02-27 17:23:12 -05:00
|
|
|
graphics/opengl_renderer/DirectRenderer2.cpp
|
2022-02-15 19:37:51 -05:00
|
|
|
graphics/opengl_renderer/EyeRenderer.cpp
|
2023-02-09 19:11:13 -05:00
|
|
|
graphics/opengl_renderer/LightningRenderer.cpp
|
2021-11-13 20:44:17 -05:00
|
|
|
graphics/opengl_renderer/dma_helpers.cpp
|
2022-03-04 18:22:01 -05:00
|
|
|
graphics/opengl_renderer/opengl_utils.cpp
|
2021-08-06 22:30:02 -04:00
|
|
|
graphics/opengl_renderer/OpenGLRenderer.cpp
|
2021-10-10 20:07:03 -04:00
|
|
|
graphics/opengl_renderer/Profiler.cpp
|
2023-02-27 19:51:14 -05:00
|
|
|
graphics/opengl_renderer/ProgressRenderer.cpp
|
2021-08-06 22:30:02 -04:00
|
|
|
graphics/opengl_renderer/Shader.cpp
|
2022-03-26 19:56:54 -04:00
|
|
|
graphics/opengl_renderer/Shadow_PS2.cpp
|
2022-03-22 21:42:37 -04:00
|
|
|
graphics/opengl_renderer/ShadowRenderer.cpp
|
2021-12-30 19:38:18 -05:00
|
|
|
graphics/opengl_renderer/SkyBlendCPU.cpp
|
|
|
|
graphics/opengl_renderer/SkyBlendGPU.cpp
|
2021-10-10 20:07:03 -04:00
|
|
|
graphics/opengl_renderer/SkyRenderer.cpp
|
2021-09-26 11:41:58 -04:00
|
|
|
graphics/opengl_renderer/TextureUploadHandler.cpp
|
2022-10-01 17:12:12 -04:00
|
|
|
graphics/opengl_renderer/VisDataHandler.cpp
|
2023-04-16 18:05:35 -04:00
|
|
|
graphics/opengl_renderer/Warp.cpp
|
2022-05-02 21:26:17 -04:00
|
|
|
graphics/texture/jak1_tpage_dir.cpp
|
2022-09-05 20:29:12 -04:00
|
|
|
graphics/texture/jak2_tpage_dir.cpp
|
2021-08-08 13:12:44 -04:00
|
|
|
graphics/texture/TextureConverter.cpp
|
|
|
|
graphics/texture/TexturePool.cpp
|
2021-08-09 19:16:39 -04:00
|
|
|
graphics/pipelines/opengl.cpp
|
2021-05-01 00:32:19 -04:00
|
|
|
system/vm/dmac.cpp
|
2022-06-11 11:32:27 -04:00
|
|
|
system/vm/vm.cpp
|
2023-01-02 09:45:38 -05:00
|
|
|
tools/subtitles/subtitle_editor.cpp
|
|
|
|
tools/filter_menu/filter_menu.cpp)
|
2020-08-22 22:30:12 -04:00
|
|
|
|
2022-05-19 16:54:36 -04:00
|
|
|
add_subdirectory(sound)
|
|
|
|
|
2021-01-06 12:16:39 -05:00
|
|
|
# we build the runtime as a static library.
|
2021-03-11 12:54:16 -05:00
|
|
|
add_library(runtime STATIC ${RUNTIME_SOURCE} "../third-party/glad/src/glad.c")
|
2020-08-22 22:30:12 -04:00
|
|
|
|
2022-11-19 23:28:20 -05:00
|
|
|
target_link_libraries(runtime common fmt glfw imgui discord-rpc sound stb_image libco SQLiteCpp)
|
2021-02-03 21:29:46 -05:00
|
|
|
if(WIN32)
|
2021-01-06 12:16:39 -05:00
|
|
|
target_link_libraries(runtime mman)
|
2021-02-03 21:29:46 -05:00
|
|
|
else()
|
2021-03-11 12:54:16 -05:00
|
|
|
target_link_libraries(runtime pthread dl)
|
2021-02-03 21:29:46 -05:00
|
|
|
endif()
|
2020-09-24 17:19:23 -04:00
|
|
|
|
2023-01-02 10:05:22 -05:00
|
|
|
add_executable(gk main.cpp)
|
2021-01-06 12:16:39 -05:00
|
|
|
target_link_libraries(gk runtime)
|