Commit f54825cc243f068eba3250ea5ec8fdbdf970602a

Authored by aurel32
1 parent 475dc65f

consolidate definition for tap script and smb support

Since the introduction of net.c in r5581 there had been 2 places where
the location of the TAP helper scripts and SMB daemon are defined.

The following patch move those definitions to net.h so they are accessible
for net.c and vl.c but defined only once

(Carlo Marcelo Arenas Belon)

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6093 c046a42c-6fe2-441c-8c8c-71466251a162
Showing 3 changed files with 8 additions and 16 deletions
... ... @@ -120,14 +120,6 @@
120 120 #define memalign(align, size) malloc(size)
121 121 #endif
122 122  
123   -#define DEFAULT_NETWORK_SCRIPT "/etc/qemu-ifup"
124   -#define DEFAULT_NETWORK_DOWN_SCRIPT "/etc/qemu-ifdown"
125   -#ifdef __sun__
126   -#define SMBD_COMMAND "/usr/sfw/sbin/smbd"
127   -#else
128   -#define SMBD_COMMAND "/usr/sbin/smbd"
129   -#endif
130   -
131 123 static VLANState *first_vlan;
132 124  
133 125 /***********************************************************/
... ...
... ... @@ -85,4 +85,12 @@ void net_cleanup(void);
85 85 int slirp_is_inited(void);
86 86 void net_client_check(void);
87 87  
  88 +#define DEFAULT_NETWORK_SCRIPT "/etc/qemu-ifup"
  89 +#define DEFAULT_NETWORK_DOWN_SCRIPT "/etc/qemu-ifdown"
  90 +#ifdef __sun__
  91 +#define SMBD_COMMAND "/usr/sfw/sbin/smbd"
  92 +#else
  93 +#define SMBD_COMMAND "/usr/sbin/smbd"
  94 +#endif
  95 +
88 96 #endif
... ...
... ... @@ -149,14 +149,6 @@
149 149  
150 150 #include "exec-all.h"
151 151  
152   -#define DEFAULT_NETWORK_SCRIPT "/etc/qemu-ifup"
153   -#define DEFAULT_NETWORK_DOWN_SCRIPT "/etc/qemu-ifdown"
154   -#ifdef __sun__
155   -#define SMBD_COMMAND "/usr/sfw/sbin/smbd"
156   -#else
157   -#define SMBD_COMMAND "/usr/sbin/smbd"
158   -#endif
159   -
160 152 //#define DEBUG_UNUSED_IOPORT
161 153 //#define DEBUG_IOPORT
162 154 //#define DEBUG_NET
... ...