Skip to content

Commit

Permalink
gst-crypto 1.0 port take 1, #4
Browse files Browse the repository at this point in the history
  • Loading branch information
Carsten Behling committed Apr 14, 2015
1 parent 8655086 commit 9e34306
Show file tree
Hide file tree
Showing 11 changed files with 1,723 additions and 649 deletions.
1 change: 1 addition & 0 deletions AUTHORS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Carsten Behling <carsten.behling@ridgerun.com>
1,127 changes: 478 additions & 649 deletions COPYING

Large diffs are not rendered by default.

24 changes: 24 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
2015-04-14 Carsten Behling <carsten.behling@ridgerun.com>

* AUTHORS:
Initial version.
* autogen.sh:
Initial version.
* ChangeLog:
Initial version.
* configure.ac:
Initial version.
* COPYING:
Initial version.
* Makefile.am:
Initial version.
* NEWS:
Initial version.
* README:
Initial version.
* src/gstcrypto.c:
Initial version.
* src/gstcrypto.h:
Initial version.
* src/Makefile.am:
Initial version.
370 changes: 370 additions & 0 deletions INSTALL

Large diffs are not rendered by default.

10 changes: 10 additions & 0 deletions Makefile.am
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
SUBDIRS = src

EXTRA_DIST = autogen.sh


# Clear dependency_libs for multiarch
all-local:
sed -i "/dependency_libs/ s/'.*'/''/" `find . -name '*.la'`
sed -i "/dependency_libs/ s/'.*'/''/" `find . -name '*.lai'`

1 change: 1 addition & 0 deletions NEWS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Nothing much yet.
7 changes: 7 additions & 0 deletions autogen.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/sh

autoreconf --verbose --force --install --make || {
echo 'autogen.sh failed';
exit 1;
}

104 changes: 104 additions & 0 deletions configure.ac
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
dnl required version of autoconf
AC_PREREQ([2.53])

dnl TODO: fill in your package name and package version here
AC_INIT([gst-crupto],[1.0.0])

dnl required versions of gstreamer and plugins-base
GST_REQUIRED=1.0.0
GSTPB_REQUIRED=1.0.0

dnl reuiren version of opensll
OPENSSL_REQUIRED=1.0.0c

AC_CONFIG_SRCDIR([src/gstcrypto.c])
AC_CONFIG_HEADERS([config.h])

dnl required version of automake
AM_INIT_AUTOMAKE([1.10])

dnl enable mainainer mode by default
AM_MAINTAINER_MODE([enable])

dnl check for tools (compiler etc.)
AC_PROG_CC

dnl required version of libtool
LT_PREREQ([2.2.6])
LT_INIT

dnl give error and exit if we don't have pkgconfig
AC_CHECK_PROG(HAVE_PKGCONFIG, pkg-config, [ ], [
AC_MSG_ERROR([You need to have pkg-config installed!])
])

dnl Check for the required version of GStreamer core (and gst-plugins-base)
dnl This will export GST_CFLAGS and GST_LIBS variables for use in Makefile.am
dnl
dnl If you need libraries from gst-plugins-base here, also add:
dnl for libgstaudio-1.0: gstreamer-audio-1.0 >= $GST_REQUIRED
dnl for libgstvideo-1.0: gstreamer-video-1.0 >= $GST_REQUIRED
dnl for libgsttag-1.0: gstreamer-tag-1.0 >= $GST_REQUIRED
dnl for libgstpbutils-1.0: gstreamer-pbutils-1.0 >= $GST_REQUIRED
dnl for libgstfft-1.0: gstreamer-fft-1.0 >= $GST_REQUIRED
dnl for libgstinterfaces-1.0: gstreamer-interfaces-1.0 >= $GST_REQUIRED
dnl for libgstrtp-1.0: gstreamer-rtp-1.0 >= $GST_REQUIRED
dnl for libgstrtsp-1.0: gstreamer-rtsp-1.0 >= $GST_REQUIRED
dnl etc.
PKG_CHECK_MODULES(GST, [
gstreamer-1.0 >= $GST_REQUIRED
gstreamer-base-1.0 >= $GST_REQUIRED
gstreamer-controller-1.0 >= $GST_REQUIRED
], [
AC_SUBST(GST_CFLAGS)
AC_SUBST(GST_LIBS)
], [
AC_MSG_ERROR([
You need to install or upgrade the GStreamer development
packages on your system. On debian-based systems these are
libgstreamer1.0-dev and libgstreamer-plugins-base1.0-dev.
on RPM-based systems gstreamer1.0-devel, libgstreamer1.0-devel
or similar. The minimum version required is $GST_REQUIRED.
])
])

dnl Check for the required version of OpenSSL
PKG_CHECK_MODULES(OPENSSL, [
openssl >= $OPENSSL_REQUIRED
], [
AC_SUBST(OPENSSL_CFLAGS)
AC_SUBST(OPENSSL_LIBS)
], [
AC_MSG_ERROR([
You need to install or upgrade the OpenSSL development
packages on your system. On debian-based systems this is
libssl-dev.
The minimum version required is $OPENSSL_REQUIRED.
])
])
dnl check if compiler understands -Wall (if yes, add -Wall to GST_CFLAGS)
AC_MSG_CHECKING([to see if compiler understands -Wall])
save_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -Wall"
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([ ], [ ])], [
GST_CFLAGS="$GST_CFLAGS -Wall"
AC_MSG_RESULT([yes])
], [
AC_MSG_RESULT([no])
])

dnl set the plugindir where plugins should be installed (for src/Makefile.am)
if test "x${prefix}" = "x$HOME"; then
plugindir="$HOME/.gstreamer-1.0/plugins"
else
plugindir="\$(libdir)/gstreamer-1.0"
fi
AC_SUBST(plugindir)

dnl set proper LDFLAGS for plugins
GST_PLUGIN_LDFLAGS='-module -avoid-version -export-symbols-regex [_]*\(gst_\|Gst\|GST_\).*'
AC_SUBST(GST_PLUGIN_LDFLAGS)

AC_CONFIG_FILES([Makefile src/Makefile])
AC_OUTPUT

10 changes: 10 additions & 0 deletions src/Makefile.am
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
plugin_LTLIBRARIES = libgstcrypto.la

libgstcrypto_la_SOURCES = gstcrypto.c gstcrypto.h

libgstcrypto_la_CFLAGS = $(GST_CFLAGS) $(OPENSSL_CFLAGS)
libgstcrypto_la_LIBADD = $(GST_LIBS) $(OPENSSL_LIBS)
libgstcrypto_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
libgstcrypto_la_LIBTOOLFLAGS = --tag=disable-static

noinst_HEADERS = gstcrypto.h
Loading

0 comments on commit 9e34306

Please sign in to comment.