renamed xml plugin to smp to avoid confusion

added some dependency checks to configure
configure checks ClearSilver and fastcgi
cleanups in the build system here and there
This commit is contained in:
Martin Willi
2008-03-28 12:44:01 +00:00
parent 892fb43b12
commit 6b9290ff12
11 changed files with 467 additions and 431 deletions
+18 -10
View File
@@ -91,6 +91,14 @@ credentials/sets/ocsp_response_wrapper.c credentials/sets/ocsp_response_wrapper.
credentials/sets/cert_cache.c credentials/sets/cert_cache.h \
credentials/credential_set.h
INCLUDES = -I${linuxdir} -I$(top_srcdir)/src/libstrongswan -I$(top_srcdir)/src/charon
AM_CFLAGS = -rdynamic -DIPSEC_DIR=\"${ipsecdir}\" \
-DIPSEC_PIDDIR=\"${piddir}\" -DIPSEC_PLUGINDIR=\"${plugindir}\"
charon_LDADD = $(top_builddir)/src/libstrongswan/libstrongswan.la -lpthread -lm -ldl
# compile options
#################
# Use RAW socket if pluto gets built
if USE_PLUTO
charon_SOURCES += network/socket-raw.c
@@ -99,6 +107,7 @@ else
endif
if USE_ME
AM_CFLAGS += -DME
charon_SOURCES += encoding/payloads/endpoint_notify.c encoding/payloads/endpoint_notify.h \
processing/jobs/initiate_mediation_job.c processing/jobs/initiate_mediation_job.h \
processing/jobs/mediation_job.c processing/jobs/mediation_job.h \
@@ -107,10 +116,13 @@ if USE_ME
sa/tasks/ike_me.c sa/tasks/ike_me.h
endif
INCLUDES = -I${linuxdir} -I$(top_srcdir)/src/libstrongswan -I$(top_srcdir)/src/charon
AM_CFLAGS = -rdynamic -DIPSEC_DIR=\"${ipsecdir}\" \
-DIPSEC_PIDDIR=\"${piddir}\" -DIPSEC_PLUGINDIR=\"${plugindir}\"
charon_LDADD = $(top_builddir)/src/libstrongswan/libstrongswan.la -lpthread -lm -ldl
if USE_INTEGRITY_TEST
AM_CFLAGS += -DINTEGRITY_TEST
endif
if USE_SELF_TEST
AM_CFLAGS += -DSELF_TEST
endif
# build optional plugins
########################
@@ -125,12 +137,8 @@ if USE_STROKE
SUBDIRS += plugins/stroke
endif
if USE_LIBDBUS
SUBDIRS += plugins/dbus
endif
if USE_LIBXML
SUBDIRS += plugins/xml
if USE_SMP
SUBDIRS += plugins/smp
endif
if USE_SQL
+10
View File
@@ -0,0 +1,10 @@
INCLUDES = -I$(top_srcdir)/src/libstrongswan -I$(top_srcdir)/src/charon ${xml_CFLAGS}
AM_CFLAGS = -rdynamic -DIPSEC_PIDDIR=\"${piddir}\"
plugin_LTLIBRARIES = libcharon-smp.la
libcharon_smp_la_SOURCES = smp.h smp.c
libcharon_smp_la_LDFLAGS = -module
libcharon_smp_la_LIBADD = ${xml_LIBS}
@@ -17,7 +17,7 @@
#include <stdlib.h>
#include "xml.h"
#include "smp.h"
#include <sys/types.h>
#include <sys/stat.h>
@@ -35,17 +35,17 @@
#include <processing/jobs/callback_job.h>
typedef struct private_xml_t private_xml_t;
typedef struct private_smp_t private_smp_t;
/**
* Private data of an xml_t object.
* Private data of an smp_t object.
*/
struct private_xml_t {
struct private_smp_t {
/**
* Public part of xml_t object.
* Public part of smp_t object.
*/
xml_t public;
smp_t public;
/**
* XML unix socket fd
@@ -662,7 +662,7 @@ static job_requeue_t process(int *fdp)
/**
* accept from XML socket and create jobs to process connections
*/
static job_requeue_t dispatch(private_xml_t *this)
static job_requeue_t dispatch(private_smp_t *this)
{
struct sockaddr_un strokeaddr;
int oldstate, fd, *fdp, strokeaddrlen = sizeof(strokeaddr);
@@ -691,7 +691,7 @@ static job_requeue_t dispatch(private_xml_t *this)
/**
* Implementation of itnerface_t.destroy.
*/
static void destroy(private_xml_t *this)
static void destroy(private_smp_t *this)
{
this->job->cancel(this->job);
close(this->socket);
@@ -704,7 +704,7 @@ static void destroy(private_xml_t *this)
plugin_t *plugin_create()
{
struct sockaddr_un unix_addr = { AF_UNIX, IPSEC_PIDDIR "/charon.xml"};
private_xml_t *this = malloc_thing(private_xml_t);
private_smp_t *this = malloc_thing(private_smp_t);
mode_t old;
this->public.plugin.destroy = (void (*)(plugin_t*))destroy;
@@ -16,27 +16,27 @@
*/
/**
* @defgroup xml xml
* @defgroup smp smp
* @ingroup cplugins
*
* @defgroup xml_i xml
* @{ @ingroup xml
* @defgroup smp_i smp
* @{ @ingroup smp
*/
#ifndef XML_H_
#define XML_H_
#ifndef SMP_H_
#define SMP_H_
#include <plugins/plugin.h>
typedef struct xml_t xml_t;
typedef struct smp_t smp_t;
/**
* XML configuration and control interface.
* SMP configuration and control interface.
*
* The XML interface uses a socket and a to communicate. The syntax is strict
* The SMP interface uses a socket and a to communicate. The syntax is strict
* XML, defined in the schema.xml specification.
*/
struct xml_t {
struct smp_t {
/**
* implements the plugin interface.
@@ -45,7 +45,7 @@ struct xml_t {
};
/**
* Create a xml plugin instance.
* Create a smp plugin instance.
*/
plugin_t *plugin_create();
+1 -1
View File
@@ -78,7 +78,7 @@ static traffic_selector_t *build_traffic_selector(private_sql_config_t *this,
*local = TRUE;
/* FALL */
case TS_REMOTE_DYNAMIC:
ts = traffic_selector_create_dynamic(protocol, type,
ts = traffic_selector_create_dynamic(protocol,
start_port, end_port);
break;
default:
-10
View File
@@ -1,10 +0,0 @@
INCLUDES = -I$(top_srcdir)/src/libstrongswan -I$(top_srcdir)/src/charon ${xml_CFLAGS}
AM_CFLAGS = -rdynamic -DIPSEC_PIDDIR=\"${piddir}\"
plugin_LTLIBRARIES = libcharon-xml.la
libcharon_xml_la_SOURCES = xml.h xml.c
libcharon_xml_la_LDFLAGS = -module
libcharon_xml_la_LIBADD = ${xml_LIBS}