add autotools magic

This commit is contained in:
Harald Welte 2010-06-13 08:06:44 +02:00
parent 7f2b555196
commit ccd6367619
5 changed files with 125 additions and 0 deletions

8
Makefile.am Normal file
View File

@ -0,0 +1,8 @@
AUTOMAKE_OPTIONS = foreign dist-bzip2 1.6
ACLOCAL_AMFLAGS = -I m4
INCLUDES = $(all_includes) -I$(top_srcdir)/include
SUBDIRS = src include
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = libosmo-asn1-tcap.pc

33
configure.ac Normal file
View File

@ -0,0 +1,33 @@
AC_INIT([libosmo-asn1-tcap], 0.0.0, [openbsc-devel@lists.openbsc.org])
AM_INIT_AUTOMAKE([dist-bzip2])
dnl kernel style compile messages
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
dnl checks for programs
AC_PROG_MAKE_SET
AC_PROG_CC
AC_PROG_INSTALL
LT_INIT
AC_PROG_LIBTOOL
AC_CONFIG_MACRO_DIR([m4])
# The following test is taken from WebKit's webkit.m4
saved_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -fvisibility=hidden "
AC_MSG_CHECKING([if ${CC} supports -fvisibility=hidden])
AC_COMPILE_IFELSE([char foo;],
[ AC_MSG_RESULT([yes])
SYMBOL_VISIBILITY="-fvisibility=hidden"],
AC_MSG_RESULT([no]))
CFLAGS="$saved_CFLAGS"
AC_SUBST(SYMBOL_VISIBILITY)
AC_OUTPUT(
libosmo-asn1-tcap.pc
src/Makefile
include/Makefile
Makefile)

33
include/Makefile.am Normal file
View File

@ -0,0 +1,33 @@
osmo_asn1_tcap_HEADERS = \
ExternalPDU.h \
Dialog1.h \
TCMessage.h \
Unidirectional.h \
Begin.h \
End.h \
Continue.h \
Abort.h \
Reason.h \
DialoguePortion.h \
DialogueOC.h \
OrigTransactionID.h \
DestTransactionID.h \
P-AbortCause.h \
ComponentPortion.h \
Component.h \
Invoke.h \
Parameter.h \
ReturnResult.h \
ReturnError.h \
Reject.h \
InvokeIdType.h \
OPERATION.h \
ERROR.h \
GeneralProblem.h \
InvokeProblem.h \
ReturnResultProblem.h \
ReturnErrorProblem.h \
ErrorCode.h
osmo_asn1_tcapdir = $(includedir)/osmocom/tcap

11
libosmo-asn1-tcap.pc.in Normal file
View File

@ -0,0 +1,11 @@
prefix=@prefix@
exec_prefix=@exec_prefix@
libdir=@libdir@
includedir=@includedir@
Name: ASN.1 library for TCAP protocol (SS7)
Description: C Utility Library
Version: @VERSION@
Libs: -L${libdir} -lasn1c
Cflags: -I${includedir}/

40
src/Makefile.am Normal file
View File

@ -0,0 +1,40 @@
# This is _NOT_ the library release version, it's an API version.
# Please read Chapter 6 "Library interface versions" of the libtool
# documentation before making any modification
LIBVERSION=0:0:0
INCLUDES = $(all_includes) -I/usr/local/include/asn1c -I$(top_srcdir)/include
AM_CFLAGS = -fPIC -Wall
libosmo_asn1_tcap_la_SOURCES = \
ExternalPDU.c \
Dialog1.c \
TCMessage.c \
Unidirectional.c \
Begin.c \
End.c \
Continue.c \
Abort.c \
Reason.c \
DialoguePortion.c \
DialogueOC.c \
OrigTransactionID.c \
DestTransactionID.c \
P-AbortCause.c \
ComponentPortion.c \
Component.c \
Invoke.c \
Parameter.c \
ReturnResult.c \
ReturnError.c \
Reject.c \
InvokeIdType.c \
OPERATION.c \
ERROR.c \
GeneralProblem.c \
InvokeProblem.c \
ReturnResultProblem.c \
ReturnErrorProblem.c \
ErrorCode.c
lib_LTLIBRARIES=libosmo-asn1-tcap.la