backports/looking-glass: new aport
This commit is contained in:
parent
863c28ebaf
commit
7cb2a35dba
4 changed files with 199 additions and 0 deletions
71
backports/looking-glass/APKBUILD
Normal file
71
backports/looking-glass/APKBUILD
Normal file
|
@ -0,0 +1,71 @@
|
||||||
|
# Contributor: Rogério da Silva Yokomizo <me@ro.ger.io>
|
||||||
|
# Maintainer: Rogério da Silva Yokomizo <me@ro.ger.io>
|
||||||
|
pkgname=looking-glass
|
||||||
|
_pkgver=B6
|
||||||
|
pkgver=6b
|
||||||
|
pkgrel=2
|
||||||
|
pkgdesc="Allows the use of a KVM configured for VGA PCI Pass-through without an attached physical monitor, keyboard or mouse"
|
||||||
|
url="https://looking-glass.io/"
|
||||||
|
arch="x86_64"
|
||||||
|
license="GPL-2.0-or-later"
|
||||||
|
makedepends="
|
||||||
|
cmake
|
||||||
|
fontconfig-dev
|
||||||
|
libsamplerate-dev
|
||||||
|
libx11-dev
|
||||||
|
libxcursor-dev
|
||||||
|
libxfixes-dev
|
||||||
|
libxi-dev
|
||||||
|
libxinerama-dev
|
||||||
|
libxkbcommon-dev
|
||||||
|
libxpresent-dev
|
||||||
|
libxscrnsaver-dev
|
||||||
|
nettle-dev
|
||||||
|
obs-studio-dev
|
||||||
|
pipewire-dev
|
||||||
|
pulseaudio-dev
|
||||||
|
samurai
|
||||||
|
spice-dev
|
||||||
|
wayland-dev
|
||||||
|
wayland-protocols
|
||||||
|
"
|
||||||
|
source="$pkgname-$_pkgver.tar.gz::https://looking-glass.io/artifact/$_pkgver/source
|
||||||
|
missing-includes.patch
|
||||||
|
obs-plugins-lib.patch
|
||||||
|
werror.patch
|
||||||
|
"
|
||||||
|
subpackages="$pkgname-obs"
|
||||||
|
builddir="$srcdir/$pkgname-$_pkgver"
|
||||||
|
options="!check" # There are no tests nor --version.
|
||||||
|
|
||||||
|
build() {
|
||||||
|
cmake -S client -B build-client -G Ninja \
|
||||||
|
-DENABLE_BACKTRACE=OFF \
|
||||||
|
-DOPTIMIZE_FOR_NATIVE=OFF \
|
||||||
|
-DCMAKE_INSTALL_PREFIX=/usr
|
||||||
|
|
||||||
|
cmake -S obs -B build-obs -G Ninja \
|
||||||
|
-DENABLE_BACKTRACE=OFF \
|
||||||
|
-DOPTIMIZE_FOR_NATIVE=OFF \
|
||||||
|
-DCMAKE_INSTALL_PREFIX=/usr
|
||||||
|
|
||||||
|
cmake --build build-client
|
||||||
|
cmake --build build-obs
|
||||||
|
}
|
||||||
|
|
||||||
|
package() {
|
||||||
|
DESTDIR="$pkgdir" cmake --install build-client
|
||||||
|
DESTDIR="$pkgdir" cmake --install build-obs
|
||||||
|
}
|
||||||
|
|
||||||
|
obs() {
|
||||||
|
pkgdesc="$pkgdesc (obs plugin)"
|
||||||
|
amove usr/lib/obs-plugins
|
||||||
|
}
|
||||||
|
|
||||||
|
sha512sums="
|
||||||
|
558981d6b32098076ef0775a748da349941551352cbef836e37310e43e5cd6072df3dec6fa2418a9abecc7729ef0c1c6869e3168d05a3d76bea46c6eb8c4e82c looking-glass-B6.tar.gz
|
||||||
|
6d2449764a8316dd3c1b5cc0aa552671068f89ed2f95297f3c5256af8529b93e5ec7af8f979bd2e744fd09b11063e8a93f3ed26284f0e49294e467ca10f6e772 missing-includes.patch
|
||||||
|
33c5463412a16691f47d7833ebf81d7cf20c560a077dca141dcc9f02a5d6dfb676e483835f39a06012b114be9f509dda4614fe253bb1c72a0142e82dc265a5ca obs-plugins-lib.patch
|
||||||
|
b952d1fd284aed15bcfe7990f160dec3a4565fb5833ce339920f62de6bb46fbc09265a0a79fe80d212eecc6a1813614e1e193a8846c37e2afd18431dc3a89ca4 werror.patch
|
||||||
|
"
|
92
backports/looking-glass/missing-includes.patch
Normal file
92
backports/looking-glass/missing-includes.patch
Normal file
|
@ -0,0 +1,92 @@
|
||||||
|
--- a/repos/PureSpice/src/agent.c
|
||||||
|
+++ b/repos/PureSpice/src/agent.c
|
||||||
|
@@ -31,6 +31,7 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
#include <unistd.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
+#include <string.h>
|
||||||
|
#include <assert.h>
|
||||||
|
|
||||||
|
#include <sys/ioctl.h>
|
||||||
|
--- a/repos/PureSpice/src/channel_cursor.c
|
||||||
|
+++ b/repos/PureSpice/src/channel_cursor.c
|
||||||
|
@@ -25,6 +25,7 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
#include "channel_cursor.h"
|
||||||
|
|
||||||
|
#include <stdlib.h>
|
||||||
|
+#include <string.h>
|
||||||
|
|
||||||
|
#include "messages.h"
|
||||||
|
|
||||||
|
--- a/repos/PureSpice/src/channel_display.c
|
||||||
|
+++ b/repos/PureSpice/src/channel_display.c
|
||||||
|
@@ -19,6 +19,7 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
|
||||||
|
#include "purespice.h"
|
||||||
|
#include <stdlib.h>
|
||||||
|
+#include <string.h>
|
||||||
|
|
||||||
|
#include "ps.h"
|
||||||
|
#include "log.h"
|
||||||
|
--- a/repos/PureSpice/src/channel_inputs.c
|
||||||
|
+++ b/repos/PureSpice/src/channel_inputs.c
|
||||||
|
@@ -25,6 +25,7 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
#include "messages.h"
|
||||||
|
|
||||||
|
#include <stdlib.h>
|
||||||
|
+#include <string.h>
|
||||||
|
|
||||||
|
const SpiceLinkHeader * channelInputs_getConnectPacket(void)
|
||||||
|
{
|
||||||
|
--- a/repos/PureSpice/src/channel_main.c
|
||||||
|
+++ b/repos/PureSpice/src/channel_main.c
|
||||||
|
@@ -24,6 +24,7 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
#include "messages.h"
|
||||||
|
|
||||||
|
#include <stdlib.h>
|
||||||
|
+#include <string.h>
|
||||||
|
|
||||||
|
struct ChannelMain
|
||||||
|
{
|
||||||
|
--- a/repos/PureSpice/src/channel_playback.c
|
||||||
|
+++ b/repos/PureSpice/src/channel_playback.c
|
||||||
|
@@ -26,6 +26,8 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
|
||||||
|
#include "messages.h"
|
||||||
|
|
||||||
|
+#include <string.h>
|
||||||
|
+
|
||||||
|
const SpiceLinkHeader * channelPlayback_getConnectPacket(void)
|
||||||
|
{
|
||||||
|
typedef struct
|
||||||
|
--- a/repos/PureSpice/src/channel_record.c
|
||||||
|
+++ b/repos/PureSpice/src/channel_record.c
|
||||||
|
@@ -26,6 +26,8 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
|
||||||
|
#include "messages.h"
|
||||||
|
|
||||||
|
+#include <string.h>
|
||||||
|
+
|
||||||
|
const SpiceLinkHeader * channelRecord_getConnectPacket(void)
|
||||||
|
{
|
||||||
|
typedef struct
|
||||||
|
--- a/repos/PureSpice/src/log.c
|
||||||
|
+++ b/repos/PureSpice/src/log.c
|
||||||
|
@@ -25,6 +25,7 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
|
||||||
|
#include <stdarg.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
+#include <string.h>
|
||||||
|
|
||||||
|
static void log_stdout(const char * file, unsigned int line,
|
||||||
|
const char * function, const char * format, ...)
|
||||||
|
--- a/repos/PureSpice/src/ps.c
|
||||||
|
+++ b/repos/PureSpice/src/ps.c
|
||||||
|
@@ -37,6 +37,7 @@ Place, Suite 330, Boston, MA 02111-1307
|
||||||
|
#include <unistd.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
+#include <string.h>
|
||||||
|
#include <assert.h>
|
||||||
|
#include <errno.h>
|
||||||
|
|
12
backports/looking-glass/obs-plugins-lib.patch
Normal file
12
backports/looking-glass/obs-plugins-lib.patch
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
--- a/obs/CMakeLists.txt
|
||||||
|
+++ b/obs/CMakeLists.txt
|
||||||
|
@@ -84,7 +84,8 @@ target_link_libraries(looking-glass-obs
|
||||||
|
)
|
||||||
|
|
||||||
|
install(TARGETS looking-glass-obs
|
||||||
|
- LIBRARY DESTINATION ${OBS_PLUGIN_PREFIX}/${CMAKE_PROJECT_NAME}/bin/${OBS_PLUGIN_DIR}
|
||||||
|
+ # LIBRARY DESTINATION ${OBS_PLUGIN_PREFIX}/${CMAKE_PROJECT_NAME}/bin/${OBS_PLUGIN_DIR}
|
||||||
|
+ LIBRARY DESTINATION /usr/lib/obs-plugins
|
||||||
|
)
|
||||||
|
|
||||||
|
feature_summary(WHAT ENABLED_FEATURES DISABLED_FEATURES)
|
24
backports/looking-glass/werror.patch
Normal file
24
backports/looking-glass/werror.patch
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
diff --git a/client/CMakeLists.txt b/client/CMakeLists.txt
|
||||||
|
index 836f814..7047365 100644
|
||||||
|
--- a/client/CMakeLists.txt
|
||||||
|
+++ b/client/CMakeLists.txt
|
||||||
|
@@ -68,7 +68,6 @@ add_compile_options(
|
||||||
|
"-Wno-unused-parameter"
|
||||||
|
"$<$<COMPILE_LANGUAGE:C>:-Wstrict-prototypes>"
|
||||||
|
"$<$<C_COMPILER_ID:GNU>:-Wimplicit-fallthrough=2>"
|
||||||
|
- "-Werror"
|
||||||
|
"-Wfatal-errors"
|
||||||
|
"-ffast-math"
|
||||||
|
"-fdata-sections"
|
||||||
|
diff --git a/obs/CMakeLists.txt b/obs/CMakeLists.txt
|
||||||
|
index 0491e65..60b37ff 100644
|
||||||
|
--- a/obs/CMakeLists.txt
|
||||||
|
+++ b/obs/CMakeLists.txt
|
||||||
|
@@ -18,7 +18,6 @@ add_feature_info(ENABLE_BACKTRACE ENABLE_BACKTRACE "Backtrace support.")
|
||||||
|
|
||||||
|
add_compile_options(
|
||||||
|
"-Wall"
|
||||||
|
- "-Werror"
|
||||||
|
"-Wfatal-errors"
|
||||||
|
"-ffast-math"
|
||||||
|
"-fdata-sections"
|
Loading…
Reference in a new issue