-
-
Notifications
You must be signed in to change notification settings - Fork 152
Expand file tree
/
Copy pathxmake.lua
More file actions
105 lines (95 loc) · 3.85 KB
/
Copy pathxmake.lua
File metadata and controls
105 lines (95 loc) · 3.85 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
includes("third_party/luajit")
add_rules("mode.debug", "mode.release")
add_requires("capstone", "fmt", "freetype", "libcurl", "libsdl3", "libuv", "zlib")
-- Only four of ffmpeg's libraries are used, and asking for "ffmpeg" wholesale
-- never resolves to the system copy: that package requires all eight pkg-config
-- modules, and libpostproc is GPL-only and so isn't packaged on Ubuntu at all.
-- The result is ffmpeg getting built from source on every clean checkout. These
-- are the same four names the Makefile's PACKAGES already asks for.
add_requires("pkgconfig::libavcodec", "pkgconfig::libavformat",
"pkgconfig::libavutil", "pkgconfig::libswresample")
set_languages("c++26")
target("pcsx-redux", function()
add_includedirs(
".",
"src",
"third_party",
"third_party/ELFIO",
"third_party/gl3w",
"third_party/imgui",
"third_party/imgui/backends",
"third_party/imgui/misc/cpp",
"third_party/llhttp",
"third_party/luajit/src",
"third_party/luv/src",
"third_party/luv/deps/lua-compat-5.3/c-api",
"third_party/magic_enum/include",
"third_party/md4c/src",
"third_party/multipart-parser-c",
"third_party/PEGTL/include",
"third_party/tracy/public",
"third_party/ucl",
"third_party/ucl/include",
"third_party/uriparser/include",
"third_party/xbyak/xbyak",
"third_party/zep/extensions",
"third_party/zep/include",
nil
)
add_files("third_party/imgui/*.cpp", { cxxflags = "-include src/forced-includes/imgui.h" })
add_deps("luajit")
add_packages("capstone", "fmt", "freetype", "libcurl", "libsdl3", "libuv", "zlib",
"pkgconfig::libavcodec", "pkgconfig::libavformat",
"pkgconfig::libavutil", "pkgconfig::libswresample")
add_files(
"src/**/*.cc",
"third_party/cq/reclaimer.cc",
"third_party/clip/clip.cpp",
"third_party/clip/image.cpp",
"third_party/cueparser/*.c",
"third_party/gl3w/GL/gl3w.c",
"third_party/gl3w/GL/gl3w-throwers.cc",
"third_party/iec-60908b/*.c",
"third_party/ImFileDialog/ImFileDialog.cpp",
"third_party/imgui/backends/imgui_impl_opengl3.cpp",
"third_party/imgui/backends/imgui_impl_sdl3.cpp",
"third_party/imgui/misc/cpp/imgui_stdlib.cpp",
"third_party/imgui/misc/freetype/imgui_freetype.cpp",
"third_party/imgui_lua_bindings/imgui_lua_bindings.cpp",
"third_party/imgui_md/imgui_md.cpp",
"third_party/imgui_memory_editor/imgui_memory_editor.cpp",
"third_party/llhttp/*.c",
"third_party/lpeg/*.c",
"third_party/lua-protobuf/pb.c",
"third_party/luafilesystem/src/lfs.c",
"third_party/luv/src/luv.c",
"third_party/md4c/src/md4c.c",
"third_party/multipart-parser-c/multipart_parser.c",
"third_party/nanovg/src/nanovg.c",
"third_party/ucl/src/n2e_99.c",
"third_party/ucl/src/n2e_ds.c",
"third_party/ucl/src/alloc.c",
"third_party/uriparser/src/*.c",
"third_party/zep/extensions/repl/mode_repl.cpp",
"third_party/zep/src/*.cpp",
"third_party/zep/src/mcommon/animation/timer.cpp",
"third_party/zep/src/mcommon/file/path.cpp",
"third_party/zep/src/mcommon/string/stringutils.cpp",
nil
)
add_defines(
"IMGUI_IMPL_OPENGL_LOADER_GL3W",
"IMGUI_ENABLE_FREETYPE",
"NVG_NO_STB",
"PB_STATIC_API",
"ZEP_FEATURE_CPP_FILE_SYSTEM",
nil
)
if is_plat("macosx") then
add_files("src/main/complain.mm", "third_party/clip/clip_osx.mm")
add_frameworks("GLUT", "OpenGL", "CoreFoundation", "Cocoa")
else
add_files("third_party/clip/clip_x11.cpp")
add_ldflags("-lstdc++fs", "-lGL", "-lX11", "-lxcb")
end
end)