summary refs log tree commit diff
path: root/pkgs/os-specific/linux/gogoclient
diff options
context:
space:
mode:
authorPeter Simons <simons@cryp.to>2012-02-28 00:10:05 +0000
committerPeter Simons <simons@cryp.to>2012-02-28 00:10:05 +0000
commit10e512f2b8b1426bf5e2238a7ff97e6785b719af (patch)
tree2b4159e9d8498c14d87315484fe61bda7511c87e /pkgs/os-specific/linux/gogoclient
parentb2356973fe8b6709e86275e57aa03db1e956121e (diff)
downloadnixlib-10e512f2b8b1426bf5e2238a7ff97e6785b719af.tar
nixlib-10e512f2b8b1426bf5e2238a7ff97e6785b719af.tar.gz
nixlib-10e512f2b8b1426bf5e2238a7ff97e6785b719af.tar.bz2
nixlib-10e512f2b8b1426bf5e2238a7ff97e6785b719af.tar.lz
nixlib-10e512f2b8b1426bf5e2238a7ff97e6785b719af.tar.xz
nixlib-10e512f2b8b1426bf5e2238a7ff97e6785b719af.tar.zst
nixlib-10e512f2b8b1426bf5e2238a7ff97e6785b719af.zip
gogoclient: ipv6 tunnel
svn path=/nixpkgs/trunk/; revision=32668
Diffstat (limited to 'pkgs/os-specific/linux/gogoclient')
-rw-r--r--pkgs/os-specific/linux/gogoclient/config-paths.patch39
-rw-r--r--pkgs/os-specific/linux/gogoclient/default.nix38
-rw-r--r--pkgs/os-specific/linux/gogoclient/gcc46-include-fix.patch22
3 files changed, 99 insertions, 0 deletions
diff --git a/pkgs/os-specific/linux/gogoclient/config-paths.patch b/pkgs/os-specific/linux/gogoclient/config-paths.patch
new file mode 100644
index 000000000000..88358038bc7e
--- /dev/null
+++ b/pkgs/os-specific/linux/gogoclient/config-paths.patch
@@ -0,0 +1,39 @@
+diff -urN gogoc-1_2-RELEASE/gogoc-tsp/conf/gogoc.conf.in gogoc-1_2-RELEASE-fix/gogoc-tsp/conf/gogoc.conf.in
+--- gogoc-1_2-RELEASE/gogoc-tsp/conf/gogoc.conf.in	2009-11-20 17:53:12.000000000 +0100
++++ gogoc-1_2-RELEASE-fix/gogoc-tsp/conf/gogoc.conf.in	2012-02-25 15:16:12.758849219 +0100
+@@ -224,7 +224,7 @@
+ #
+ #   broker_list=<file_name>
+ #  
+-broker_list=tsp-broker-list.txt
++broker_list=/var/lib/gogoc/tsp-broker-list.txt
+ 
+ #
+ # Last Server Used File Name:
+@@ -234,7 +234,7 @@
+ #
+ #   last_server=<file_name>
+ #
+-last_server=tsp-last-server.txt
++last_server=/var/lib/gogoc/tsp-last-server.txt
+ 
+ #
+ # Always Use Last Known Working Server:
+@@ -294,7 +294,7 @@
+ #
+ #   log_filename=<file_name>
+ #
+-log_filename=gogoc.log
++log_filename=/var/log/gogoc.log
+ 
+ #
+ # Log File Rotation:
+@@ -313,7 +313,7 @@
+ #
+ #   log_rotation=<yes|no>
+ #
+-log_rotation=yes
++log_rotation=no
+ 
+ #
+ # Log File Rotation Size:
diff --git a/pkgs/os-specific/linux/gogoclient/default.nix b/pkgs/os-specific/linux/gogoclient/default.nix
new file mode 100644
index 000000000000..d1a4bf9feb65
--- /dev/null
+++ b/pkgs/os-specific/linux/gogoclient/default.nix
@@ -0,0 +1,38 @@
+{stdenv, fetchurl, openssl, nettools, iproute, procps}:
+
+let baseName = "gogoclient";
+    version  = "1.2";
+in
+
+stdenv.mkDerivation rec {
+  name = "${baseName}-${version}";
+
+  src = fetchurl {
+    url = http://gogo6.com/downloads/gogoc-1_2-RELEASE.tar.gz;
+    sha256 = "a0ef45c0bd1fc9964dc8ac059b7d78c12674bf67ef641740554e166fa99a2f49";
+  };
+  patches = [./gcc46-include-fix.patch ./config-paths.patch ];
+  makeFlags = ["target=linux"];
+  installFlags = ["installdir=$(out)"];
+
+  buildInputs = [openssl];
+
+  preFixup = ''
+    ensureDir $out/share/${name}
+    chmod 444 $out/bin/gogoc.conf
+    mv $out/bin/gogoc.conf $out/share/${name}/gogoc.conf.sample
+    rm $out/bin/gogoc.conf.sample
+
+    substituteInPlace "$out/template/linux.sh" \
+      --replace "/sbin/ifconfig" "${nettools}/sbin/ifconfig" \
+      --replace "/sbin/route"    "${nettools}/sbin/route" \
+      --replace "/sbin/ip"       "${iproute}/sbin/ip" \
+      --replace "/sbin/sysctl"   "${procps}/sbin/sysctl"
+  '';
+
+  meta = {
+    homepage = http://gogonet.gogo6.com;
+    description = "Client to connect to the Freenet6 IPv6 tunnel broker service";
+    maintainers = [stdenv.lib.maintainers.bluescreen303];
+  };
+}
diff --git a/pkgs/os-specific/linux/gogoclient/gcc46-include-fix.patch b/pkgs/os-specific/linux/gogoclient/gcc46-include-fix.patch
new file mode 100644
index 000000000000..22ecad187d62
--- /dev/null
+++ b/pkgs/os-specific/linux/gogoclient/gcc46-include-fix.patch
@@ -0,0 +1,22 @@
+diff -urN gogoc-1_2-RELEASE/gogoc-messaging/src/clientmsgsender.cc gogoc-1_2-RELEASE-fix/gogoc-messaging/src/clientmsgsender.cc
+--- gogoc-1_2-RELEASE/gogoc-messaging/src/clientmsgsender.cc	2009-11-20 17:34:55.000000000 +0100
++++ gogoc-1_2-RELEASE-fix/gogoc-messaging/src/clientmsgsender.cc	2012-02-25 15:06:20.764698284 +0100
+@@ -15,6 +15,7 @@
+ // **************************************************************************
+ #include <gogocmessaging/clientmsgsender.h>
+ #include <assert.h>
++#include <stddef.h>
+ 
+ 
+ namespace gogocmessaging
+diff -urN gogoc-1_2-RELEASE/gogoc-messaging/src/servermsgsender.cc gogoc-1_2-RELEASE-fix/gogoc-messaging/src/servermsgsender.cc
+--- gogoc-1_2-RELEASE/gogoc-messaging/src/servermsgsender.cc	2009-11-20 17:34:56.000000000 +0100
++++ gogoc-1_2-RELEASE-fix/gogoc-messaging/src/servermsgsender.cc	2012-02-25 15:06:36.722740288 +0100
+@@ -15,6 +15,7 @@
+ // **************************************************************************
+ #include <gogocmessaging/servermsgsender.h>
+ #include <assert.h>
++#include <stddef.h>
+ 
+ 
+ namespace gogocmessaging