mirror of
https://github.com/kunkundi/crossdesk.git
synced 2025-10-26 20:25:34 +08:00
Support generate makefile
This commit is contained in:
@@ -20,7 +20,7 @@ X11SessionImpl::~X11SessionImpl() {
|
|||||||
|
|
||||||
void X11SessionImpl::Release() { delete this; }
|
void X11SessionImpl::Release() { delete this; }
|
||||||
|
|
||||||
int X11SessionImpl::Initialize() {}
|
int X11SessionImpl::Initialize() { return 0; }
|
||||||
|
|
||||||
void X11SessionImpl::RegisterObserver(x11_session_observer *observer) {
|
void X11SessionImpl::RegisterObserver(x11_session_observer *observer) {
|
||||||
observer_ = observer;
|
observer_ = observer;
|
||||||
|
|||||||
6
thirdparty/ffmpeg/xmake.lua
vendored
6
thirdparty/ffmpeg/xmake.lua
vendored
@@ -28,7 +28,7 @@ package("ffmpeg")
|
|||||||
add_versions("git:5.0.1", "n5.0.1")
|
add_versions("git:5.0.1", "n5.0.1")
|
||||||
add_versions("git:4.0.2", "n4.0.2")
|
add_versions("git:4.0.2", "n4.0.2")
|
||||||
|
|
||||||
add_configs("gpl", {description = "Enable GPL code", default = true, type = "boolean"})
|
add_configs("gpl", {description = "Enable GPL code", default = false, type = "boolean"})
|
||||||
add_configs("ffprobe", {description = "Enable ffprobe program.", default = false, type = "boolean"})
|
add_configs("ffprobe", {description = "Enable ffprobe program.", default = false, type = "boolean"})
|
||||||
add_configs("ffmpeg", {description = "Enable ffmpeg program.", default = true, type = "boolean"})
|
add_configs("ffmpeg", {description = "Enable ffmpeg program.", default = true, type = "boolean"})
|
||||||
add_configs("ffplay", {description = "Enable ffplay program.", default = false, type = "boolean"})
|
add_configs("ffplay", {description = "Enable ffplay program.", default = false, type = "boolean"})
|
||||||
@@ -42,14 +42,14 @@ package("ffmpeg")
|
|||||||
add_configs("vdpau", {description = "Enable vdpau library.", default = false, type = "boolean"})
|
add_configs("vdpau", {description = "Enable vdpau library.", default = false, type = "boolean"})
|
||||||
add_configs("hardcoded-tables", {description = "Enable hardcoded tables.", default = true, type = "boolean"})
|
add_configs("hardcoded-tables", {description = "Enable hardcoded tables.", default = true, type = "boolean"})
|
||||||
add_configs("asm", {description = "Enable asm", default = false, type = "boolean"})
|
add_configs("asm", {description = "Enable asm", default = false, type = "boolean"})
|
||||||
add_configs("libx264", {description = "Enable libx264", default = true, type = "boolean"})
|
add_configs("libopenh264", {description = "Enable libopenh264", default = true, type = "boolean"})
|
||||||
end
|
end
|
||||||
|
|
||||||
add_links("avfilter", "avdevice", "avformat", "avcodec", "swscale", "swresample", "avutil")
|
add_links("avfilter", "avdevice", "avformat", "avcodec", "swscale", "swresample", "avutil")
|
||||||
if is_plat("macosx") then
|
if is_plat("macosx") then
|
||||||
add_frameworks("CoreFoundation", "Foundation", "CoreVideo", "CoreMedia", "AudioToolbox", "VideoToolbox", "Security")
|
add_frameworks("CoreFoundation", "Foundation", "CoreVideo", "CoreMedia", "AudioToolbox", "VideoToolbox", "Security")
|
||||||
elseif is_plat("linux") then
|
elseif is_plat("linux") then
|
||||||
add_syslinks("pthread")
|
add_syslinks("pthread", "openh264")
|
||||||
end
|
end
|
||||||
|
|
||||||
if is_plat("linux", "macosx") then
|
if is_plat("linux", "macosx") then
|
||||||
|
|||||||
25
xmake.lua
25
xmake.lua
@@ -68,13 +68,20 @@ target("remote_desk")
|
|||||||
"-lxcb-shm", "-lXext", "-lX11", "-lXv", "-ldl", "-lpthread",
|
"-lxcb-shm", "-lXext", "-lX11", "-lXv", "-ldl", "-lpthread",
|
||||||
{force = true})
|
{force = true})
|
||||||
end
|
end
|
||||||
|
after_install(function (target)
|
||||||
|
os.cp("$(projectdir)/thirdparty/nvcodec/Lib/x64/*.so", "$(projectdir)/out/bin")
|
||||||
|
os.cp("$(projectdir)/thirdparty/nvcodec/Lib/x64/*.so.1", "$(projectdir)/out/bin")
|
||||||
|
os.cp("$(projectdir)/out/lib/*.so", "$(projectdir)/out/bin")
|
||||||
|
os.rm("$(projectdir)/out/include")
|
||||||
|
os.rm("$(projectdir)/out/lib")
|
||||||
|
end)
|
||||||
|
|
||||||
target("linux_capture")
|
-- target("linux_capture")
|
||||||
set_kind("binary")
|
-- set_kind("binary")
|
||||||
add_packages("sdl2", "imgui", "ffmpeg", "openh264")
|
-- add_packages("sdl2", "imgui", "ffmpeg", "openh264")
|
||||||
add_files("remote_desk_gui/linux_capture.cpp")
|
-- add_files("remote_desk_gui/linux_capture.cpp")
|
||||||
add_ldflags("-lavformat", "-lavdevice", "-lavfilter", "-lavcodec",
|
-- add_ldflags("-lavformat", "-lavdevice", "-lavfilter", "-lavcodec",
|
||||||
"-lswscale", "-lavutil", "-lswresample",
|
-- "-lswscale", "-lavutil", "-lswresample",
|
||||||
"-lasound", "-lxcb-shape", "-lxcb-xfixes", "-lsndio", "-lxcb",
|
-- "-lasound", "-lxcb-shape", "-lxcb-xfixes", "-lsndio", "-lxcb",
|
||||||
"-lxcb-shm", "-lXext", "-lX11", "-lXv", "-lpthread", "-lSDL2", "-lopenh264",
|
-- "-lxcb-shm", "-lXext", "-lX11", "-lXv", "-lpthread", "-lSDL2", "-lopenh264",
|
||||||
"-ldl" ,{force = true})
|
-- "-ldl" ,{force = true})
|
||||||
Reference in New Issue
Block a user