This commit is contained in:
parent
bf656ecd40
commit
4f9a60d955
14
net-tools-1.60-ifconfig.8.diff
Normal file
14
net-tools-1.60-ifconfig.8.diff
Normal file
@ -0,0 +1,14 @@
|
||||
--- net-tools-1.60/man/en_US/ifconfig.8 2000-10-28 12:59:42.000000000 +0200
|
||||
+++ net-tools-1.60/man/en_US/ifconfig.8 2008-03-02 18:03:05.954727145 +0100
|
||||
@@ -11,6 +11,11 @@
|
||||
used at boot time to set up interfaces as necessary. After that, it
|
||||
is usually only needed when debugging or when system tuning is needed.
|
||||
.LP
|
||||
+.B WARNING:
|
||||
+.B Ifconfig
|
||||
+is obsolete on system with Linux kernel newer than 2.0. On this system
|
||||
+you should use ip. See the ip manual page for details
|
||||
+.LP
|
||||
If no arguments are given,
|
||||
.B ifconfig
|
||||
displays the status of the currently active interfaces. If
|
@ -1,5 +1,5 @@
|
||||
--- Makefile
|
||||
+++ Makefile 2006/07/24 07:44:14
|
||||
+++ Makefile 2008/03/07 12:14:02
|
||||
@@ -90,7 +90,7 @@
|
||||
# You may need to uncomment and edit these if you are using libc5 and IPv6.
|
||||
COPTS = -D_GNU_SOURCE -O2 -Wall -g # -I/usr/inet6/include
|
||||
@ -19,7 +19,7 @@
|
||||
update: all installbin installdata
|
||||
|
||||
--- config.in
|
||||
+++ config.in 2006/07/24 07:44:14
|
||||
+++ config.in 2008/03/07 12:14:02
|
||||
@@ -42,14 +42,14 @@
|
||||
* course, welcome. Answer `n' here if you have no support for
|
||||
* internationalization on your system.
|
||||
@ -61,7 +61,7 @@
|
||||
+bool 'Build iptunnel and ipmaddr' HAVE_IP_TOOLS y
|
||||
+bool 'Build mii-tool' HAVE_MII y
|
||||
--- configure.sh
|
||||
+++ configure.sh 2006/07/24 07:44:14
|
||||
+++ configure.sh 2008/03/07 12:14:02
|
||||
@@ -58,9 +58,8 @@
|
||||
#
|
||||
function readln()
|
||||
@ -75,7 +75,7 @@
|
||||
|
||||
# bool processes a boolean argument
|
||||
--- lib/inet6_gr.c
|
||||
+++ lib/inet6_gr.c 2006/07/24 07:44:14
|
||||
+++ lib/inet6_gr.c 2008/03/07 12:14:02
|
||||
@@ -34,6 +34,10 @@
|
||||
|
||||
/* neighbour discovery from linux-2.4.0/include/net/neighbour.h */
|
||||
@ -88,7 +88,7 @@
|
||||
#define NUD_REACHABLE 0x02
|
||||
#define NUD_STALE 0x04
|
||||
--- lib/inet_sr.c
|
||||
+++ lib/inet_sr.c 2006/07/24 07:44:14
|
||||
+++ lib/inet_sr.c 2008/03/07 12:14:02
|
||||
@@ -40,6 +40,10 @@
|
||||
#define full_mask(x) (((struct sockaddr_in *)&(x))->sin_addr.s_addr)
|
||||
#endif
|
||||
@ -100,8 +100,61 @@
|
||||
extern struct aftype inet_aftype;
|
||||
|
||||
static int skfd = -1;
|
||||
--- lib/interface.c
|
||||
+++ lib/interface.c 2008/03/07 12:14:02
|
||||
@@ -86,6 +86,7 @@
|
||||
int procnetdev_vsn = 1;
|
||||
|
||||
int ife_short;
|
||||
+int ife_field = 5;
|
||||
|
||||
static struct interface *int_list, *int_last;
|
||||
|
||||
@@ -139,6 +140,22 @@
|
||||
return 0;
|
||||
}
|
||||
|
||||
+void get_max_ifacename(void)
|
||||
+{
|
||||
+ struct interface *ife;
|
||||
+ int tmp = ife_field;
|
||||
+
|
||||
+ if (!int_list && (if_readlist(0) < 0)) {
|
||||
+ return;
|
||||
+ }
|
||||
+ for (ife = int_list; ife; ife = ife->next) {
|
||||
+ tmp = strlen (ife->name);
|
||||
+ if (tmp > ife_field) {
|
||||
+ ife_field = tmp;
|
||||
+ }
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
int free_interface_list(void)
|
||||
{
|
||||
struct interface *ife;
|
||||
@@ -579,7 +596,7 @@
|
||||
|
||||
void ife_print_short(struct interface *ptr)
|
||||
{
|
||||
- printf("%-5.5s ", ptr->name);
|
||||
+ printf("%-*.*s ", ife_field,ife_field,ptr->name);
|
||||
printf("%5d %3d", ptr->mtu, ptr->metric);
|
||||
/* If needed, display the interface statistics. */
|
||||
if (ptr->statistics_valid) {
|
||||
@@ -670,7 +687,9 @@
|
||||
if (hw == NULL)
|
||||
hw = get_hwntype(-1);
|
||||
|
||||
- printf(_("%-9.9s Link encap:%s "), ptr->name, hw->title);
|
||||
+ printf(_("%-*.*s Link encap:%s "),
|
||||
+ ife_field+4,ife_field+4,ptr->name, hw->title
|
||||
+ );
|
||||
/* For some hardware types (eg Ash, ATM) we don't print the
|
||||
hardware address if it's null. */
|
||||
if (hw->print != NULL && (! (hw_null_address(hw, ptr->hwaddr) &&
|
||||
--- netstat.c
|
||||
+++ netstat.c 2006/07/24 07:44:14
|
||||
+++ netstat.c 2008/03/07 12:14:13
|
||||
@@ -117,6 +117,10 @@
|
||||
#define SO_WAITDATA (1<<17) /* wait data to read */
|
||||
#define SO_NOSPACE (1<<18) /* no space to write */
|
||||
@ -113,8 +166,17 @@
|
||||
#define DFLT_AF "inet"
|
||||
|
||||
#define FEATURE_NETSTAT
|
||||
@@ -1452,6 +1456,8 @@
|
||||
printf(_("Iface MTU Met RX-OK RX-ERR RX-DRP RX-OVR TX-OK TX-ERR TX-DRP TX-OVR Flg\n"));
|
||||
}
|
||||
|
||||
+ get_max_ifacename();
|
||||
+
|
||||
if (for_all_interfaces(do_if_print, &flag_all) < 0) {
|
||||
perror(_("missing interface information"));
|
||||
exit(1);
|
||||
--- po/de.po
|
||||
+++ po/de.po 2006/07/24 07:48:22
|
||||
+++ po/de.po 2008/03/07 12:14:02
|
||||
@@ -2148,7 +2148,7 @@
|
||||
"Source Destination Gateway Flags Metric Ref Use "
|
||||
"Iface\n"
|
||||
|
@ -1,3 +1,13 @@
|
||||
-------------------------------------------------------------------
|
||||
Thu Mar 6 18:02:43 CET 2008 - ms@suse.de
|
||||
|
||||
- fixed length of interface field (bnc #367769)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Mar 4 10:30:18 CET 2008 - ms@suse.de
|
||||
|
||||
- added obsolete warning for ifconfig into man page (bnc #366477)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sun Feb 24 22:03:41 CET 2008 - crrodriguez@suse.de
|
||||
|
||||
|
@ -21,7 +21,7 @@ Provides: iputils:/usr/share/man/man8/traceroute6.1.gz
|
||||
Obsoletes: traceroute net_tool
|
||||
AutoReqProv: on
|
||||
Version: 1.60
|
||||
Release: 672
|
||||
Release: 674
|
||||
Summary: Important Programs for Networking
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
Source: net-tools-%{version}.tar.bz2
|
||||
@ -56,6 +56,7 @@ Patch26: net-tools-1.60-sctp-quiet
|
||||
Patch27: net-tools-1.60-hostname-space.patch
|
||||
Patch28: traceroute-strip.diff
|
||||
Patch29: traceroute-maxprobes.diff
|
||||
Patch30: net-tools-1.60-ifconfig.8.diff
|
||||
|
||||
%description
|
||||
This package contains essential programs for network administration and
|
||||
@ -104,6 +105,7 @@ cd ..
|
||||
%patch25 -p1
|
||||
%patch26 -p1
|
||||
%patch27 -p1
|
||||
%patch30 -p1
|
||||
|
||||
%build
|
||||
make config
|
||||
@ -157,6 +159,10 @@ rm -rf $RPM_BUILD_ROOT
|
||||
%lang(pt_BR) %doc %_mandir/pt_BR/man*/*
|
||||
|
||||
%changelog
|
||||
* Thu Mar 06 2008 ms@suse.de
|
||||
- fixed length of interface field (bnc #367769)
|
||||
* Tue Mar 04 2008 ms@suse.de
|
||||
- added obsolete warning for ifconfig into man page (bnc #366477)
|
||||
* Sun Feb 24 2008 crrodriguez@suse.de
|
||||
- use find_lang macro
|
||||
* Wed Jul 25 2007 ms@suse.de
|
||||
|
Loading…
Reference in New Issue
Block a user