diff options
-rw-r--r-- | .SRCINFO | 20 | ||||
-rwxr-xr-x | .gitignore | 2 | ||||
-rwxr-xr-x | Config-linux-config.h | 200 | ||||
-rwxr-xr-x | LICENSE | 28 | ||||
-rwxr-xr-x | PKGBUILD | 68 | ||||
-rwxr-xr-x | libarstream2-Makefile | 31 |
6 files changed, 349 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..b5b03a313539 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,20 @@ +pkgbase = libarstream2-git + pkgdesc = Parrot Streaming Library + pkgver = r156.bcd93a5 + pkgrel = 1 + url = http://developer.parrot.com/ + arch = x86_64 + license = custom + makedepends = git + depends = libarsal-git + source = libarstream2::git+https://github.com/Parrot-Developers/libARStream2 + source = libarstream2-Makefile + source = Config-linux-config.h + source = LICENSE + sha256sums = SKIP + sha256sums = b48204d27c7cb89c18e062d2d953639fc1d090f48ff2deb5edf75ed94f138eb8 + sha256sums = 5956b54ef47ad26df51991a4aa7002abdcb524a51b455d040f55b4d11a4f44a7 + sha256sums = 1771e95329e9cb2bed04e023e330af3d558d0f13c0c1c5de0581f2880f149deb + +pkgname = libarstream2-git + diff --git a/.gitignore b/.gitignore new file mode 100755 index 000000000000..c83b46b095d1 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +libarstream2/ +*.pkg.tar.xz diff --git a/Config-linux-config.h b/Config-linux-config.h new file mode 100755 index 000000000000..dc8a5ded8656 --- /dev/null +++ b/Config-linux-config.h @@ -0,0 +1,200 @@ +/* config.h. Generated from config.h.in by configure. */ +/* config.h.in. Generated from configure.ac by autoheader. */ + +/* Debug Mode */ +/* #undef DEBUG */ + +/* Define to 1 if you have the declaration of `PRIi16', and to 0 if you don't. + */ +#define HAVE_DECL_PRII16 1 + +/* Define to 1 if you have the declaration of `PRIi32', and to 0 if you don't. + */ +#define HAVE_DECL_PRII32 1 + +/* Define to 1 if you have the declaration of `PRIi64', and to 0 if you don't. + */ +#define HAVE_DECL_PRII64 1 + +/* Define to 1 if you have the declaration of `PRIi8', and to 0 if you don't. + */ +#define HAVE_DECL_PRII8 1 + +/* Define to 1 if you have the declaration of `PRIu16', and to 0 if you don't. + */ +#define HAVE_DECL_PRIU16 1 + +/* Define to 1 if you have the declaration of `PRIu32', and to 0 if you don't. + */ +#define HAVE_DECL_PRIU32 1 + +/* Define to 1 if you have the declaration of `PRIu64', and to 0 if you don't. + */ +#define HAVE_DECL_PRIU64 1 + +/* Define to 1 if you have the declaration of `PRIu8', and to 0 if you don't. + */ +#define HAVE_DECL_PRIU8 1 + +/* Define to 1 if you have the <android/log.h> header file. */ +/* #undef HAVE_ANDROID_LOG_H */ + +/* Define to 1 if you have the `clock_gettime' function. */ +#define HAVE_CLOCK_GETTIME 1 + +/* Define to 1 if you have the <CoreBluetooth/CoreBluetooth.h> header file. */ +/* #undef HAVE_COREBLUETOOTH_COREBLUETOOTH_H */ + +/* Define to 1 if you have the declaration of `MSG_NOSIGNAL', and to 0 if you + don't. */ +#ifdef __linux__ +# define HAVE_DECL_MSG_NOSIGNAL 1 +#else +# define HAVE_DECL_MSG_NOSIGNAL 0 +#endif + +/* Define to 1 if you have the declaration of `SO_NOSIGPIPE', and to 0 if you + don't. */ +#ifdef __linux__ +# define HAVE_DECL_SO_NOSIGPIPE 0 +#else +# define HAVE_DECL_SO_NOSIGPIPE 1 +#endif + +/* Define to 1 if you have the declaration of `CLOCK_MONOTONIC', and to 0 if + you don't. */ +#ifdef __linux__ +# define HAVE_DECL_CLOCK_MONOTONIC 1 +#else +# define HAVE_DECL_CLOCK_MONOTONIC 0 +#endif + +/* Define to 1 if you have the declaration of `CLOCK_REALTIME', and to 0 if + you don't. */ +#ifdef __linux__ +# define HAVE_DECL_CLOCK_REALTIME 1 +#else +# define HAVE_DECL_CLOCK_REALTIME 0 +#endif + +/* Define to 1 if you have the declaration of `log2', and to 0 if you don't. + */ +#define HAVE_DECL_LOG2 1 + +/* Define to 1 if you have the declaration of `SYS_gettid', and to 0 if you + don't. */ +#define HAVE_DECL_SYS_GETTID 1 + +/* Define to 1 if you have the <dlfcn.h> header file. */ +#define HAVE_DLFCN_H 1 + +/* Define to 1 if you have the <ftw.h> header file. */ +#define HAVE_FTW_H 1 + +/* Define to 1 if you have the `gettimeofday' function. */ +#define HAVE_GETTIMEOFDAY 1 + +/* Define to 1 if you have the <inttypes.h> header file. */ +#define HAVE_INTTYPES_H 1 + +/* Whether the libm on the host has the log2 function */ +#define HAVE_LOG2 1 + +/* Define to 1 if you have the <memory.h> header file. */ +#define HAVE_MEMORY_H 1 + +/* Define to 1 if you have the <netinet/in.h> header file. */ +#define HAVE_NETINET_IN_H 1 + +/* Define to 1 if you have the <pthread.h> header file. */ +#define HAVE_PTHREAD_H 1 + +/* Define to 1 if you have the <semaphore.h> header file. */ +#define HAVE_SEMAPHORE_H 1 + +/* Define to 1 if you have the `sem_destroy' function. */ +#define HAVE_SEM_DESTROY 1 + +/* Define to 1 if you have the `sem_getvalue' function. */ +#define HAVE_SEM_GETVALUE 1 + +/* Define to 1 if you have the `sem_init' function. */ +#define HAVE_SEM_INIT 1 + +/* Define to 1 if you have the `sem_post' function. */ +#define HAVE_SEM_POST 1 + +/* Define to 1 if you have the `sem_timedwait' function. */ +#ifdef __linux__ +# define HAVE_SEM_TIMEDWAIT 1 +#endif + +/* Define to 1 if you have the `sem_trywait' function. */ +#define HAVE_SEM_TRYWAIT 1 + +/* Define to 1 if you have the `sem_wait' function. */ +#define HAVE_SEM_WAIT 1 + +/* Define to 1 if you have the <stdarg.h> header file. */ +#define HAVE_STDARG_H 1 + +/* Define to 1 if you have the <stdint.h> header file. */ +#define HAVE_STDINT_H 1 + +/* Define to 1 if you have the <stdio.h> header file. */ +#define HAVE_STDIO_H 1 + +/* Define to 1 if you have the <stdlib.h> header file. */ +#define HAVE_STDLIB_H 1 + +/* Define to 1 if you have the <strings.h> header file. */ +#define HAVE_STRINGS_H 1 + +/* Define to 1 if you have the <string.h> header file. */ +#define HAVE_STRING_H 1 + +/* Define to 1 if you have the <sys/socket.h> header file. */ +#define HAVE_SYS_SOCKET_H 1 + +/* Define to 1 if you have the <sys/stat.h> header file. */ +#define HAVE_SYS_STAT_H 1 + +/* Define to 1 if you have the <sys/time.h> header file. */ +#define HAVE_SYS_TIME_H 1 + +/* Define to 1 if you have the <sys/types.h> header file. */ +#define HAVE_SYS_TYPES_H 1 + +/* Define to 1 if you have the <sys/uio.h> header file. */ +#define HAVE_SYS_UIO_H 1 + +/* Define to 1 if you have the `time' function. */ +#define HAVE_TIME 1 + +/* Define to 1 if you have the <time.h> header file. */ +#define HAVE_TIME_H 1 + +/* Define to 1 if you have the <unistd.h> header file. */ +#define HAVE_UNISTD_H 1 + +/* Define to 1 if you have the <sys/statfs.h> header file. */ +#ifdef __linux__ +# define HAVE_SYS_STATFS_H 1 +#endif + +/* Define to 1 if you have the <sys/mount.h> header file. */ +#define HAVE_SYS_MOUNT_H 1 + +/* No-debug Mode */ +#define NDEBUG /**/ + +/* Define to 1 if you have the ANSI C header files. */ +#define STDC_HEADERS 1 + +/* Define to 1 if you have the <sys/mount.h> header file. */ +#define HAVE_SYS_MOUNT_H 1 + +/* Define to 1 if you have the <UIKit/UIKit.h> header file. */ +/* #undef HAVE_UIKIT_UIKIT_H */ +/* Define to `unsigned int' if <sys/types.h> does not define. */ +/* #undef size_t */ diff --git a/LICENSE b/LICENSE new file mode 100755 index 000000000000..2b9256f4825e --- /dev/null +++ b/LICENSE @@ -0,0 +1,28 @@ +Copyright (C) 2014 Parrot SA + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: +* Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. +* Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in + the documentation and/or other materials provided with the + distribution. +* Neither the name of Parrot nor the names + of its contributors may be used to endorse or promote products + derived from this software without specific prior written + permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS +FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, +BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS +OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED +AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +SUCH DAMAGE. diff --git a/PKGBUILD b/PKGBUILD new file mode 100755 index 000000000000..bbec25b268a3 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,68 @@ +# Maintainer: Alexandre Iooss <alexandre.iooss@gmail.com> + +# OPTIONAL:libmux \ +# OPTIONAL:libpomp \ +# OPTIONAL:libARMedia + +pkgname=libarstream2-git +pkgver=r156.bcd93a5 +pkgrel=1 +pkgdesc="Parrot Streaming Library" +arch=(x86_64) +url="http://developer.parrot.com/" +license=('custom') +groups=() +depends=(libarsal-git) +optdepends=() +makedepends=(git) +provides=() +conflicts=() +replaces=() +backup=() +options=() +install= +source=('libarstream2::git+https://github.com/Parrot-Developers/libARStream2' + 'libarstream2-Makefile' + 'Config-linux-config.h' + 'LICENSE') +sha256sums=('SKIP' + 'b48204d27c7cb89c18e062d2d953639fc1d090f48ff2deb5edf75ed94f138eb8' + '5956b54ef47ad26df51991a4aa7002abdcb524a51b455d040f55b4d11a4f44a7' + '1771e95329e9cb2bed04e023e330af3d558d0f13c0c1c5de0581f2880f149deb') + +pkgver() { + cd "$srcdir/libarstream2" + printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" +} + +prepare() { + cp "$srcdir/libarstream2-Makefile" "$srcdir/libarstream2/Makefile" + cp "$srcdir/Config-linux-config.h" "$srcdir/libarstream2/Includes/config.h" +} + +build() { + cd "$srcdir/libarstream2" + make +} + +package() { + # Install headers + mkdir -p "$pkgdir/usr/include/libARStream2" + cp "$srcdir/libarstream2/Includes/libARStream2/arstream2_error.h" "$pkgdir/usr/include/libARStream2/" + cp "$srcdir/libarstream2/Includes/libARStream2/arstream2_h264_filter.h" "$pkgdir/usr/include/libARStream2/" + cp "$srcdir/libarstream2/Includes/libARStream2/arstream2_h264_parser.h" "$pkgdir/usr/include/libARStream2/" + cp "$srcdir/libarstream2/Includes/libARStream2/arstream2_h264_sei.h" "$pkgdir/usr/include/libARStream2/" + cp "$srcdir/libarstream2/Includes/libARStream2/arstream2_h264_writer.h" "$pkgdir/usr/include/libARStream2/" + cp "$srcdir/libarstream2/Includes/libARStream2/arstream2_rtp_receiver.h" "$pkgdir/usr/include/libARStream2/" + cp "$srcdir/libarstream2/Includes/libARStream2/arstream2_rtp_sender.h" "$pkgdir/usr/include/libARStream2/" + cp "$srcdir/libarstream2/Includes/libARStream2/arstream2_stream_recorder.h" "$pkgdir/usr/include/libARStream2/" + cp "$srcdir/libarstream2/Includes/libARStream2/arstream2_stream_receiver.h" "$pkgdir/usr/include/libARStream2/" + + # Install lib + mkdir -p "$pkgdir/usr/lib" + cp "$srcdir/libarstream2/libarstream2.so" "$pkgdir/usr/lib/" + + # Install license + mkdir -p "$pkgdir/usr/share/licenses/$pkgname" + cp "$srcdir/LICENSE" "$pkgdir/usr/share/licenses/$pkgname/LICENSE" +} diff --git a/libarstream2-Makefile b/libarstream2-Makefile new file mode 100755 index 000000000000..7c6489d22323 --- /dev/null +++ b/libarstream2-Makefile @@ -0,0 +1,31 @@ +CC = gcc +CFLAGS = -fPIC -Wall -Wextra -O2 -g -IIncludes -DHAVE_CONFIG_H +LDFLAGS = -shared +RM = rm -f +TARGET_LIB = libarstream2.so + +SRCS = gen/Sources/arstream2_error.c \ + src/arstream2_h264_filter.c \ + src/arstream2_h264_parser.c \ + src/arstream2_h264_sei.c \ + src/arstream2_h264_writer.c \ + src/arstream2_rtp_receiver.c \ + src/arstream2_rtp_sender.c \ + src/arstream2_stream_recorder.c \ + src/arstream2_stream_receiver.c +OBJS = $(SRCS:.c=.o) + +.PHONY: all +all: ${TARGET_LIB} + +$(TARGET_LIB): $(OBJS) + $(CC) ${LDFLAGS} -o $@ $^ + +$(SRCS:.c=.d):%.d:%.c + $(CC) $(CFLAGS) -MM $< >$@ + +include $(SRCS:.c=.d) + +.PHONY: clean +clean: + -${RM} ${TARGET_LIB} ${OBJS} $(SRCS:.c=.d) |