aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuido Falsi <madpilot@FreeBSD.org>2023-11-03 19:14:57 +0000
committerGuido Falsi <madpilot@FreeBSD.org>2023-11-03 19:14:57 +0000
commit7d637bf4782a4ac613492bd6ed16a8b49d68a721 (patch)
treecaa0c6694c73772ffe351d595d2ad9ec279d8bea
parent5d6d9d4aba10aad6319e4d9fb1afdecb3da6b9fa (diff)
downloadports-7d637bf4782a4ac613492bd6ed16a8b49d68a721.tar.gz
ports-7d637bf4782a4ac613492bd6ed16a8b49d68a721.zip
multimedia/fswebcam: Command line tool for webcams
fswebcam captures images from a V4L1/V4L2 compatible device or file, averages them to reduce noise and draws a caption using the GD Graphics Library which also handles compressing the image to PNG or JPEG. Works fine with webcams supported by multimedia/webcamd.
-rw-r--r--multimedia/Makefile1
-rw-r--r--multimedia/fswebcam/Makefile24
-rw-r--r--multimedia/fswebcam/distinfo3
-rw-r--r--multimedia/fswebcam/files/patch-Makefile.in13
-rw-r--r--multimedia/fswebcam/files/patch-videodev.h13
-rw-r--r--multimedia/fswebcam/files/patch-videodev2.h12
-rw-r--r--multimedia/fswebcam/pkg-descr6
7 files changed, 72 insertions, 0 deletions
diff --git a/multimedia/Makefile b/multimedia/Makefile
index 5bb15b628f23..ed68e81a9acf 100644
--- a/multimedia/Makefile
+++ b/multimedia/Makefile
@@ -70,6 +70,7 @@
SUBDIR += flvtool++
SUBDIR += fpc-dts
SUBDIR += fpc-libvlc
+ SUBDIR += fswebcam
SUBDIR += fxtv
SUBDIR += gaupol
SUBDIR += gavl
diff --git a/multimedia/fswebcam/Makefile b/multimedia/fswebcam/Makefile
new file mode 100644
index 000000000000..ca640e247620
--- /dev/null
+++ b/multimedia/fswebcam/Makefile
@@ -0,0 +1,24 @@
+PORTNAME= fswebcam
+PORTVERSION= 20200725
+CATEGORIES= multimedia
+
+MAINTAINER= madpilot@FreeBSD.org
+COMMENT= Small and simple webcam software for *nix
+WWW= https://www.sanslogic.co.uk/fswebcam/
+
+LICENSE= GPLv2
+LICENSE_FILE= ${WRKSRC}/LICENSE
+
+BUILD_DEPENDS= v4l_compat>0:multimedia/v4l_compat
+LIB_DEPENDS= libgd.so:graphics/gd \
+ libv4l2.so:multimedia/libv4l
+
+USES= localbase:ldflags
+USE_GITHUB= yes
+GH_ACCOUNT= fsphil
+GNU_CONFIGURE= yes
+
+PLIST_FILES= bin/fswebcam \
+ man/man1/fswebcam.1.gz
+
+.include <bsd.port.mk>
diff --git a/multimedia/fswebcam/distinfo b/multimedia/fswebcam/distinfo
new file mode 100644
index 000000000000..5a26bdceae0e
--- /dev/null
+++ b/multimedia/fswebcam/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1698870800
+SHA256 (fsphil-fswebcam-20200725_GH0.tar.gz) = d5439b2bf49bb634100d7e42ed9854f84bfd355c1d40bc3d4d81593eeadd8aee
+SIZE (fsphil-fswebcam-20200725_GH0.tar.gz) = 119399
diff --git a/multimedia/fswebcam/files/patch-Makefile.in b/multimedia/fswebcam/files/patch-Makefile.in
new file mode 100644
index 000000000000..3d02b9496e1a
--- /dev/null
+++ b/multimedia/fswebcam/files/patch-Makefile.in
@@ -0,0 +1,13 @@
+--- Makefile.in.orig 2020-07-25 18:25:51 UTC
++++ Makefile.in
+@@ -22,8 +22,8 @@ install: all
+ install: all
+ mkdir -p ${DESTDIR}${bindir}
+ mkdir -p ${DESTDIR}${mandir}/man1
+- install -m 755 fswebcam ${DESTDIR}${bindir}
+- install -m 644 fswebcam.1.gz ${DESTDIR}${mandir}/man1
++ ${BSD_INSTALL_PROGRAM} fswebcam ${DESTDIR}${bindir}
++ ${BSD_INSTALL_MAN} fswebcam.1.gz ${DESTDIR}${mandir}/man1
+
+ fswebcam: $(OBJS)
+ $(CC) -o fswebcam $(OBJS) $(LDFLAGS)
diff --git a/multimedia/fswebcam/files/patch-videodev.h b/multimedia/fswebcam/files/patch-videodev.h
new file mode 100644
index 000000000000..129210db5651
--- /dev/null
+++ b/multimedia/fswebcam/files/patch-videodev.h
@@ -0,0 +1,13 @@
+--- videodev.h.orig 2020-07-25 18:25:51 UTC
++++ videodev.h
+@@ -12,8 +12,9 @@
+ #ifndef __LINUX_VIDEODEV_H
+ #define __LINUX_VIDEODEV_H
+
++#include <infiniband/types.h>
+ #include <linux/types.h>
+-#include <linux/ioctl.h>
++/* #include <linux/ioctl.h> */
+ #include <linux/videodev2.h>
+
+
diff --git a/multimedia/fswebcam/files/patch-videodev2.h b/multimedia/fswebcam/files/patch-videodev2.h
new file mode 100644
index 000000000000..e0b7aeb5eb84
--- /dev/null
+++ b/multimedia/fswebcam/files/patch-videodev2.h
@@ -0,0 +1,12 @@
+--- videodev2.h.orig 2020-07-25 18:25:51 UTC
++++ videodev2.h
+@@ -59,7 +59,8 @@
+
+ #include <sys/time.h>
+
+-#include <linux/ioctl.h>
++/* #include <linux/ioctl.h> */
++#include <infiniband/types.h>
+ #include <linux/types.h>
+ #include <linux/v4l2-common.h>
+ #include <linux/v4l2-controls.h>
diff --git a/multimedia/fswebcam/pkg-descr b/multimedia/fswebcam/pkg-descr
new file mode 100644
index 000000000000..f89dd7c57286
--- /dev/null
+++ b/multimedia/fswebcam/pkg-descr
@@ -0,0 +1,6 @@
+fswebcam is a neat and simple webcam app. It captures images from
+a V4L1/V4L2 compatible device or file, averages them to reduce noise
+and draws a caption using the GD Graphics Library which also handles
+compressing the image to PNG or JPEG. The resulting image is saved
+to a file or sent to stdio where it can be piped to something like
+ncftpput or scp.