1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-18 00:10:04 +00:00

multimedia/obuparse: Add Port: Portable single file AV1 OBU parser

Simple and portable single file AV1 OBU parser

Features:

*  No allocations; only works on user-provided buffers and the stack.
*  OBU header parsing.
*  Sequence Header OBU parsing.
*  Metadata OBU parsing.
*  Tile List OBU parsing.
*  Tile Group OBU parsing.
*  Frame Header OBU parsing.
*  Frame OBU parsing.
This commit is contained in:
Daniel Engberg 2023-08-05 20:57:25 +02:00
parent 69e0cbe8ea
commit cb0f0ba546
5 changed files with 79 additions and 0 deletions

View File

@ -260,6 +260,7 @@
SUBDIR += obs-studio
SUBDIR += obs-text-pthread
SUBDIR += obs-waveform
SUBDIR += obuparse
SUBDIR += oggvideotools
SUBDIR += ogmrip
SUBDIR += ogmtools

View File

@ -0,0 +1,30 @@
PORTNAME= obuparse
DISTVERSION= g20230712
CATEGORIES= multimedia
MAINTAINER= diizzy@FreeBSD.org
COMMENT= Simple and portable single file AV1 OBU parser
WWW= https://github.com/dwbuiten/obuparse
LICENSE= ISCL
LICENSE_FILE= ${WRKSRC}/LICENSE
USES= gmake
USE_GITHUB= yes
GH_ACCOUNT= dwbuiten
GH_TAGNAME= f40598f
USE_LDCONFIG= yes
MAKE_ARGS= PREFIX="${STAGEDIR}${PREFIX}"
INSTALL_TARGET= install-shared
PLIST_FILES= include/obuparse.h \
lib/libobuparse.so \
lib/libobuparse.so.1
post-install:
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libobuparse.so.1
.include <bsd.port.mk>

View File

@ -0,0 +1,3 @@
TIMESTAMP = 1690742528
SHA256 (dwbuiten-obuparse-g20230712-f40598f_GH0.tar.gz) = 3908f4f8a2b85acf602f18ed0b91c860c787046a26441c2d92dec79da68e5a68
SIZE (dwbuiten-obuparse-g20230712-f40598f_GH0.tar.gz) = 29233

View File

@ -0,0 +1,33 @@
--- Makefile.orig 2023-07-12 18:02:40 UTC
+++ Makefile
@@ -1,9 +1,9 @@
PREFIX=/usr/local
-CFLAGS := -O3 -std=c99 -Wall -Wextra -g -fPIC -I. $(CPPFLAGS)
+CFLAGS += -std=c99 -Wall -Wextra -fPIC -I. $(CPPFLAGS)
LDFLAGS +=
-CC := $(CROSS)gcc
-AR := $(CROSS)ar
+CC := $(CC)
+AR := $(AR)
ifneq (,$(findstring mingw,$(CC)))
LIBSUF=.dll
@@ -11,7 +11,7 @@ ifneq (,$(findstring mingw,$(CC)))
SYSTEM=MINGW
else
LIBSUF=.so
- LDFLAGS=-Wl,--version-script,obuparse.v
+ LDFLAGS+= -Wl,--version-script,obuparse.v
endif
all: libobuparse$(LIBSUF) libobuparse.a
@@ -24,7 +24,7 @@ libobuparse.a: obuparse.o
$(AR) rcs $@ $^
libobuparse$(LIBSUF): obuparse.o
- $(CC) $(LDFLAGS) -shared $^ -o $@
+ $(CC) $(LDFLAGS) -shared $^ -o $@ -Wl,-soname,libobuparse$(LIBSUF).1
install: install-shared install-static

View File

@ -0,0 +1,12 @@
Simple and portable single file AV1 OBU parser written in mostly C89 with a
tiny bit of C99.
* No allocations; only works on user-provided buffers and the stack.
* OBU header parsing.
* Sequence Header OBU parsing.
* Metadata OBU parsing.
* Tile List OBU parsing.
* Tile Group OBU parsing.
* Frame Header OBU parsing.
* Frame OBU parsing.