Commit Graph
1343 Commits
Author SHA1 Message Date
Henrik RydgårdandClaude Sonnet 5 abe6786ae1 Rename core to Core and extract it and GPU into their own CMakeLists.txt
Mirrors the earlier Common extraction. The old "core" target folded in
all of GPU/ (~200 files) plus a few ext/ files wholesale; Windows
already treats GPU as its own project (GPU.vcxproj), so GPU/CMakeLists.txt
splits that out too. GPU has a genuine two-way dependency with Core
(Core/System.cpp calls GPU_Init(), GPU/* calls back into Core for
Memory/Config/CoreTiming/etc), so GPU is a CMake OBJECT library: its
object files are always included wherever consumed instead of being
lazily pulled from an archive, avoiding the GNU ld single-pass
archive-ordering problem a two-way STATIC dependency would hit.

Also fixed a few library misattributions discovered while tracing what
each file actually uses:
- GlslangLibs (glslang/spirv-cross) moved from Core to Common, since
  it's Common/GPU/ShaderTranslation.cpp and VulkanContext.cpp that
  call into it directly. It only worked before because Core happened
  to always be linked after Common.
- ZSTD and OPENGL_LIBRARIES/X11_LIBRARIES moved from Core to GPU,
  matching where they're actually called (GPU/Debugger/Record.cpp and
  Playback.cpp for ZSTD, GPU/GLES for raw gl*() calls).
- GPU also needs Ext::Snappy directly (Playback.cpp calls
  snappy_uncompress) and the libretro-common include dir under
  LIBRETRO, both previously inherited for free by accident.

Also fixed USE_DISCORD's add_compile_definitions ordering: it was
being defined after ppsspp_ui's add_library call, so the UI target
never actually saw it on non-MSVC platforms.

Co-Authored-By: Claude Sonnet 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01PSNaZnHCjmryS3ziVN9gZU
2026-07-24 20:16:07 +02:00
Henrik RydgårdandClaude Sonnet 5 b2d375f2e5 Extract Common into its own CMakeLists.txt
First step of breaking up the monolithic root CMakeLists.txt: move the
add_library(Common STATIC ...) target definition, and every scattered
target_link_libraries/target_compile_definitions/target_include_directories
call touching it, into Common/CMakeLists.txt, pulled in via
add_subdirectory(Common).

Source paths are now relative to Common/ instead of prefixed with
"Common/". The two files living outside that directory (ext/jpge/*)
use ${CMAKE_SOURCE_DIR}/... instead.

include_directories(Common) stays in the root file rather than moving
into Common/CMakeLists.txt: it's a directory-scope command that needs
to affect targets defined *later* in the root file, and add_subdirectory
scope doesn't propagate upward or sideways, so moving it would have
silently broken unprefixed #includes elsewhere in the project.

add_subdirectory(Common) is placed at the point where the *last*
prerequisite variable it needs (PNG_LIBRARIES, RT_LIB, ATOMIC_LIB, etc.)
is guaranteed already set, not where the old add_library(Common ...)
used to start - some of those are resolved later in the file than
Common's original position was.

Verified with a clean ./b.sh --debug rebuild and a HEADLESS=ON
UNITTEST=ON reconfigure/build.

Co-Authored-By: Claude Sonnet 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01PSNaZnHCjmryS3ziVN9gZU
2026-07-24 20:16:07 +02:00
Henrik RydgårdandClaude Sonnet 5 4f3336016f Link openxr_loader into ppsspp_jni for the Android VR build
The Android VR build (ANDROID=true, OPENXR=TRUE) was failing to link
ppsspp_jni with undefined references to xrGetInstanceProcAddr,
xrCreateReferenceSpace, xrEnumerateViewConfigurations, etc. - all called
from Common/VR/*.cpp, which is unconditionally part of Common and always
linked into ppsspp_jni via core.

openxr_loader (built via ext/OpenXR-SDK whenever OPENXR AND NOT
ARMV7_DEVICE) was only ever being added to targetExtraLibs, which just
${TargetBin} - the desktop-style executable - consumes. ppsspp_jni,
the actual Android JNI target Gradle's CMake external native build
uses, never got it. Link it in directly, gated the same way OpenXR is
gated everywhere else in the file.

Co-Authored-By: Claude Sonnet 5 <[email protected]>
2026-07-24 19:57:57 +02:00
Henrik Rydgård 71e2a87611 Fix Android CMakeLists.txt build 2026-07-24 16:59:41 +02:00
Henrik Rydgård 85f8715660 Break the circular dependency caused by putting EmuThread in core using an interface 2026-07-24 15:31:42 +02:00
Henrik Rydgård 2489f5c581 Some CMakeLists.txt reorganization, use EmuThread from SDL 2026-07-24 15:31:41 +02:00
Henrik Rydgård afe4d5beaf Buildfixes, dependency shuffling to make things more logical 2026-07-24 14:43:34 +02:00
Henrik Rydgård dd8c282a26 Add a ppsspp_ui target 2026-07-24 12:06:15 +02:00
Henrik Rydgård 733e07d581 CMakeLists.txt: Remove the confusing "native" target and reshuffle dependencies 2026-07-24 12:06:15 +02:00
Henrik Rydgård b9a3b322cb CMakeLists.txt: Stop using ${CoreLibName} 2026-07-24 12:06:15 +02:00
Craig Carnell f1f73b0418 libretro: remove CmdLine as not used 2026-07-22 20:16:18 +01:00
Henrik Rydgård 221aba92da Move EmuThread.cpp/h to Core, in preparation for sharing logic 2026-07-21 12:50:22 +02:00
Henrik Rydgård 29836ea74e Move the new incomplete command line parser to Core 2026-07-20 12:02:07 +02:00
Henrik Rydgård cfd9c62f17 Ubuntu/cmake: Improve error messages when SDL3 is missing 2026-06-29 23:23:58 +02:00
Henrik Rydgård 510a4336ef Android buildfix 2026-06-16 19:23:45 +02:00
Henrik Rydgård 494ac1e0fe Another buildfix attempt 2026-06-16 11:44:44 +02:00
Henrik Rydgård 1e62cb7fc1 Finish the SDL3 port on Mac, update CI to 26.04 2026-06-16 11:39:57 +02:00
Henrik Rydgård fbf2ac91a8 Remove SDL2 references 2026-06-16 11:39:24 +02:00
Henrik Rydgård cd02b5d31c Use fontconfig 2026-06-16 11:39:24 +02:00
Henrik Rydgård 2b821037d7 SDL3_ttf work 2026-06-16 11:39:24 +02:00
Henrik Rydgård 6c85a1a4b6 More SDL3 work by AI 2026-06-16 11:39:24 +02:00
Henrik Rydgård 34c2218558 SDL3 port phase 1 2026-06-16 11:39:24 +02:00
Henrik Rydgård ec6c7b08f5 Add a common TextureAlpha enum, replacing CheckAlphaResult and ReplacedTextureAlpha. 2026-06-09 11:25:50 +02:00
Henrik Rydgård 195455a7f4 Break out VertexReader, prepare VertexReader for CrossSIMD use in software transform 2026-06-04 12:45:17 +02:00
Eloren1 74f9b36bd5 Add LoadStateConfirmScreen to all build systems 2026-05-31 22:09:01 +03:00
Henrik Rydgård 8df41f8fb9 Merge pull request #21715 from hrydgard/vp-refactor-2
Viewport and culling total rework
2026-05-31 14:07:41 +02:00
Henrik Rydgård 0b47955c64 Delete geometry shader culling support. Is mostly replaced, and will be fully replaced with software transform. 2026-05-30 19:07:59 +02:00
Henrik Rydgård 83dcd24043 Small SIMD optimization in software transform 2026-05-30 19:07:59 +02:00
Kevin Reinholz 98becf8787 Don't enable experimental BUILD_BUNDLED_FFMPEG option by default 2026-05-29 20:27:10 -07:00
Kevin Reinholz bc2648edb1 Add experimental cmake port of ppsspp-ffmpeg as a standard module built from source 2026-05-29 19:06:04 -07:00
Craig Carnell 8352935956 webOS: fix aarch64 compile 2026-05-29 20:40:11 +01:00
Henrik Rydgård f60e27a9b7 Just some refactoring of the GPUStatistics struct, and more use of StringWriter 2026-05-29 14:40:31 +02:00
Kevin Reinholz 344bbff308 Fix build on aarch64/arm64 FreeBSD 2026-05-27 20:04:01 -07:00
Henrik Rydgård ff76224191 A cross compilation setup by Claude for loongarch64 to check that things build. 2026-05-25 13:29:01 +02:00
Henrik Rydgård 3aa4714ce0 Merge draw_text_win with draw_text_uwp. 2026-05-18 14:11:22 +02:00
Henrik Rydgård 3325cbe6b2 Remove the legacy icon images for zip/rar/7z. Include this in the regular gamelist so search works for them. 2026-05-03 18:43:48 +02:00
Henrik Rydgård fd7c5cdd6b Add pugixml dependency 2026-04-16 12:12:12 -06:00
Henrik Rydgård 3663d46a5b Split out the GameBrowser from MainScreen 2026-04-13 13:20:19 -06:00
Kevin Reinholz 4a5dd4caa6 Fix build with system rapidjson. Attempt to break out the lib7zip support--this fixes build on amd64 FreeBSD 2026-04-09 16:44:45 -07:00
Henrik Rydgård 0a0b4b9d95 Make opening 7z file android-compatible. Assorted buildfixes. 2026-03-27 14:34:18 -06:00
Henrik Rydgård 99d5bcc26d Build fixes, crashfix on fail-to-open 2026-03-27 14:34:18 -06:00
Henrik Rydgård 8380e13f10 Add AI-generated SevenZipFileReader 2026-03-27 14:34:18 -06:00
Henrik Rydgård 116c31e7d9 Add the LZMA sdk 2026-03-27 14:34:15 -06:00
Chris Healy ba59170b0b OpenGL: Add GLProfiler for GPU timestamp profiling
Adds a new GLProfiler class for GPU-side timestamp profiling, similar to
VulkanProfiler. Uses GL_EXT_disjoint_timer_query (GLES) or GL_ARB_timer_query
(desktop GL).

Features:
- Scoped Begin()/End() profiling with printf-style naming
- Automatic GPU disjoint detection (frequency changes invalidate results)
- Millisecond timing output via INFO_LOG
- Pre-allocated query pool (1024 queries max per frame)
- Nested scope support with indented output

Signed-off-by: Chris Healy <[email protected]>
2026-03-18 09:52:43 -07:00
Kevin Reinholz d404040b21 Merge branch 'master' into master 2026-03-13 19:00:00 -07:00
Kevin Reinholz a7b672ae0d Remove redundant sse2 flag on x86_64 as it's enabled by default and only needs to explicitly be set on 32-bit x86 2026-03-13 18:44:09 -07:00
Kevin Reinholz f020bcdd75 Create option to build with system freetype, libchdr, and rapidjson instead of bundled modules. Add a couple of FreeBSD-specific tweaks to CMakeLists.txt while at it 2026-03-10 18:03:06 -07:00
Henrik Rydgård 19bb9c5a34 Support the more modern file picker, spawns a lot faster 2026-03-11 00:17:46 +01:00
Eric Warmenhoven 9b26df8283 libretro: fix ios/tvos builds 2026-03-08 12:16:52 -04:00
Henrik Rydgård d6ca0378b6 Move DarwinFileSystemServices.mm/h to Core/Util 2026-03-07 11:35:34 +01:00