Skip to contentSkip to conversation

svn commit: trunk/buildroot/package: openswan

Buildroot aldot at uclibc.org 1 participant 1 message Nov 28, 2006

lore
Share & tools
lore
#0 lore raw

Author: aldot
Date: 2006-11-28 08:59:17 -0800 (Tue, 28 Nov 2006) New Revision: 16707

Log:
- add openswan support. Compile tested only. Closes #200.

Added:
trunk/buildroot/package/openswan/ trunk/buildroot/package/openswan/Config.in trunk/buildroot/package/openswan/openswan-2.4.7-001-oswlog.patch trunk/buildroot/package/openswan/openswan-2.4.7-002-oswlog.patch trunk/buildroot/package/openswan/openswan-2.4.7-003-spi.patch trunk/buildroot/package/openswan/openswan-2.4.7-004-alloc.patch trunk/buildroot/package/openswan/openswan-2.4.7-005-pluto.patch trunk/buildroot/package/openswan/openswan-2.4.7-006-linux-include.patch trunk/buildroot/package/openswan/openswan.mk

Modified:
trunk/buildroot/package/Config.in

Changeset:
Modified: trunk/buildroot/package/Config.in
===================================================================

buildroot/package/Config.in +3 -0
@@ -51,6 +51,8 @@
 source "package/file/Config.in"
 source "package/freetype/Config.in"
 source "package/gettext/Config.in"
+source "package/gmp/Config.in"
+source "package/mpfr/Config.in"
 source "package/gzip/Config.in"
 source "package/haserl/Config.in"
 source "package/hdparm/Config.in"
@@ -108,6 +110,7 @@
 source "package/openssh/Config.in"
 source "package/openssl/Config.in"
 source "package/openvpn/Config.in"
+source "package/openswan/Config.in"
 source "package/pciutils/Config.in"
 source "package/pcmcia/Config.in"
 source "package/pkgconfig/Config.in"

Added: trunk/buildroot/package/openswan/Config.in
===================================================================

buildroot/package/openswan/Config.in +9 -0
@@ -0,0 +1,9 @@
+config BR2_PACKAGE_OPENSWAN
+        bool "openswan"
+        default n
+        select BR2_PACKAGE_LIBGMP
+        select BR2_PACKAGE_MICROPERL
+        help
+	  Openswan is an implementation of IPsec for Linux.
+          http://openswan.org/
+

Added: trunk/buildroot/package/openswan/openswan-2.4.7-001-oswlog.patch
===================================================================

buildroot/package/openswan/openswan-2.4.7-001-oswlog.patch +30 -0
@@ -0,0 +1,30 @@
+--- openswan-2.4.7.orig/lib/libopenswan/oswlog.c	2004-10-17 01:42:13.000000000 +0200
++++ openswan-2.4.7/lib/libopenswan/oswlog.c	2006-11-28 16:08:18.000000000 +0100
+@@ -41,9 +41,11 @@ bool
+ bool
+     logged_txt_warning = FALSE;  /* should we complain about finding KEY? */
+ 
++#if !defined(NO_DEBUG)
+ void openswanlib_passert_fail(const char *pred_str, const char *file_str,
+ 			      unsigned long line_no);
+ openswan_passert_fail_t openswan_passert_fail = openswanlib_passert_fail;
++#endif /* NO_DEBUG */
+ 
+ void
+ tool_init_log(void)
+@@ -104,6 +106,7 @@ openswan_log(const char *message, ...)
+ 	syslog(LOG_WARNING, "%s", m);
+ }
+ 
++#if !defined(NO_DEBUG)
+ void
+ openswan_loglog(int mess_no, const char *message, ...)
+ {
+@@ -119,6 +122,7 @@ openswan_loglog(int mess_no, const char 
+     if (log_to_syslog)
+ 	syslog(LOG_WARNING, "%s", m);
+ }
++#endif
+ 
+ void
+ openswan_log_errno_routine(int e, const char *message, ...)

Added: trunk/buildroot/package/openswan/openswan-2.4.7-002-oswlog.patch
===================================================================

buildroot/package/openswan/openswan-2.4.7-002-oswlog.patch +34 -0
@@ -0,0 +1,34 @@
+diff -urp openswan-2.4.7.orig/include/oswlog.h openswan-2.4.7/include/oswlog.h
+--- openswan-2.4.7.orig/include/oswlog.h	2005-01-26 01:52:16.000000000 +0100
++++ openswan-2.4.7/include/oswlog.h	2006-11-28 17:56:59.000000000 +0100
+@@ -53,6 +53,16 @@ extern void tool_close_log(void);
+ #else /*!DEBUG*/
+ 
+ #define DBG(cond, action)	{ }	/* do nothing */
++#define DBGP(...) (0)
++#define exit_tool exit
++#define loglog(...) do { } while(0)
++#define openswan_loglog(...) do { } while(0)
++#define openswan_DBG_dump(...) do { } while(0)
++#define plog    openswan_log
++extern void openswan_log(const char *message, ...) PRINTF_LIKE(1);
++#define DBG_log(...) do { } while(0)
++extern void tool_init_log(void);
++extern void tool_close_log(void);
+ 
+ #endif /*!DEBUG*/
+ 
+diff -urp openswan-2.4.7.orig/include/pluto_constants.h openswan-2.4.7/include/pluto_constants.h
+--- openswan-2.4.7.orig/include/pluto_constants.h	2005-11-16 23:41:30.000000000 +0100
++++ openswan-2.4.7/include/pluto_constants.h	2006-11-28 17:34:20.000000000 +0100
+@@ -175,6 +175,10 @@ extern const char *const debug_bit_names
+ 
+ #define DBG_NONE	0	/* no options on, including impairments */
+ #define DBG_ALL		LRANGES(DBG_RAW, DBG_X509)  /* all logging options on EXCEPT DBG_PRIVATE */
++#else
++/* FIXME: better cleanup ac.c instead of this */
++#define DBG_RAW         LELEM(0)
++#define DBG_PRIVATE     LELEM(20)
+ #endif
+ 
+ /* State of exchanges

Added: trunk/buildroot/package/openswan/openswan-2.4.7-003-spi.patch
===================================================================

buildroot/package/openswan/openswan-2.4.7-003-spi.patch +12 -0
@@ -0,0 +1,12 @@
+--- openswan-2.4.7.orig/programs/spi/spi.c	2006-02-15 05:36:36.000000000 +0100
++++ openswan-2.4.7/programs/spi/spi.c	2006-11-28 15:52:41.000000000 +0100
+@@ -538,7 +538,9 @@ main(int argc, char *argv[])
+ 		case 'g':
+ 			debug = 1;
+ 			pfkey_lib_debug = PF_KEY_DEBUG_PARSE_MAX;
++#if !defined(NO_DEBUG)
+ 			cur_debugging = 0xffffffff;
++#endif
+ 			argcount--;
+ 			break;
+ 

Added: trunk/buildroot/package/openswan/openswan-2.4.7-004-alloc.patch
===================================================================

buildroot/package/openswan/openswan-2.4.7-004-alloc.patch +12 -0
@@ -0,0 +1,12 @@
+--- openswan-2.4.7.orig/lib/libopenswan/alloc.c	2004-10-17 01:42:13.000000000 +0200
++++ openswan-2.4.7/lib/libopenswan/alloc.c	2006-11-28 16:06:27.000000000 +0100
+@@ -26,7 +26,9 @@
+ #include "constants.h"
+ #include "oswlog.h"
+ 
++#if !defined(NO_DEBUG)
+ #define LEAK_DETECTIVE
++#endif
+ #include "oswalloc.h"
+ 
+ const chunk_t empty_chunk = { NULL, 0 };

Added: trunk/buildroot/package/openswan/openswan-2.4.7-005-pluto.patch
===================================================================

buildroot/package/openswan/openswan-2.4.7-005-pluto.patch +207 -0

207 lines not on this page · raw message

Added: trunk/buildroot/package/openswan/openswan-2.4.7-006-linux-include.patch
===================================================================

buildroot/package/openswan/openswan-2.4.7-006-linux-include.patch +12 -0
@@ -0,0 +1,12 @@
+diff -urp openswan-2.4.7.orig/linux/include/openswan/passert.h openswan-2.4.7/linux/include/openswan/passert.h
+--- openswan-2.4.7.orig/linux/include/openswan/passert.h	2004-10-21 20:44:42.000000000 +0200
++++ openswan-2.4.7/linux/include/openswan/passert.h	2006-11-28 17:50:03.000000000 +0100
+@@ -69,7 +69,7 @@ extern void switch_fail(int n
+ # define bad_case(n) abort()
+ # define passert(pred)  { }	/* do nothing */
+ # define happy(x)  { (void) x; }	/* evaluate non-judgementally */
+-
++# define pexpect(x) do { } while(0)
+ #endif /*!DEBUG*/
+ 
+ #endif /* _OPENSWAN_PASSERT_H */

Added: trunk/buildroot/package/openswan/openswan.mk
===================================================================

buildroot/package/openswan/openswan.mk +61 -0

61 lines not on this page · raw message