| 1 | 1 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,86 @@ |
| 0 |
+Originaly By: Zack Winkles <winkie AT linuxfromscratch DOT org> |
|
| 1 |
+Submitted By: Jim Gifford <jim AT linuxfromscratch DOT org> |
|
| 2 |
+Date: 2004-06-23 |
|
| 3 |
+Initial Package Version: 1.60 |
|
| 4 |
+Origin: N/A |
|
| 5 |
+Upstream Status: N/A |
|
| 6 |
+Description: Fix some occurrences of syntax that GCC 3.4 doesn't like. |
|
| 7 |
+ |
|
| 8 |
+diff -Naur net-tools-1.60.orig/hostname.c net-tools-1.60/hostname.c |
|
| 9 |
+--- net-tools-1.60.orig/hostname.c 2001-04-08 17:04:23.000000000 +0000 |
|
| 10 |
+@@ -78,6 +78,7 @@ |
|
| 11 |
+ fprintf(stderr, _("%s: name too long\n"), program_name);
|
|
| 12 |
+ break; |
|
| 13 |
+ default: |
|
| 14 |
++ ((void)0); |
|
| 15 |
+ } |
|
| 16 |
+ exit(1); |
|
| 17 |
+ } |
|
| 18 |
+@@ -98,6 +99,7 @@ |
|
| 19 |
+ fprintf(stderr, _("%s: name too long\n"), program_name);
|
|
| 20 |
+ break; |
|
| 21 |
+ default: |
|
| 22 |
++ ((void)0); |
|
| 23 |
+ } |
|
| 24 |
+ exit(1); |
|
| 25 |
+ }; |
|
| 26 |
+@@ -117,6 +119,7 @@ |
|
| 27 |
+ fprintf(stderr, _("%s: name too long\n"), program_name);
|
|
| 28 |
+ break; |
|
| 29 |
+ default: |
|
| 30 |
++ ((void)0); |
|
| 31 |
+ } |
|
| 32 |
+ exit(1); |
|
| 33 |
+ }; |
|
| 34 |
+@@ -174,6 +177,7 @@ |
|
| 35 |
+ printf("%s\n", hp->h_name);
|
|
| 36 |
+ break; |
|
| 37 |
+ default: |
|
| 38 |
++ ((void)0); |
|
| 39 |
+ } |
|
| 40 |
+ } |
|
| 41 |
+ |
|
| 42 |
+diff -Naur net-tools-1.60.orig/lib/inet_sr.c net-tools-1.60/lib/inet_sr.c |
|
| 43 |
+--- net-tools-1.60.orig/lib/inet_sr.c 2000-02-20 21:46:45.000000000 +0000 |
|
| 44 |
+@@ -105,6 +105,7 @@ |
|
| 45 |
+ case 2: |
|
| 46 |
+ isnet = 0; break; |
|
| 47 |
+ default: |
|
| 48 |
++ ((void)0); |
|
| 49 |
+ } |
|
| 50 |
+ |
|
| 51 |
+ /* Fill in the other fields. */ |
|
| 52 |
+diff -Naur net-tools-1.60.orig/mii-tool.c net-tools-1.60/mii-tool.c |
|
| 53 |
+--- net-tools-1.60.orig/mii-tool.c 2000-05-21 14:31:17.000000000 +0000 |
|
| 54 |
+@@ -379,17 +379,17 @@ |
|
| 55 |
+ /*--------------------------------------------------------------------*/ |
|
| 56 |
+ |
|
| 57 |
+ const char *usage = |
|
| 58 |
+-"usage: %s [-VvRrwl] [-A media,... | -F media] [interface ...] |
|
| 59 |
+- -V, --version display version information |
|
| 60 |
+- -v, --verbose more verbose output |
|
| 61 |
+- -R, --reset reset MII to poweron state |
|
| 62 |
+- -r, --restart restart autonegotiation |
|
| 63 |
+- -w, --watch monitor for link status changes |
|
| 64 |
+- -l, --log with -w, write events to syslog |
|
| 65 |
+- -A, --advertise=media,... advertise only specified media |
|
| 66 |
+- -F, --force=media force specified media technology |
|
| 67 |
+-media: 100baseT4, 100baseTx-FD, 100baseTx-HD, 10baseT-FD, 10baseT-HD, |
|
| 68 |
+- (to advertise both HD and FD) 100baseTx, 10baseT\n"; |
|
| 69 |
++"usage: %s [-VvRrwl] [-A media,... | -F media] [interface ...]\n" |
|
| 70 |
++" -V, --version display version information\n" |
|
| 71 |
++" -v, --verbose more verbose output\n" |
|
| 72 |
++" -R, --reset reset MII to poweron state\n" |
|
| 73 |
++" -r, --restart restart autonegotiation\n" |
|
| 74 |
++" -w, --watch monitor for link status changes\n" |
|
| 75 |
++" -l, --log with -w, write events to syslog\n" |
|
| 76 |
++" -A, --advertise=media,... advertise only specified media\n" |
|
| 77 |
++" -F, --force=media force specified media technology\n" |
|
| 78 |
++"media: 100baseT4, 100baseTx-FD, 100baseTx-HD, 10baseT-FD, 10baseT-HD,\n" |
|
| 79 |
++" (to advertise both HD and FD) 100baseTx, 10baseT\n"; |
|
| 80 |
+ |
|
| 81 |
+ int main(int argc, char **argv) |
|
| 82 |
+ {
|
| 0 | 83 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,51 @@ |
| 0 |
+Submitted By: Jim Gifford (jim at linuxfromscratch dot org) |
|
| 1 |
+Date: 2004-06-24 |
|
| 2 |
+Initial Package Version: 2.6 |
|
| 3 |
+Origin: Gentoo and Self |
|
| 4 |
+Upstream Status: N/A |
|
| 5 |
+Description: Fixes Compile Issues with the 2.6 Kernel |
|
| 6 |
+ |
|
| 7 |
+ |
|
| 8 |
+diff -Naur net-tools-1.60.orig/hostname.c net-tools-1.60/hostname.c |
|
| 9 |
+--- net-tools-1.60.orig/hostname.c 2001-04-08 17:04:23.000000000 +0000 |
|
| 10 |
+@@ -42,10 +42,16 @@ |
|
| 11 |
+ #include "config.h" |
|
| 12 |
+ #include "version.h" |
|
| 13 |
+ #include "../intl.h" |
|
| 14 |
++#include <linux/version.h> |
|
| 15 |
+ |
|
| 16 |
+ #if HAVE_AFDECnet |
|
| 17 |
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 5, 0) |
|
| 18 |
+ #include <netdnet/dn.h> |
|
| 19 |
+ #endif |
|
| 20 |
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 0) |
|
| 21 |
++#include <linux/dn.h> |
|
| 22 |
++#endif |
|
| 23 |
++#endif |
|
| 24 |
+ |
|
| 25 |
+ char *Release = RELEASE, *Version = "hostname 1.100 (2001-04-14)"; |
|
| 26 |
+ |
|
| 27 |
+diff -Naur net-tools-1.60.orig/lib/x25_sr.c net-tools-1.60/lib/x25_sr.c |
|
| 28 |
+--- net-tools-1.60.orig/lib/x25_sr.c 2000-05-20 13:38:10.000000000 +0000 |
|
| 29 |
+@@ -22,6 +22,7 @@ |
|
| 30 |
+ #include <sys/socket.h> |
|
| 31 |
+ #include <sys/ioctl.h> |
|
| 32 |
+ #include <linux/x25.h> |
|
| 33 |
++#include <linux/version.h> |
|
| 34 |
+ #include <ctype.h> |
|
| 35 |
+ #include <errno.h> |
|
| 36 |
+ #include <netdb.h> |
|
| 37 |
+@@ -77,7 +78,11 @@ |
|
| 38 |
+ rt.sigdigits=sigdigits; |
|
| 39 |
+ |
|
| 40 |
+ /* x25_route_struct.address isn't type struct sockaddr_x25, Why? */ |
|
| 41 |
++#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 0) |
|
| 42 |
+ memcpy(&rt.address, &sx25.sx25_addr, sizeof(x25_address)); |
|
| 43 |
++#else |
|
| 44 |
++ memcpy(&rt.address, &sx25.sx25_addr, sizeof(struct x25_address)); |
|
| 45 |
++#endif |
|
| 46 |
+ |
|
| 47 |
+ while (*args) {
|
|
| 48 |
+ if (!strcmp(*args,"device") || !strcmp(*args,"dev")) {
|
| 0 | 49 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,27 @@ |
| 0 |
+Submitted By: Randy McMurchy <randy_at_linuxfromscratch_dot_org> |
|
| 1 |
+Date: 2004-08-27 |
|
| 2 |
+Initial Package Version: 1.60 |
|
| 3 |
+Upstream Status: N/A (package is unmaintained) |
|
| 4 |
+Origin: From Fedora Core (submitted to LFS-Hackers by Kevin White) |
|
| 5 |
+Description: Fixes mii-tool when compiled using Linux-2.6.x |
|
| 6 |
+ |
|
| 7 |
+$LastChangedBy: randy $ |
|
| 8 |
+$Date: 2004-08-27 21:04:05 -0600 (Fri, 27 Aug 2004) $ |
|
| 9 |
+ |
|
| 10 |
+--- net-tools-1.60/include/mii.h.bar Tue Jul 31 11:49:39 2001 |
|
| 11 |
+@@ -11,11 +11,9 @@ |
|
| 12 |
+ |
|
| 13 |
+ /* network interface ioctl's for MII commands */ |
|
| 14 |
+ #ifndef SIOCGMIIPHY |
|
| 15 |
+-#define SIOCGMIIPHY (SIOCDEVPRIVATE) /* Read from current PHY */ |
|
| 16 |
+-#define SIOCGMIIREG (SIOCDEVPRIVATE+1) /* Read any PHY register */ |
|
| 17 |
+-#define SIOCSMIIREG (SIOCDEVPRIVATE+2) /* Write any PHY register */ |
|
| 18 |
+-#define SIOCGPARAMS (SIOCDEVPRIVATE+3) /* Read operational parameters */ |
|
| 19 |
+-#define SIOCSPARAMS (SIOCDEVPRIVATE+4) /* Set operational parameters */ |
|
| 20 |
++#define SIOCGMIIPHY 0x8947 /* Read from current PHY */ |
|
| 21 |
++#define SIOCGMIIREG 0x8948 /* Read any PHY register */ |
|
| 22 |
++#define SIOCSMIIREG 0x8949 /* Write any PHY register */ |
|
| 23 |
+ #endif |
|
| 24 |
+ |
|
| 25 |
+ #include <linux/types.h> |
| 0 | 26 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,53 @@ |
| 0 |
+Summary: Networking Tools |
|
| 1 |
+Name: net-tools |
|
| 2 |
+Version: 1.60 |
|
| 3 |
+Release: 1%{?dist}
|
|
| 4 |
+License: GPLv2+ |
|
| 5 |
+URL: http://net-tools.sourceforge.net |
|
| 6 |
+Group: System Environment/Base |
|
| 7 |
+Vendor: VMware, Inc. |
|
| 8 |
+Distribution: Photon |
|
| 9 |
+Source0: http://www.tazenda.demon.co.uk/phil/net-tools/%{name}-%{version}.tar.bz2
|
|
| 10 |
+%define sha1 net-tools=944fb70641505d5d1139dba3aeb81ba124574b83 |
|
| 11 |
+Patch0: http://www.linuxfromscratch.org/patches/blfs/6.3/net-tools-1.60-gcc34-3.patch |
|
| 12 |
+Patch1: http://www.linuxfromscratch.org/patches/blfs/6.3/net-tools-1.60-kernel_headers-2.patch |
|
| 13 |
+Patch2: http://www.linuxfromscratch.org/patches/blfs/6.3/net-tools-1.60-mii_ioctl-1.patch |
|
| 14 |
+%description |
|
| 15 |
+The Net-tools package is a collection of programs for controlling the network subsystem of the Linux kernel. |
|
| 16 |
+%prep |
|
| 17 |
+%setup -q |
|
| 18 |
+%patch0 -p1 |
|
| 19 |
+%patch1 -p1 |
|
| 20 |
+%patch2 -p1 |
|
| 21 |
+%build |
|
| 22 |
+yes "" | make config |
|
| 23 |
+sed -i -e 's|HAVE_IP_TOOLS 0|HAVE_IP_TOOLS 1|g' \ |
|
| 24 |
+ -e 's|HAVE_MII 0|HAVE_MII 1|g' config.h |
|
| 25 |
+sed -i -e 's|#define HAVE_HWSTRIP 1|#define HAVE_HWSTRIP 0|g' \ |
|
| 26 |
+ -e 's|#define HAVE_HWTR 1|#define HAVE_HWTR 0|g' config.h |
|
| 27 |
+sed -i -e 's|# HAVE_IP_TOOLS=0|HAVE_IP_TOOLS=1|g' \ |
|
| 28 |
+ -e 's|# HAVE_MII=0|HAVE_MII=1|g' config.make |
|
| 29 |
+make %{?_smp_mflags}
|
|
| 30 |
+%install |
|
| 31 |
+make BASEDIR=%{buildroot} BINDIR=%{_bindir} SBINDIR=%{_sbindir} install
|
|
| 32 |
+rm %{buildroot}/bin/hostname
|
|
| 33 |
+rm %{buildroot}/bin/dnsdomainname
|
|
| 34 |
+rm %{buildroot}/usr/share/man/man1/dnsdomainname.1
|
|
| 35 |
+rm %{buildroot}/usr/share/man/man1/hostname.1
|
|
| 36 |
+%check |
|
| 37 |
+make -k check |& tee %{_specdir}/%{name}-check-log || %{nocheck}
|
|
| 38 |
+%post -p /sbin/ldconfig |
|
| 39 |
+%postun -p /sbin/ldconfig |
|
| 40 |
+%clean |
|
| 41 |
+rm -rf %{buildroot}/*
|
|
| 42 |
+%files |
|
| 43 |
+%defattr(-,root,root) |
|
| 44 |
+/bin/* |
|
| 45 |
+/sbin/* |
|
| 46 |
+%{_mandir}/man1/*
|
|
| 47 |
+%{_mandir}/man5/*
|
|
| 48 |
+%{_mandir}/man8/*
|
|
| 49 |
+ |
|
| 50 |
+%changelog |
|
| 51 |
+* Mon Jul 13 2015 Divya Thaluru <dthaluru@vmware.com> 1.60-1 |
|
| 52 |
+- Initial build. First version |