]> git.pld-linux.org Git - packages/wpa_supplicant.git/commitdiff
- TODO item
authorPaweł Gołaszewski <blues@pld-linux.org>
Fri, 3 Dec 2010 18:27:43 +0000 (18:27 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    wpa_supplicant-syslog-support.patch -> 1.1
    wpa_supplicant.spec -> 1.76

wpa_supplicant-syslog-support.patch [new file with mode: 0644]
wpa_supplicant.spec

diff --git a/wpa_supplicant-syslog-support.patch b/wpa_supplicant-syslog-support.patch
new file mode 100644 (file)
index 0000000..1a44b30
--- /dev/null
@@ -0,0 +1,143 @@
+Index: wpa_supplicant/main.c
+===================================================================
+RCS file: /cvs/hostap/wpa_supplicant/main.c,v
+retrieving revision 1.14
+diff -u -r1.14 main.c
+--- wpa_supplicant/main.c      3 Dec 2005 18:33:07 -0000       1.14
++++ wpa_supplicant/main.c      12 Feb 2006 00:54:28 -0000
+@@ -33,13 +33,12 @@
+ extern struct wpa_driver_ops *wpa_supplicant_drivers[];
+-
+ static void usage(void)
+ {
+       int i;
+       printf("%s\n\n%s\n"
+              "usage:\n"
+-             "  wpa_supplicant [-BddehLqqvwW] [-P<pid file>] "
++             "  wpa_supplicant [-BddehlLqqsvwW] [-P<pid file>] "
+              "[-g<global ctrl>] \\\n"
+              "        -i<ifname> -c<config file> [-C<ctrl>] [-D<driver>] "
+              "[-p<driver_param>] \\\n"
+@@ -67,10 +66,12 @@
+              "  -K = include keys (passwords, etc.) in debug output\n"
+              "  -t = include timestamp in debug messages\n"
+              "  -h = show this help text\n"
++             "  -l = log file\n"
+              "  -L = show license (GPL and BSD)\n");
+       printf("  -p = driver parameters\n"
+              "  -P = PID file\n"
+              "  -q = decrease debugging verbosity (-qq even less)\n"
++             "  -s = log to syslog\n"
+              "  -v = show version\n"
+              "  -w = wait for interface to be added, if needed\n"
+              "  -W = wait for a control interface monitor before starting\n"
+@@ -139,7 +140,7 @@
+       wpa_supplicant_fd_workaround();
+       for (;;) {
+-              c = getopt(argc, argv, "Bc:C:D:dg:hi:KLNp:P:qtvwW");
++              c = getopt(argc, argv, "Bc:C:D:dg:hi:Kl:LNp:P:qstvwW");
+               if (c < 0)
+                       break;
+               switch (c) {
+@@ -177,6 +178,16 @@
+               case 'K':
+                       params.wpa_debug_show_keys++;
+                       break;
++              case 'l':
++#ifdef CONFIG_NO_STDOUT_DEBUG
++                      printf("Logging disabled with "
++                             "CONFIG_NO_STDOUT_DEBUG=y build time "
++                             "option.\n");
++                      return -1;
++#else /* CONFIG_NO_STDOUT_DEBUG */
++                      params.log_file = os_rel2abs_path(optarg);
++                      break;
++#endif /* CONFIG_NO_STDOUT_DEBUG */
+               case 'L':
+                       license();
+                       return -1;
+@@ -189,6 +200,16 @@
+               case 'q':
+                       params.wpa_debug_level++;
+                       break;
++              case 's':
++#ifdef CONFIG_NO_STDOUT_DEBUG
++                      printf("Logging disabled with "
++                             "CONFIG_NO_STDOUT_DEBUG=y build time "
++                             "option.\n");
++                      return -1;
++#else /* CONFIG_NO_STDOUT_DEBUG */
++                      params.wpa_log_syslog++;
++                      break;
++#endif /* CONFIG_NO_STDOUT_DEBUG */
+               case 't':
+                       params.wpa_debug_timestamp++;
+                       break;
+Index: wpa_supplicant/wpa_supplicant.c
+===================================================================
+RCS file: /cvs/hostap/wpa_supplicant/wpa_supplicant.c,v
+retrieving revision 1.315
+diff -u -r1.315 wpa_supplicant.c
+--- wpa_supplicant/wpa_supplicant.c    30 Jan 2006 04:24:58 -0000      1.315
++++ wpa_supplicant/wpa_supplicant.c    12 Feb 2006 00:54:32 -0000
+@@ -13,6 +13,7 @@
+  */
+ #include "includes.h"
++#include <syslog.h>
+ #include "common.h"
+ #include "eapol_sm.h"
+@@ -103,6 +104,8 @@
+ extern int wpa_debug_level;
+ extern int wpa_debug_show_keys;
+ extern int wpa_debug_timestamp;
++extern FILE *wpa_log_file;
++extern int wpa_log_syslog;
+ static void wpa_supplicant_scan(void *eloop_ctx, void *timeout_ctx);
+@@ -2098,6 +2101,16 @@
+               params->wpa_debug_show_keys;
+       wpa_debug_timestamp = global->params.wpa_debug_timestamp =
+               params->wpa_debug_timestamp;
++      if (params->log_file)
++      {
++              global->params.log_file = strdup(params->log_file);
++              wpa_log_file = fopen(params->log_file,"w");
++      }
++
++      wpa_log_syslog = global->params.wpa_log_syslog =
++              params->wpa_log_syslog;
++      if (wpa_log_syslog)
++              openlog("wpa_supplicant",0,LOG_DAEMON);
+       if (eloop_init(global)) {
+               wpa_printf(MSG_ERROR, "Failed to initialize event loop");
+Index: wpa_supplicant/wpa_supplicant_i.h
+===================================================================
+RCS file: /cvs/hostap/wpa_supplicant/wpa_supplicant_i.h,v
+retrieving revision 1.85
+diff -u -r1.85 wpa_supplicant_i.h
+--- wpa_supplicant/wpa_supplicant_i.h  8 Feb 2006 04:08:51 -0000       1.85
++++ wpa_supplicant/wpa_supplicant_i.h  12 Feb 2006 00:54:32 -0000
+@@ -137,6 +137,16 @@
+       int wpa_debug_timestamp;
+       /**
++       * log_file - log file name to write all messages into
++       */
++      char* log_file;
++
++      /**
++       * wpa_log_syslog - Wether to log message to syslog
++       */
++      int wpa_log_syslog;
++
++      /**
+        * ctrl_interface - Global ctrl_iface path/parameter
+        */
+       char *ctrl_interface;
index a3173c3fa502a12b0ed97c7b8f6b179efb843ae5..8c0d262985e42007dbe8d4e99a4e4b564cb4fd1e 100644 (file)
@@ -1,9 +1,9 @@
 # TODO:
-# - wpa_gui can be built with qt4 - bcond?
 # - icon for wpa_gui
 # - reverse madwifi bcond when appropriate packages will be available on ftp
 #      / as of madwifi-ng > r1499 and kernel > 2.6.14 wext driver could be
 #      used instead of madwifi - so madwifi bcond will become obsolete soon /
+# - syslog-support patch should be fixed and/or ripped from debian/ubuntu
 #
 # Conditional build
 %bcond_without dbus            # don't build D-BUS control interface
@@ -30,6 +30,7 @@ Source3:      %{name}-dbus.service
 Patch0:                %{name}-makefile.patch
 Patch1:                %{name}-OPTCFLAGS.patch
 Patch2:                %{name}-lrelease.patch
+Patch3:                %{name}-syslog-support.patch
 URL:           http://hostap.epitest.fi/wpa_supplicant/
 %{?with_dbus:BuildRequires:    dbus-devel}
 BuildRequires: libnl-devel
@@ -107,6 +108,7 @@ Graficzny interfejs suplikanta WPA/WPA2/RSN/IEEE 802.1X dla Linuksa.
 %patch0 -p1
 %patch1 -p1
 %patch2 -p0
+#patch3 -p0
 
 install %{SOURCE1} wpa_supplicant/.config
 
This page took 0.861633 seconds and 4 git commands to generate.