git: a49c9a49de9c - main - multimedia/nymphcast: 'broadcast' to your TV or speakers from the desktop

From: Adriaan de Groot <adridg_at_FreeBSD.org>
Date: Mon, 14 Feb 2022 22:18:20 UTC
The branch main has been updated by adridg:

URL: https://cgit.FreeBSD.org/ports/commit/?id=a49c9a49de9c9b180f3da58f7edce28abaeb1ea9

commit a49c9a49de9c9b180f3da58f7edce28abaeb1ea9
Author:     Adriaan de Groot <adridg@FreeBSD.org>
AuthorDate: 2022-02-05 21:06:20 +0000
Commit:     Adriaan de Groot <adridg@FreeBSD.org>
CommitDate: 2022-02-14 22:18:18 +0000

    multimedia/nymphcast: 'broadcast' to your TV or speakers from the desktop
    
    This is three ports:
    - nymphrpc (RPC library)
    - nymphcastlib (supporting library for the server and clients)
    - nymphcast (the server)
    
    There is no client for FreeBSD (yet). Use the client on Android,
    Windows, or Linux.
---
 multimedia/Makefile                                |   3 +
 multimedia/nymphcast/Makefile                      |  44 +++++++
 multimedia/nymphcast/distinfo                      |  11 ++
 multimedia/nymphcast/files/patch-Makefile          | 126 +++++++++++++++++++++
 multimedia/nymphcast/files/patch-bytebauble.h      |  10 ++
 .../files/patch-ffplay_audio__renderer.cpp         |  11 ++
 .../files/patch-ffplay_video__renderer.cpp         |  11 ++
 .../nymphcast/files/patch-lcdapi_api_LCDMutex.cpp  |  20 ++++
 .../files/patch-lcdapi_sensors_LCDSensor.cpp       |  11 ++
 .../files/patch-lcdapi_sensors_LCDSensor.h         |  17 +++
 multimedia/nymphcast/pkg-descr                     |   8 ++
 multimedia/nymphcast/pkg-plist                     |  17 +++
 multimedia/nymphcastlib/Makefile                   |  20 ++++
 multimedia/nymphcastlib/distinfo                   |   3 +
 multimedia/nymphcastlib/files/patch-Makefile       |  92 +++++++++++++++
 multimedia/nymphcastlib/pkg-descr                  |  10 ++
 multimedia/nymphcastlib/pkg-plist                  |   4 +
 multimedia/nymphrpc/Makefile                       |  18 +++
 multimedia/nymphrpc/distinfo                       |   3 +
 multimedia/nymphrpc/files/patch-Makefile           |  78 +++++++++++++
 multimedia/nymphrpc/pkg-descr                      |   9 ++
 multimedia/nymphrpc/pkg-plist                      |  19 ++++
 22 files changed, 545 insertions(+)

diff --git a/multimedia/Makefile b/multimedia/Makefile
index 563e6034aa5c..c4e01058e05a 100644
--- a/multimedia/Makefile
+++ b/multimedia/Makefile
@@ -275,6 +275,9 @@
     SUBDIR += neolink
     SUBDIR += nordlicht
     SUBDIR += nostt
+    SUBDIR += nymphcast
+    SUBDIR += nymphcastlib
+    SUBDIR += nymphrpc
     SUBDIR += obs-audio-spectralizer
     SUBDIR += obs-ndi
     SUBDIR += obs-qtwebkit
diff --git a/multimedia/nymphcast/Makefile b/multimedia/nymphcast/Makefile
new file mode 100644
index 000000000000..002d37337a11
--- /dev/null
+++ b/multimedia/nymphcast/Makefile
@@ -0,0 +1,44 @@
+PORTNAME=	NymphCast
+DISTVERSION=	v0.1-rc0
+CATEGORIES=	multimedia
+
+# -p3 because WRKSRC_SUBDIR is set; the patches are from the toplevel,
+# similarly the LICENSE_FILE lives at the toplevel of the upstream
+# source repo, outside of WRKSRC_SUBDIR.
+PATCHFILES=	e4de6983e738acff88db8c81a2e5bb0760db5855.patch:-p3 \
+		1d32a9d470dd8b6c2af5f6638b53b9a012865cc7.patch:-p3 \
+		40e8c286f7d5f37e976e655a086d5630107c7f09.patch:-p3 \
+		9e192666796bdb1913a2f965314a8cf51c2a644f.patch:-p3
+PATCH_SITES=	https://github.com/${GH_ACCOUNT}/${PORTNAME}/commit/
+
+MAINTAINER=	adridg@FreeBSD.org
+COMMENT=	Audio and video source for a television or powered speakers
+
+LICENSE=	BSD3CLAUSE
+LICENSE_FILE=	${WRKSRC}/../../LICENSE
+
+BUILD_DEPENDS=	rapidjson>=0:devel/rapidjson
+LIB_DEPENDS=	libnymphrpc.so:multimedia/nymphrpc \
+		libnymphcast.so:multimedia/nymphcastlib \
+		libasound.so:audio/alsa-lib \
+		libPocoFoundation.so:devel/poco \
+		libSDL2.so:devel/sdl20 \
+		libcurl.so:ftp/curl \
+		libfreeimage.so:graphics/freeimage \
+		libSDL2_image-2.0.so:graphics/sdl2_image \
+		libavutil.so:multimedia/ffmpeg \
+		libvlccore.so:multimedia/vlc \
+		libfreetype.so:print/freetype2
+
+USES=		compiler:c++17-lang gl gmake pkgconfig
+USE_GL=		gl
+
+USE_GITHUB=	yes
+GH_ACCOUNT=	MayaPosch
+
+WRKSRC_SUBDIR=	src/server
+
+post-extract:
+	${MV} ${WRKSRC}/version ${WRKSRC}/version.mk
+
+.include <bsd.port.mk>
diff --git a/multimedia/nymphcast/distinfo b/multimedia/nymphcast/distinfo
new file mode 100644
index 000000000000..6b6e612a7c3b
--- /dev/null
+++ b/multimedia/nymphcast/distinfo
@@ -0,0 +1,11 @@
+TIMESTAMP = 1644866502
+SHA256 (MayaPosch-NymphCast-v0.1-rc0_GH0.tar.gz) = f1b24fb7a1e33f3a6d265d88f38d3311fa52ac682f3da6723fd920d12aa8eb51
+SIZE (MayaPosch-NymphCast-v0.1-rc0_GH0.tar.gz) = 122440019
+SHA256 (e4de6983e738acff88db8c81a2e5bb0760db5855.patch) = 1f2e867df817feef5c23ddd2b17b15ee7e67664e6bedbcfac5007b8397939ace
+SIZE (e4de6983e738acff88db8c81a2e5bb0760db5855.patch) = 562
+SHA256 (1d32a9d470dd8b6c2af5f6638b53b9a012865cc7.patch) = 44b8327462c0ed85b785957e0b40792268342e20cab5092b211b449bf2bde7f7
+SIZE (1d32a9d470dd8b6c2af5f6638b53b9a012865cc7.patch) = 978
+SHA256 (40e8c286f7d5f37e976e655a086d5630107c7f09.patch) = d192afdd52b623350816583d3ceb4d2ecf624098e9a0dadd88cfce8abb3b8be7
+SIZE (40e8c286f7d5f37e976e655a086d5630107c7f09.patch) = 815
+SHA256 (9e192666796bdb1913a2f965314a8cf51c2a644f.patch) = 2cb24f1af222cd555b1e6aa9700aa1b4b841075f5cdaa1b76c40eff025c9764c
+SIZE (9e192666796bdb1913a2f965314a8cf51c2a644f.patch) = 1601
diff --git a/multimedia/nymphcast/files/patch-Makefile b/multimedia/nymphcast/files/patch-Makefile
new file mode 100644
index 000000000000..ce39d1cd8969
--- /dev/null
+++ b/multimedia/nymphcast/files/patch-Makefile
@@ -0,0 +1,126 @@
+--- Makefile.orig	2021-12-29 08:48:31 UTC
++++ Makefile
+@@ -9,7 +9,7 @@ TARGET := $(PLATFORM)
+ CROSSC := 1
+ else
+ # Get the compiler's (GCC or Clang) target triplet and use that as platform.
+-TARGET := $(shell g++ -dumpmachine)
++TARGET :=
+ $(info TARGET: $(TARGET))
+ endif
+ 
+@@ -17,8 +17,8 @@ ifdef TOOLCHAIN
+ #include Makefile.$(TARGET)
+ include toolchain/$(TOOLCHAIN).mk
+ else
+-GPP = g++
+-GCC = gcc
++GPP = c++
++GCC = cc
+ STRIP = strip
+ MAKEDIR = mkdir -p
+ RM = rm
+@@ -34,7 +34,7 @@ UMCH := $(shell uname -m)
+ TARGET_BIN := $(TARGET)/
+ 
+ # Include the file with the versioning information ('VERSION' variable).
+-include version
++include version.mk
+ VERSIONINFO = -D__VERSION="\"$(VERSION)\""
+ 
+ OUTPUT = nymphcast_server
+@@ -47,7 +47,7 @@ INCLUDE = -I . -I ffplay -I angelscript/angelscript/in
+ 			-I gui/core/nanosvg
+ ifdef CROSSC
+ INCLUDE += -I $(SYSROOT)/usr/include/SDL2 -I $(SYSROOT)/usr/include/freetype2
+-else 
++else
+ INCLUDE += `sdl2-config --cflags` \
+ 			`pkg-config --cflags freetype2`
+ endif
+@@ -55,7 +55,7 @@ endif
+ LIB := -lnymphrpc -lPocoNet -lPocoNetSSL -lPocoUtil -lPocoFoundation -lPocoJSON -lPocoData \
+ 		-lPocoDataSQLite -lswscale -lavcodec -lavdevice -lavformat -lavutil -lpostproc \
+ 		-lswresample -lavfilter -lSDL2_image -Langelscript/angelscript/lib-$(TARGET) -langelscript \
+-		-lstdc++fs -lfreetype \
++		-lfreetype \
+ 			 -lcurl -lvlc -lfreeimage \
+ 			-lnymphcast -lPocoNet -lPocoUtil -lPocoFoundation
+ ifdef CROSSC
+@@ -76,7 +76,7 @@ ifdef OS
+ 	LDFLAGS += -lws2_32 -lopengl32 -lwinmm -lole32
+ 	OUTPUT := $(OUTPUT).exe
+ else
+-	LDFLAGS += -pthread -latomic -lGL -lasound
++	LDFLAGS += -pthread -lGL -lasound
+ endif
+ 
+ # Check which version of OpenGL or OpenGL ES to use.
+@@ -157,10 +157,10 @@ makedir:
+ 	$(MAKEDIR) obj/$(TARGET_BIN)lcdapi/api
+ 	$(MAKEDIR) obj/$(TARGET_BIN)lcdapi/sensors
+ 	$(MAKEDIR) bin/$(TARGET)
+-	
++
+ angelscript:
+-	make -C angelscript/angelscript/projects/gnuc/ static
+-	
++	$(MAKE) -C angelscript/angelscript/projects/gnuc/ static
++
+ gui: $(GUI_OBJECTS)
+ 
+ obj/$(TARGET_BIN)%.o: %.cpp
+@@ -168,7 +168,7 @@ obj/$(TARGET_BIN)%.o: %.cpp
+ 
+ obj/$(TARGET_BIN)%.o: %.c
+ 	$(GCC) -c -o $@ $< -g3 $(CFLAGS)
+-	
++
+ bin/$(TARGET_BIN)$(OUTPUT): angelscript $(OBJECTS) $(C_OBJECTS) $(GUI_OBJECTS)
+ 	$(GPP) -o $@ $(OBJECTS) $(GUI_OBJECTS) $(C_OBJECTS) $(LDFLAGS)
+ 	cp $@ $@.debug
+@@ -178,15 +178,15 @@ clean: clean-objects clean-angelscript clean-gui
+ 
+ clean-objects:
+ 	$(RM) $(OBJECTS) $(C_OBJECTS)
+-	
++
+ clean-angelscript:
+-	make -C angelscript/angelscript/projects/gnuc/ clean
+-	
++	$(MAKE) -C angelscript/angelscript/projects/gnuc/ clean
++
+ clean-gui:
+ 	$(RM) $(GUI_OBJECTS)
+-	
++
+ .PHONY: all clean angelscript makedir gui
+-	
++
+ .PHONY: install
+ install:
+ 	install -d $(DESTDIR)$(PREFIX)/bin/ \
+@@ -201,12 +201,12 @@ install:
+ 
+ .PHONY: install-systemd
+ install-systemd:
+-	#install -d $(DESTDIR)$(CONFDIR)/systemd/system/ 
++	#install -d $(DESTDIR)$(CONFDIR)/systemd/system/
+ 	sed ${SED_REPLACE} systemd/nymphcast.service > /etc/systemd/system/nymphcast.service
+ 
+ .PHONY: install-openrc
+ install-openrc:
+-	install -d $(DESTDIR)$(CONFDIR)/init.d/	
++	install -d $(DESTDIR)$(CONFDIR)/init.d/
+ 	sed ${SED_REPLACE} openrc/nymphcast > $(DESTDIR)$(CONFDIR)/init.d/nymphcast
+ 	chmod 0755 $(DESTDIR)$(CONFDIR)/init.d/nymphcast
+ 
+@@ -227,7 +227,7 @@ ar-rasp-full: bin/$(TARGET_BIN)$(OUTPUT)
+ 	cp -r wallpapers/ out/tmp/payload/usr/local/share/nymphcast/.
+ 	#tar -cvJf out/nymphcast_raspbian.xz -C out/tmp/ .
+ 	cd out/tmp && zip --symlinks -vr ../nymphcast_raspbian.zip . && cd -
+-	
++
+ ar-rasp-audio: bin/$(TARGET_BIN)$(OUTPUT)
+ 	rm -rf out/tmp
+ 	rm -f out/nymphcast_audio_raspbian.zip
diff --git a/multimedia/nymphcast/files/patch-bytebauble.h b/multimedia/nymphcast/files/patch-bytebauble.h
new file mode 100644
index 000000000000..61b3bffb634e
--- /dev/null
+++ b/multimedia/nymphcast/files/patch-bytebauble.h
@@ -0,0 +1,10 @@
+--- bytebauble.h.orig	2022-02-05 21:38:24 UTC
++++ bytebauble.h
+@@ -19,6 +19,7 @@
+ 
+ #include <climits>
+ #include <cstdint>
++#include <cstddef>
+ 
+ #ifdef _MSC_VER
+ #include <stdlib.h>
diff --git a/multimedia/nymphcast/files/patch-ffplay_audio__renderer.cpp b/multimedia/nymphcast/files/patch-ffplay_audio__renderer.cpp
new file mode 100644
index 000000000000..e46d4eefac9c
--- /dev/null
+++ b/multimedia/nymphcast/files/patch-ffplay_audio__renderer.cpp
@@ -0,0 +1,11 @@
+--- ffplay/audio_renderer.cpp.orig	2022-02-05 21:39:05 UTC
++++ ffplay/audio_renderer.cpp
+@@ -149,7 +149,7 @@ int AudioRenderer::configure_audio_filters(VideoState 
+                    1, is->audio_filter_src.freq);
+     if (is->audio_filter_src.channel_layout)
+         snprintf(asrc_args + ret, sizeof(asrc_args) - ret,
+-                 ":channel_layout=0x%"PRIx64,  is->audio_filter_src.channel_layout);
++                 ":channel_layout=0x%" PRIx64,  is->audio_filter_src.channel_layout);
+ 
+     ret = avfilter_graph_create_filter(&filt_asrc,
+                                        avfilter_get_by_name("abuffer"), "ffplay_abuffer",
diff --git a/multimedia/nymphcast/files/patch-ffplay_video__renderer.cpp b/multimedia/nymphcast/files/patch-ffplay_video__renderer.cpp
new file mode 100644
index 000000000000..9660ca48d947
--- /dev/null
+++ b/multimedia/nymphcast/files/patch-ffplay_video__renderer.cpp
@@ -0,0 +1,11 @@
+--- ffplay/video_renderer.cpp.orig	2022-02-05 21:45:21 UTC
++++ ffplay/video_renderer.cpp
+@@ -204,7 +204,7 @@ display:
+ 			//FileMetaInfo::position = master_clock;	// Copy to FleMetaInfo structure for the current file.
+ 			FileMetaInfo::setPosition(master_clock);
+             av_log(NULL, AV_LOG_INFO,
+-                   "%7.2f %s:%7.3f fd=%4d aq=%5dKB vq=%5dKB sq=%5dB f=%"PRId64"/%"PRId64"   \r",
++                   "%7.2f %s:%7.3f fd=%4d aq=%5dKB vq=%5dKB sq=%5dB f=%" PRId64 "/%" PRId64 "   \r",
+                    master_clock,
+                    (is->audio_st && is->video_st) ? "A-V" : (is->video_st ? "M-V" : (is->audio_st ? "M-A" : "   ")),
+                    av_diff,
diff --git a/multimedia/nymphcast/files/patch-lcdapi_api_LCDMutex.cpp b/multimedia/nymphcast/files/patch-lcdapi_api_LCDMutex.cpp
new file mode 100644
index 000000000000..68776a771cd1
--- /dev/null
+++ b/multimedia/nymphcast/files/patch-lcdapi_api_LCDMutex.cpp
@@ -0,0 +1,20 @@
+--- lcdapi/api/LCDMutex.cpp.orig	2022-02-05 21:50:30 UTC
++++ lcdapi/api/LCDMutex.cpp
+@@ -22,7 +22,7 @@ namespace lcdapi {
+ 
+ using namespace std;
+ 
+-LCDMutex::LCDMutex() : _mutex(), _owner(static_cast<pthread_t>(-1)) {
++LCDMutex::LCDMutex() : _mutex(), _owner(nullptr) {
+   ::pthread_mutex_init(&_mutex, 0);
+ }
+ 
+@@ -38,7 +38,7 @@ void LCDMutex::lock() {
+ }
+ 
+ void LCDMutex::unlock() {
+-  _owner = static_cast<pthread_t>(-1);
++  _owner = nullptr;
+   ::pthread_mutex_unlock(&_mutex);
+ }
+ 
diff --git a/multimedia/nymphcast/files/patch-lcdapi_sensors_LCDSensor.cpp b/multimedia/nymphcast/files/patch-lcdapi_sensors_LCDSensor.cpp
new file mode 100644
index 000000000000..5eb551b58b91
--- /dev/null
+++ b/multimedia/nymphcast/files/patch-lcdapi_sensors_LCDSensor.cpp
@@ -0,0 +1,11 @@
+--- lcdapi/sensors/LCDSensor.cpp.orig	2022-02-05 21:52:04 UTC
++++ lcdapi/sensors/LCDSensor.cpp
+@@ -36,7 +36,7 @@ const int LCDSensor::MAX_CMD_RESULT_LINE_SIZE = 255;
+ LCDSensor::LCDSensor()
+   : _exist(true),
+     _onChangeThreadStarted(false),
+-    _onChangeThread(static_cast<pthread_t>(-1)),
++    _onChangeThread(nullptr),
+     _onChangeList(),
+     _onTimeOutList()
+ {
diff --git a/multimedia/nymphcast/files/patch-lcdapi_sensors_LCDSensor.h b/multimedia/nymphcast/files/patch-lcdapi_sensors_LCDSensor.h
new file mode 100644
index 000000000000..3035e1e5b931
--- /dev/null
+++ b/multimedia/nymphcast/files/patch-lcdapi_sensors_LCDSensor.h
@@ -0,0 +1,17 @@
+--- lcdapi/sensors/LCDSensor.h.orig	2022-02-05 21:39:20 UTC
++++ lcdapi/sensors/LCDSensor.h
+@@ -53,12 +53,12 @@ class LCDWidgetTimeOut {
+ 
+  LCDWidgetTimeOut()
+     : _widgetId(), _timeOut(0), _widget(NULL),
+-    _thread(static_cast<pthread_t>(-1))
++    _thread(nullptr)
+   {
+   }
+ 
+   bool isValid() {
+-    return (_thread != static_cast<pthread_t>(-1));
++    return (_thread != nullptr);
+   }
+ 
+   const LCDWidgetTimeOut& operator=(const LCDWidgetTimeOut& rhs) {
diff --git a/multimedia/nymphcast/pkg-descr b/multimedia/nymphcast/pkg-descr
new file mode 100644
index 000000000000..9c61d4845087
--- /dev/null
+++ b/multimedia/nymphcast/pkg-descr
@@ -0,0 +1,8 @@
+NymphCast is a software solution which turns your choice of
+FreeBSD-capable hardware into an audio and video source for a
+television or powered speakers. It enables the streaming of audio
+and video over the network from a wide range of client devices,
+as well as the streaming of internet media to a NymphCast server,
+controlled by a client device, or directly on the receiver.
+
+WWW: http://nyanko.ws/nymphcast.php
diff --git a/multimedia/nymphcast/pkg-plist b/multimedia/nymphcast/pkg-plist
new file mode 100644
index 000000000000..702c14b9e576
--- /dev/null
+++ b/multimedia/nymphcast/pkg-plist
@@ -0,0 +1,17 @@
+bin/nymphcast_server
+etc/nymphcast/nymphcast_audio_config.ini
+etc/nymphcast/nymphcast_config.ini
+etc/nymphcast/nymphcast_gui_config.ini
+etc/nymphcast/nymphcast_screensaver_config.ini
+etc/nymphcast/nymphcast_video_config.ini
+share/nymphcast/apps/apps.html
+share/nymphcast/apps/apps.ini
+share/nymphcast/apps/hellocast/hellocast.as
+share/nymphcast/apps/hellocast/index.html
+share/nymphcast/apps/hellocast/logo.jpg
+share/nymphcast/apps/hellocast/logo_large.jpg
+share/nymphcast/apps/soundcloud/logo.png
+share/nymphcast/apps/soundcloud/soundcloud.as
+share/nymphcast/wallpapers/forest_brook.jpg
+share/nymphcast/wallpapers/green.jpg
+@dir etc/avahi/services
diff --git a/multimedia/nymphcastlib/Makefile b/multimedia/nymphcastlib/Makefile
new file mode 100644
index 000000000000..e1d5ca389cb7
--- /dev/null
+++ b/multimedia/nymphcastlib/Makefile
@@ -0,0 +1,20 @@
+PORTNAME=	NymphCastLib
+DISTVERSION=	v0.1-beta0
+CATEGORIES=	multimedia
+
+MAINTAINER=	adridg@FreeBSD.org
+COMMENT=	Core functionality for a NymphCast client
+
+LICENSE=	BSD3CLAUSE
+LICENSE_FILE=	${WRKSRC}/LICENSE
+
+LIB_DEPENDS=	libnymphrpc.so:multimedia/nymphrpc \
+		libPocoNet.so:devel/poco
+
+USES=		compiler:c++17-lang gmake
+
+USE_GITHUB=	yes
+GH_ACCOUNT=	MayaPosch
+GH_PROJECT=	libnymphcast
+
+.include <bsd.port.mk>
diff --git a/multimedia/nymphcastlib/distinfo b/multimedia/nymphcastlib/distinfo
new file mode 100644
index 000000000000..2d3bf47bdf92
--- /dev/null
+++ b/multimedia/nymphcastlib/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1643981378
+SHA256 (MayaPosch-libnymphcast-v0.1-beta0_GH0.tar.gz) = 319a6666693b93851a1ef2c73e2967d2be833fa7ea3b486915b434d6c8672d9d
+SIZE (MayaPosch-libnymphcast-v0.1-beta0_GH0.tar.gz) = 206661
diff --git a/multimedia/nymphcastlib/files/patch-Makefile b/multimedia/nymphcastlib/files/patch-Makefile
new file mode 100644
index 000000000000..c839722e93a0
--- /dev/null
+++ b/multimedia/nymphcastlib/files/patch-Makefile
@@ -0,0 +1,92 @@
+--- Makefile.orig	2021-12-25 18:20:11 UTC
++++ Makefile
+@@ -6,6 +6,9 @@
+ 
+ export TOP := $(CURDIR)
+ 
++CXX ?= c++
++ARCH =
++
+ ifndef ANDROID_ABI_LEVEL
+ ANDROID_ABI_LEVEL := 21
+ endif
+@@ -30,10 +33,6 @@ TOOLCHAIN_POSTFIX := .cmd
+ endif
+ endif
+ 
+-ifndef ARCH
+-ARCH := $(shell g++ -dumpmachine)/
+-endif
+-
+ USYS := $(shell uname -s)
+ UMCH := $(shell uname -m)
+ 
+@@ -59,7 +58,7 @@ MAKEDIR = mkdir -p
+ RM = rm
+ AR = ar 
+ else
+-GCC = g++
++GCC = $(CXX)
+ MAKEDIR = mkdir -p
+ RM = rm
+ AR = ar
+@@ -76,11 +75,11 @@ ifeq ($(shell uname -s),Darwin)
+ 	LIBNAME = $(OUTPUT).0.dylib
+ endif
+ 
+-INCLUDE := -I src
++INCLUDE := -I src -I /usr/local/include
+ LIBS := -lnymphrpc -lPocoNet -lPocoUtil -lPocoFoundation -lPocoJSON 
+ #-lstdc++fs
+ CFLAGS := $(INCLUDE) -g3 -std=c++17 -O0
+-SHARED_FLAGS := -fPIC -shared -Wl,$(SONAME),$(LIBNAME)
++SHARED_FLAGS := -fPIC -shared -Wl,$(SONAME),$(LIBNAME) -L /usr/local/lib
+ 
+ ifdef ANDROID
+ CFLAGS += -fPIC
+@@ -109,9 +108,10 @@ SOURCES := $(wildcard src/*.cpp)
+ OBJECTS := $(addprefix obj/static/$(ARCH),$(notdir) $(SOURCES:.cpp=.o))
+ SHARED_OBJECTS := $(addprefix obj/shared/$(ARCH),$(notdir) $(SOURCES:.cpp=.o))
+ 
+-all: lib
++all: makedir
++	$(MAKE) lib
+ 
+-lib: makedir lib/$(ARCH)$(OUTPUT).a lib/$(ARCH)$(LIBNAME)
++lib: makedir lib/$(OUTPUT).a lib/$(LIBNAME)
+ 	
+ obj/static/$(ARCH)%.o: %.cpp
+ 	$(GCC) -c -o $@ $< $(CFLAGS)
+@@ -119,11 +119,11 @@ obj/static/$(ARCH)%.o: %.cpp
+ obj/shared/$(ARCH)%.o: %.cpp
+ 	$(GCC) -c -o $@ $< $(CFLAGS) $(SHARED_FLAGS) $(LIBS)
+ 	
+-lib/$(ARCH)$(OUTPUT).a: $(OBJECTS)
++lib/$(OUTPUT).a: $(OBJECTS)
+ 	-rm -f $@
+ 	$(AR) rcs $@ $^
+ 	
+-lib/$(ARCH)$(LIBNAME): $(SHARED_OBJECTS)
++lib/$(LIBNAME): $(SHARED_OBJECTS)
+ 	$(GCC) -o $@ $(CFLAGS) $(SHARED_FLAGS) $(SHARED_OBJECTS) $(LIBS)
+ 	
+ makedir:
+@@ -168,9 +168,9 @@ endif
+ .PHONY: install
+ install:
+ 	install -d $(DESTDIR)$(PREFIX)/lib
+-	install -m 644 lib/$(ARCH)$(OUTPUT).a $(DESTDIR)$(PREFIX)/lib/
++	install -m 644 lib/$(OUTPUT).a $(DESTDIR)$(PREFIX)/lib/
+ ifndef OS
+-	install -m 644 lib/$(ARCH)$(OUTPUT).so.$(VERSION) $(DESTDIR)$(PREFIX)/lib
++	install -m 644 lib/$(OUTPUT).so.$(VERSION) $(DESTDIR)$(PREFIX)/lib
+ endif
+ 	install -d $(DESTDIR)$(PREFIX)/include
+ 	install -m 644 src/nymphcast_client.h $(DESTDIR)$(PREFIX)/include/
+@@ -183,4 +183,4 @@ ifndef OS
+ endif
+ 
+ package:
+-	tar -C lib/$(ARCH) -cvzf lib/$(OUTPUT)-$(VERSION)-$(USYS)-$(UMCH).tar.gz $(OUTPUT).a $(OUTPUT).so.$(VERSION)
+\ No newline at end of file
++	tar -C lib/$(ARCH) -cvzf lib/$(OUTPUT)-$(VERSION)-$(USYS)-$(UMCH).tar.gz $(OUTPUT).a $(OUTPUT).so.$(VERSION)
diff --git a/multimedia/nymphcastlib/pkg-descr b/multimedia/nymphcastlib/pkg-descr
new file mode 100644
index 000000000000..446adef62c86
--- /dev/null
+++ b/multimedia/nymphcastlib/pkg-descr
@@ -0,0 +1,10 @@
+Libnymphcast is a library containing the core functionality for a NymphCast
+client. This includes:
+
+- Streaming media files to a remote NymphCast receiver.
+- Sending a URL to a media file to a NymphCast receiver to initiate playback.
+- Communication with remote NymphCast Apps.
+- Multi-casting media content.
+- Interact with NymphCast MediaServers.
+
+WWW: https://github.com/MayaPosch/libnymphcast
diff --git a/multimedia/nymphcastlib/pkg-plist b/multimedia/nymphcastlib/pkg-plist
new file mode 100644
index 000000000000..a79a77b00558
--- /dev/null
+++ b/multimedia/nymphcastlib/pkg-plist
@@ -0,0 +1,4 @@
+include/nymphcast_client.h
+lib/libnymphcast.a
+lib/libnymphcast.so.0.1
+lib/libnymphcast.so
diff --git a/multimedia/nymphrpc/Makefile b/multimedia/nymphrpc/Makefile
new file mode 100644
index 000000000000..f36c8dd07393
--- /dev/null
+++ b/multimedia/nymphrpc/Makefile
@@ -0,0 +1,18 @@
+PORTNAME=	NymphRPC
+DISTVERSION=	v0.1-alpha1
+CATEGORIES=	multimedia devel
+
+MAINTAINER=	adridg@FreeBSD.org
+COMMENT=	Compact, C++-based Remote Procedure Call (RPC) library
+
+LICENSE=	BSD3CLAUSE
+LICENSE_FILE=	${WRKSRC}/LICENSE
+
+LIB_DEPENDS=	libPocoNet.so:devel/poco
+
+USES=		compiler:c++17-lang gmake
+
+USE_GITHUB=	yes
+GH_ACCOUNT=	MayaPosch
+
+.include <bsd.port.mk>
diff --git a/multimedia/nymphrpc/distinfo b/multimedia/nymphrpc/distinfo
new file mode 100644
index 000000000000..0b9d5b8bf1ba
--- /dev/null
+++ b/multimedia/nymphrpc/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1643980281
+SHA256 (MayaPosch-NymphRPC-v0.1-alpha1_GH0.tar.gz) = e002829eabc75e2db061d301a0102ff982e2917cbc119f68f05b02e1ad168844
+SIZE (MayaPosch-NymphRPC-v0.1-alpha1_GH0.tar.gz) = 14119499
diff --git a/multimedia/nymphrpc/files/patch-Makefile b/multimedia/nymphrpc/files/patch-Makefile
new file mode 100644
index 000000000000..660f7f7da65f
--- /dev/null
+++ b/multimedia/nymphrpc/files/patch-Makefile
@@ -0,0 +1,78 @@
+--- Makefile.orig	2021-12-16 10:20:49 UTC
++++ Makefile
+@@ -7,6 +7,8 @@
+ 
+ export TOP := $(CURDIR)
+ 
++CXX ?= g++
++
+ ifndef ANDROID_ABI_LEVEL
+ ANDROID_ABI_LEVEL := 21
+ endif
+@@ -31,9 +33,7 @@ TOOLCHAIN_POSTFIX := .cmd
+ endif
+ endif
+ 
+-ifndef ARCH
+-ARCH := $(shell g++ -dumpmachine)/
+-endif
++ARCH :=
+ 
+ USYS := $(shell uname -s)
+ UMCH := $(shell uname -m)
+@@ -60,7 +60,7 @@ MAKEDIR = mkdir -p
+ RM = rm
+ AR = ar 
+ else
+-GCC = g++
++GCC = $(CXX)
+ MAKEDIR = mkdir -p
+ RM = rm
+ AR = ar
+@@ -81,9 +81,10 @@ endif
+ 
+ 
+ INCLUDE = -I src
++INCLUDE += -I /usr/local/include
+ LIBS := -lPocoNet -lPocoUtil -lPocoFoundation -lPocoJSON 
+ CFLAGS := $(INCLUDE) -g3 -std=c++11 -O0
+-SHARED_FLAGS := -fPIC -shared -Wl,$(SONAME),$(LIBNAME)
++SHARED_FLAGS := -fPIC -shared -Wl,$(SONAME),$(LIBNAME) -L /usr/local/lib
+ 
+ ifdef ANDROID
+ CFLAGS += -fPIC
+@@ -115,7 +116,7 @@ SHARED_OBJECTS := $(addprefix obj/shared/$(ARCH),$(not
+ 
+ all: lib
+ 
+-lib: makedir lib/$(ARCH)$(OUTPUT).a lib/$(ARCH)$(LIBNAME)
++lib: makedir lib/$(OUTPUT).a lib/$(LIBNAME)
+ 	
+ obj/static/$(ARCH)%.o: %.cpp
+ 	$(GCC) -c -o $@ $< $(CFLAGS)
+@@ -123,11 +124,11 @@ obj/static/$(ARCH)%.o: %.cpp
+ obj/shared/$(ARCH)%.o: %.cpp
+ 	$(GCC) -c -o $@ $< $(SHARED_FLAGS) $(CFLAGS) $(LIBS)
+ 	
+-lib/$(ARCH)$(OUTPUT).a: $(OBJECTS)
++lib/$(OUTPUT).a: $(OBJECTS)
+ 	-rm -f $@
+ 	$(AR) rcs $@ $^
+ 	
+-lib/$(ARCH)$(LIBNAME): $(SHARED_OBJECTS)
++lib/$(LIBNAME): $(SHARED_OBJECTS)
+ 	$(GCC) -o $@ $(CFLAGS) $(SHARED_FLAGS) $(SHARED_OBJECTS) $(LIBS)
+ 	
+ makedir:
+@@ -165,9 +166,9 @@ endif
+ .PHONY: install
+ install:
+ 	install -d $(DESTDIR)$(PREFIX)/lib/
+-	install -m 644 lib/$(ARCH)$(OUTPUT).a $(DESTDIR)$(PREFIX)/lib/
++	install -m 644 lib/$(OUTPUT).a $(DESTDIR)$(PREFIX)/lib/
+ ifndef OS
+-	install -m 644 lib/$(ARCH)$(OUTPUT).so.$(VERSION) $(DESTDIR)$(PREFIX)/lib/
++	install -m 644 lib/$(OUTPUT).so.$(VERSION) $(DESTDIR)$(PREFIX)/lib/
+ endif
+ 	install -d $(DESTDIR)$(PREFIX)/include/nymph
+ 	install -m 644 src/*.h $(DESTDIR)$(PREFIX)/include/nymph/
diff --git a/multimedia/nymphrpc/pkg-descr b/multimedia/nymphrpc/pkg-descr
new file mode 100644
index 000000000000..9f9d64e8386b
--- /dev/null
+++ b/multimedia/nymphrpc/pkg-descr
@@ -0,0 +1,9 @@
+NymphRPC is a compact, C++-based Remote Procedure Call (RPC) library.
+Look at the example server and client implementations in the test folder
+to get an idea of how NymphRPC is integrated into an application.
+
+The basic procedure is to define the RPC methods and client-side callbacks
+in the server, which the client will synchronise with when it connects to
+the server. There is no Domain-Specific Language (DSL) or auto-generated code.
+
+WWW: https://github.com/MayaPosch/NymphRPC
diff --git a/multimedia/nymphrpc/pkg-plist b/multimedia/nymphrpc/pkg-plist
new file mode 100644
index 000000000000..26f6340a72bc
--- /dev/null
+++ b/multimedia/nymphrpc/pkg-plist
@@ -0,0 +1,19 @@
+include/nymph/abstract_request.h
+include/nymph/callback_request.h
+include/nymph/dispatcher.h
+include/nymph/nymph.h
+include/nymph/nymph_listener.h
+include/nymph/nymph_logger.h
+include/nymph/nymph_message.h
+include/nymph/nymph_method.h
+include/nymph/nymph_server.h
+include/nymph/nymph_session.h
+include/nymph/nymph_socket_listener.h
+include/nymph/nymph_types.h
+include/nymph/nymph_utilities.h
+include/nymph/remote_client.h
+include/nymph/remote_server.h
+include/nymph/worker.h
+lib/libnymphrpc.a
+lib/libnymphrpc.so.0.1
+lib/libnymphrpc.so