mirror of
https://github.com/pikvm/ustreamer.git
synced 2026-02-27 20:26:31 +00:00
Compare commits
6 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
eb1a2e3695 | ||
|
|
6cfd3739d3 | ||
|
|
77b8386de7 | ||
|
|
a002bd3427 | ||
|
|
202b907430 | ||
|
|
d9f4aba953 |
@@ -1,7 +1,7 @@
|
|||||||
[bumpversion]
|
[bumpversion]
|
||||||
commit = True
|
commit = True
|
||||||
tag = True
|
tag = True
|
||||||
current_version = 3.8
|
current_version = 3.11
|
||||||
parse = (?P<major>\d+)\.(?P<minor>\d+)(\.(?P<patch>\d+)(\-(?P<release>[a-z]+))?)?
|
parse = (?P<major>\d+)\.(?P<minor>\d+)(\.(?P<patch>\d+)(\-(?P<release>[a-z]+))?)?
|
||||||
serialize =
|
serialize =
|
||||||
{major}.{minor}
|
{major}.{minor}
|
||||||
|
|||||||
29
Makefile
29
Makefile
@@ -8,7 +8,7 @@ MANPREFIX ?= $(PREFIX)/share/man
|
|||||||
|
|
||||||
CC ?= gcc
|
CC ?= gcc
|
||||||
PY ?= python3
|
PY ?= python3
|
||||||
CFLAGS ?= -O3 -MD
|
CFLAGS ?= -O3
|
||||||
LDFLAGS ?=
|
LDFLAGS ?=
|
||||||
|
|
||||||
RPI_VC_HEADERS ?= /opt/vc/include
|
RPI_VC_HEADERS ?= /opt/vc/include
|
||||||
@@ -20,7 +20,8 @@ LINTERS_IMAGE ?= $(USTR)-linters
|
|||||||
|
|
||||||
|
|
||||||
# =====
|
# =====
|
||||||
override CFLAGS += -c -std=c11 -Wall -Wextra -D_GNU_SOURCE
|
_CFLAGS = -MD -c -std=c11 -Wall -Wextra -D_GNU_SOURCE $(CFLAGS)
|
||||||
|
_LDFLAGS = $(LDFLAGS)
|
||||||
|
|
||||||
_COMMON_LIBS = -lm -ljpeg -pthread -lrt
|
_COMMON_LIBS = -lm -ljpeg -pthread -lrt
|
||||||
|
|
||||||
@@ -48,7 +49,7 @@ endef
|
|||||||
|
|
||||||
ifneq ($(call optbool,$(WITH_OMX)),)
|
ifneq ($(call optbool,$(WITH_OMX)),)
|
||||||
_USTR_LIBS += -lbcm_host -lvcos -lvcsm -lopenmaxil -lmmal -lmmal_core -lmmal_util -lmmal_vc_client -lmmal_components -L$(RPI_VC_LIBS)
|
_USTR_LIBS += -lbcm_host -lvcos -lvcsm -lopenmaxil -lmmal -lmmal_core -lmmal_util -lmmal_vc_client -lmmal_components -L$(RPI_VC_LIBS)
|
||||||
override CFLAGS += -DWITH_OMX -DOMX_SKIP64BIT -I$(RPI_VC_HEADERS)
|
override _CFLAGS += -DWITH_OMX -DOMX_SKIP64BIT -I$(RPI_VC_HEADERS)
|
||||||
_USTR_SRCS += $(shell ls \
|
_USTR_SRCS += $(shell ls \
|
||||||
src/ustreamer/encoders/omx/*.c \
|
src/ustreamer/encoders/omx/*.c \
|
||||||
src/ustreamer/h264/*.c \
|
src/ustreamer/h264/*.c \
|
||||||
@@ -58,14 +59,14 @@ endif
|
|||||||
|
|
||||||
ifneq ($(call optbool,$(WITH_GPIO)),)
|
ifneq ($(call optbool,$(WITH_GPIO)),)
|
||||||
_USTR_LIBS += -lgpiod
|
_USTR_LIBS += -lgpiod
|
||||||
override CFLAGS += -DWITH_GPIO
|
override _CFLAGS += -DWITH_GPIO
|
||||||
_USTR_SRCS += $(shell ls src/ustreamer/gpio/*.c)
|
_USTR_SRCS += $(shell ls src/ustreamer/gpio/*.c)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|
||||||
WITH_PTHREAD_NP ?= 1
|
WITH_PTHREAD_NP ?= 1
|
||||||
ifneq ($(call optbool,$(WITH_PTHREAD_NP)),)
|
ifneq ($(call optbool,$(WITH_PTHREAD_NP)),)
|
||||||
override CFLAGS += -DWITH_PTHREAD_NP
|
override _CFLAGS += -DWITH_PTHREAD_NP
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|
||||||
@@ -74,7 +75,7 @@ ifneq ($(call optbool,$(WITH_SETPROCTITLE)),)
|
|||||||
ifeq ($(shell uname -s | tr A-Z a-z),linux)
|
ifeq ($(shell uname -s | tr A-Z a-z),linux)
|
||||||
_USTR_LIBS += -lbsd
|
_USTR_LIBS += -lbsd
|
||||||
endif
|
endif
|
||||||
override CFLAGS += -DWITH_SETPROCTITLE
|
override _CFLAGS += -DWITH_SETPROCTITLE
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|
||||||
@@ -82,7 +83,7 @@ endif
|
|||||||
all: $(USTR) $(DUMP) python
|
all: $(USTR) $(DUMP) python
|
||||||
|
|
||||||
|
|
||||||
install: $(USTR) $(DUMP)
|
install: all
|
||||||
mkdir -p $(DESTDIR)$(PREFIX)/bin $(DESTDIR)$(MANPREFIX)/man1
|
mkdir -p $(DESTDIR)$(PREFIX)/bin $(DESTDIR)$(MANPREFIX)/man1
|
||||||
install -m755 $(USTR) $(DESTDIR)$(PREFIX)/bin/$(USTR)
|
install -m755 $(USTR) $(DESTDIR)$(PREFIX)/bin/$(USTR)
|
||||||
install -m755 $(DUMP) $(DESTDIR)$(PREFIX)/bin/$(DUMP)
|
install -m755 $(DUMP) $(DESTDIR)$(PREFIX)/bin/$(DUMP)
|
||||||
@@ -108,27 +109,27 @@ regen:
|
|||||||
$(USTR): $(_USTR_SRCS:%.c=$(BUILD)/%.o)
|
$(USTR): $(_USTR_SRCS:%.c=$(BUILD)/%.o)
|
||||||
# $(info ========================================)
|
# $(info ========================================)
|
||||||
$(info == LD $@)
|
$(info == LD $@)
|
||||||
@ $(CC) $^ -o $@ $(LDFLAGS) $(_USTR_LIBS)
|
@ $(CC) $^ -o $@ $(_LDFLAGS) $(_USTR_LIBS)
|
||||||
# $(info :: CC = $(CC))
|
# $(info :: CC = $(CC))
|
||||||
# $(info :: LIBS = $(_USTR_LIBS))
|
# $(info :: LIBS = $(_USTR_LIBS))
|
||||||
# $(info :: CFLAGS = $(CFLAGS))
|
# $(info :: CFLAGS = $(_CFLAGS))
|
||||||
# $(info :: LDFLAGS = $(LDFLAGS))
|
# $(info :: LDFLAGS = $(_LDFLAGS))
|
||||||
|
|
||||||
|
|
||||||
$(DUMP): $(_DUMP_SRCS:%.c=$(BUILD)/%.o)
|
$(DUMP): $(_DUMP_SRCS:%.c=$(BUILD)/%.o)
|
||||||
# $(info ========================================)
|
# $(info ========================================)
|
||||||
$(info == LD $@)
|
$(info == LD $@)
|
||||||
@ $(CC) $^ -o $@ $(LDFLAGS) $(_DUMP_LIBS)
|
@ $(CC) $^ -o $@ $(_LDFLAGS) $(_DUMP_LIBS)
|
||||||
# $(info :: CC = $(CC))
|
# $(info :: CC = $(CC))
|
||||||
# $(info :: LIBS = $(_DUMP_LIBS))
|
# $(info :: LIBS = $(_DUMP_LIBS))
|
||||||
# $(info :: CFLAGS = $(CFLAGS))
|
# $(info :: CFLAGS = $(_CFLAGS))
|
||||||
# $(info :: LDFLAGS = $(LDFLAGS))
|
# $(info :: LDFLAGS = $(_LDFLAGS))
|
||||||
|
|
||||||
|
|
||||||
$(BUILD)/%.o: %.c
|
$(BUILD)/%.o: %.c
|
||||||
$(info -- CC $<)
|
$(info -- CC $<)
|
||||||
@ mkdir -p $(dir $@) || true
|
@ mkdir -p $(dir $@) || true
|
||||||
@ $(CC) $< -o $@ $(CFLAGS)
|
@ $(CC) $< -o $@ $(_CFLAGS)
|
||||||
|
|
||||||
|
|
||||||
python:
|
python:
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
.\" Manpage for ustreamer-dump.
|
.\" Manpage for ustreamer-dump.
|
||||||
.\" Open an issue or pull request to https://github.com/pikvm/ustreamer to correct errors or typos
|
.\" Open an issue or pull request to https://github.com/pikvm/ustreamer to correct errors or typos
|
||||||
.TH USTREAMER-DUMP 1 "version 3.8" "January 2021"
|
.TH USTREAMER-DUMP 1 "version 3.11" "January 2021"
|
||||||
|
|
||||||
.SH NAME
|
.SH NAME
|
||||||
ustreamer-dump \- Dump uStreamer's memory sink to file
|
ustreamer-dump \- Dump uStreamer's memory sink to file
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
.\" Manpage for ustreamer.
|
.\" Manpage for ustreamer.
|
||||||
.\" Open an issue or pull request to https://github.com/pikvm/ustreamer to correct errors or typos
|
.\" Open an issue or pull request to https://github.com/pikvm/ustreamer to correct errors or typos
|
||||||
.TH USTREAMER 1 "version 3.8" "November 2020"
|
.TH USTREAMER 1 "version 3.11" "November 2020"
|
||||||
|
|
||||||
.SH NAME
|
.SH NAME
|
||||||
ustreamer \- stream MJPG video from any V4L2 device to the network
|
ustreamer \- stream MJPG video from any V4L2 device to the network
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
|
|
||||||
pkgname=ustreamer
|
pkgname=ustreamer
|
||||||
pkgver=3.8
|
pkgver=3.11
|
||||||
pkgrel=1
|
pkgrel=1
|
||||||
pkgdesc="Lightweight and fast MJPG-HTTP streamer"
|
pkgdesc="Lightweight and fast MJPG-HTTP streamer"
|
||||||
url="https://github.com/pikvm/ustreamer"
|
url="https://github.com/pikvm/ustreamer"
|
||||||
@@ -43,5 +43,5 @@ build() {
|
|||||||
|
|
||||||
package() {
|
package() {
|
||||||
cd "$srcdir/$pkgname-build"
|
cd "$srcdir/$pkgname-build"
|
||||||
make DESTDIR="$pkgdir" PREFIX=/usr install
|
make $_options DESTDIR="$pkgdir" PREFIX=/usr install
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=ustreamer
|
PKG_NAME:=ustreamer
|
||||||
PKG_VERSION:=3.8
|
PKG_VERSION:=3.11
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=1
|
||||||
PKG_MAINTAINER:=Maxim Devaev <mdevaev@gmail.com>
|
PKG_MAINTAINER:=Maxim Devaev <mdevaev@gmail.com>
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ from distutils.core import setup
|
|||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
setup(
|
setup(
|
||||||
name="ustreamer",
|
name="ustreamer",
|
||||||
version="3.8",
|
version="3.11",
|
||||||
description="uStreamer tools",
|
description="uStreamer tools",
|
||||||
author="Maxim Devaev",
|
author="Maxim Devaev",
|
||||||
author_email="mdevaev@gmail.com",
|
author_email="mdevaev@gmail.com",
|
||||||
|
|||||||
@@ -267,12 +267,13 @@ FIELD_GETTER(wait_timeout, Double, Float)
|
|||||||
#undef FIELD_GETTER
|
#undef FIELD_GETTER
|
||||||
|
|
||||||
static PyMethodDef MemsinkObject_methods[] = {
|
static PyMethodDef MemsinkObject_methods[] = {
|
||||||
# define ADD_METHOD(_meth, _flags) {.ml_name = #_meth, .ml_meth = (PyCFunction)MemsinkObject_##_meth, .ml_flags = (_flags)}
|
# define ADD_METHOD(_name, _method, _flags) \
|
||||||
ADD_METHOD(close, METH_NOARGS),
|
{.ml_name = _name, .ml_meth = (PyCFunction)MemsinkObject_##_method, .ml_flags = (_flags)}
|
||||||
ADD_METHOD(enter, METH_NOARGS),
|
ADD_METHOD("close", close, METH_NOARGS),
|
||||||
ADD_METHOD(exit, METH_VARARGS),
|
ADD_METHOD("__enter__", enter, METH_NOARGS),
|
||||||
ADD_METHOD(wait_frame, METH_NOARGS),
|
ADD_METHOD("__exit__", exit, METH_VARARGS),
|
||||||
ADD_METHOD(is_opened, METH_NOARGS),
|
ADD_METHOD("wait_frame", wait_frame, METH_NOARGS),
|
||||||
|
ADD_METHOD("is_opened", is_opened, METH_NOARGS),
|
||||||
{},
|
{},
|
||||||
# undef ADD_METHOD
|
# undef ADD_METHOD
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -23,5 +23,5 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#ifndef VERSION
|
#ifndef VERSION
|
||||||
# define VERSION "3.8"
|
# define VERSION "3.11"
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
Reference in New Issue
Block a user