core: added libsxt skel;

master
Alexander Vdolainen 9 years ago
parent d1bf79b1e3
commit 9e541bc4aa

@ -6,7 +6,7 @@ else
EXAMPLES = EXAMPLES =
endif endif
SUBDIRS = include tdata sexpr sxmp ydaemon man $(EXAMPLES) SUBDIRS = include tdata sxt sexpr sxmp ydaemon man $(EXAMPLES)
libsxmpdocdir = ${prefix}/doc/libsxmp libsxmpdocdir = ${prefix}/doc/libsxmp
libsxmpdoc_DATA = \ libsxmpdoc_DATA = \

@ -1,6 +1,7 @@
dnl Process this file with autoconf to produce a configure script. dnl Process this file with autoconf to produce a configure script.
AC_INIT(libsxmp, m4_esyscmd([tr -d '\n' < VERSION.sxmp])) AC_INIT(libsxmp, m4_esyscmd([tr -d '\n' < VERSION.sxmp]))
AC_SUBST([LIBSXT_VERSION], m4_esyscmd([tr -d '\n' < sxt/VERSION]))
AC_SUBST([LIBTDATA_VERSION], m4_esyscmd([tr -d '\n' < tdata/VERSION])) AC_SUBST([LIBTDATA_VERSION], m4_esyscmd([tr -d '\n' < tdata/VERSION]))
AC_SUBST([LIBSEXPR_VERSION], m4_esyscmd([tr -d '\n' < sexpr/VERSION])) AC_SUBST([LIBSEXPR_VERSION], m4_esyscmd([tr -d '\n' < sexpr/VERSION]))
AC_SUBST([LIBYDAEMON_VERSION], m4_esyscmd([tr -d '\n' < ydaemon/VERSION])) AC_SUBST([LIBYDAEMON_VERSION], m4_esyscmd([tr -d '\n' < ydaemon/VERSION]))
@ -102,6 +103,8 @@ dnl AM_CONDITIONAL(BUILD_WIN32, test "x$enable_win32_build" = "xyes")
AC_OUTPUT([ AC_OUTPUT([
Makefile Makefile
sxt/libsxt.pc
sxt/Makefile
sxmp/libsxmp.pc sxmp/libsxmp.pc
sxmp/Makefile sxmp/Makefile
sexpr/Makefile sexpr/Makefile

@ -0,0 +1,39 @@
## Process this file with automake to produce Makefile.in
AM_CPPFLAGS = \
-DPACKAGE_LOCALE_DIR=\""$(localedir)"\" \
-DPACKAGE_SRC_DIR=\""$(srcdir)"\" \
-DPACKAGE_DATA_DIR=\""$(pkgdatadir)"\" \
$(LIBSXMP_CFLAGS) -I../include
AM_CFLAGS =\
-Wall\
-g
lib_LTLIBRARIES = libsxt.la
libsxt_la_SOURCES = \
core.c
libsxt_la_LDFLAGS =
libsxt_la_LIBADD = -lpthread -lcrypto $(OPENSSL_LIBS)
if COND_WIN32
libsxt_la_LDFLAGS += -no-undefined
libsxt_la_LIBADD += -lmman -luuid /mingw64/lib/libtdata.a
else
libsxt_la_LIBADD += $(LIBUUID_LIBS) ../tdata/.libs/libtdata.la
endif !COND_WIN32
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = libsxt.pc
EXTRA_DIST = \
libsxt.pc.in

@ -0,0 +1,3 @@
0.0.1

@ -0,0 +1,62 @@
/*
* Secure eXtended Message Passing framework
* Secure eXtended Transport layer implementation: (libsxt)
* - very similar to SSH2/TLS
* - using already proven and tested crypto algos
* - better than TLS for message passing
*
* (c) Alexander Vdolainen 2016 <avdolainen@zoho.com>
*
* libsxmp is free software: you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* libsxmp is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
* See the GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.";
*
*/
#include <stdlib.h>
#include <stdio.h>
#include <errno.h>
#include <string.h>
#include <pthread.h>
#include <sys/stat.h>
#include <sys/time.h>
#include <sys/types.h>
#include <sys/mman.h>
#include <fcntl.h>
#ifdef WIN32
#include <Winsock2.h>
#define EBADE 1
#define NETDB_SUCCESS 0
#else
#include <sys/select.h>
#include <netdb.h>
#include <unistd.h>
#include <uuid/uuid.h>
#endif
#include <openssl/ssl.h>
#include <openssl/err.h>
#include <openssl/engine.h>
#include <tdata/usrtc.h>
#include <tdata/list.h>
int sxt_init(void)
{
return;
}
int sxt_finish(void)
{
return;
}

@ -0,0 +1,13 @@
prefix=@prefix@
exec_prefix=@exec_prefix@
libdir=@libdir@
datarootdir=@datarootdir@
datadir=@datadir@
includedir=@includedir@
Name: libsxt
Description: Secure eXtended Transport implementation library
Version: @LIBSXT_VERSION@
Requires:
Libs: -L${libdir} -lsxt
Cflags: -I${includedir}
Loading…
Cancel
Save