diff --git a/build.sh b/build.sh index 591728b..317340b 100755 --- a/build.sh +++ b/build.sh @@ -5,7 +5,7 @@ build_gsr_kms_server() { includes="$(pkg-config --cflags $dependencies)" libs="$(pkg-config --libs $dependencies) -ldl" opts="-O2 -g0 -DNDEBUG" - gcc -c src/kms/kms_server.c $opts $includes + gcc -c kms/server/kms_server.c $opts $includes gcc -o gsr-kms-server -O2 kms_server.o -s $libs } @@ -19,7 +19,7 @@ build_gsr() { gcc -c src/capture/xcomposite_cuda.c $opts $includes gcc -c src/capture/xcomposite_vaapi.c $opts $includes gcc -c src/capture/kms_vaapi.c $opts $includes - gcc -c src/kms/kms_client.c $opts $includes + gcc -c kms/client/kms_client.c $opts $includes gcc -c src/egl.c $opts $includes gcc -c src/cuda.c $opts $includes gcc -c src/xnvctrl.c $opts $includes diff --git a/src/kms/kms_client.c b/kms/client/kms_client.c similarity index 99% rename from src/kms/kms_client.c rename to kms/client/kms_client.c index cddd8ff..2b59836 100644 --- a/src/kms/kms_client.c +++ b/kms/client/kms_client.c @@ -1,4 +1,4 @@ -#include "../../include/kms/kms_client.h" +#include "kms_client.h" #include #include #include diff --git a/include/kms/kms_client.h b/kms/client/kms_client.h similarity index 95% rename from include/kms/kms_client.h rename to kms/client/kms_client.h index bb4325b..59d3cb3 100644 --- a/include/kms/kms_client.h +++ b/kms/client/kms_client.h @@ -1,7 +1,7 @@ #ifndef GSR_KMS_CLIENT_H #define GSR_KMS_CLIENT_H -#include "kms_shared.h" +#include "../kms_shared.h" #include typedef struct { diff --git a/include/kms/kms_shared.h b/kms/kms_shared.h similarity index 100% rename from include/kms/kms_shared.h rename to kms/kms_shared.h diff --git a/kms/server/.gitignore b/kms/server/.gitignore new file mode 100644 index 0000000..97420ef --- /dev/null +++ b/kms/server/.gitignore @@ -0,0 +1 @@ +sibs-build/ diff --git a/src/kms/kms_server.c b/kms/server/kms_server.c similarity index 99% rename from src/kms/kms_server.c rename to kms/server/kms_server.c index e7ee02f..73cf9d0 100644 --- a/src/kms/kms_server.c +++ b/kms/server/kms_server.c @@ -1,4 +1,4 @@ -#include "../../include/kms/kms_shared.h" +#include "../kms_shared.h" #include #include diff --git a/kms/server/project.conf b/kms/server/project.conf new file mode 100644 index 0000000..cf863c1 --- /dev/null +++ b/kms/server/project.conf @@ -0,0 +1,8 @@ +[package] +name = "gsr-kms-server" +type = "executable" +version = "1.0.0" +platforms = ["posix"] + +[dependencies] +libdrm = ">=2" diff --git a/project.conf b/project.conf index 3e39072..231ca5d 100644 --- a/project.conf +++ b/project.conf @@ -5,7 +5,7 @@ version = "2.0.0" platforms = ["posix"] [config] -ignore_dirs = ["src/kms"] +ignore_dirs = ["kms/server"] [dependencies] libavcodec = ">=58" diff --git a/src/capture/kms_vaapi.c b/src/capture/kms_vaapi.c index 7e42011..2e970a3 100644 --- a/src/capture/kms_vaapi.c +++ b/src/capture/kms_vaapi.c @@ -1,5 +1,5 @@ #include "../../include/capture/kms_vaapi.h" -#include "../../include/kms/kms_client.h" +#include "../../kms/client/kms_client.h" #include "../../include/egl.h" #include "../../include/utils.h" #include