On Sun, Jan 16, 2011 at 11:13 AM, Andrew Bradford <[email protected]> wrote: > > On Thu, Jan 13, 2011 at 2:19 AM, Grail Dane <[email protected]> wrote: >> >> Hi All >> Wasn't sure if this was a dev thing or not, but I see we have recently >> started to host our own copy of iana-etc as the original site seems >> to not be responding. After searching for a bit I found a thread on LFS >> talking about it and the fact that not only could >> the source not been downloaded but once it is that the files being used, ie >> services and protocols, are out of date (circa 2008). >> The hot debate about how to update them never really seemed to get resolved >> except to say to get them from iana directly. >> What I thought I would add here is that with one simple change and an >> addition to make this can be done: >> 1. The following sed update the now out of date link to where the protocol >> files are stored: >> sed -i '/file=/s@pro[^ *]@&/&.txt@' Makefile >> 2. There is already a built in get call that can retrieve the latest copies, >> so simply do the following: >> make get && make >> And viola, if you ran this today the files would be as up to date as: >> services 2011-01-11 >> protocols 2010-11-23 >> Just thought you might all like to know :) >> Cheers >> Grail > > Grail, > > Thanks for pointing this out! I didn't know the package had a built in > updater script, that's neat. > > I did find that your sed line doesn't work well for me on amd64 Debian 5, it > ends up garbling the protocol-numbers.iana line in Makefile to look like this: > > protocol-numbers.iana: > $(AWK) -f get.gawk -v file=prot/prot.txtocol-numbers > >protocol-numbers.i > ana > > Which isn't the desired output. A less complex sed line that works for me, > achieves your desired intent, and is a little easier for the regex impaired > (myself included :) would be: > > sed -i '/file=/s@protocol-numbers@&/&.txt@' Makefile > > I'll craft a patch and submit it to the list. > > Regards, > Andrew
Patch attached for the embedded book. It may also work on other books but I haven't tested that. Sorry if my previous email's sed line got wrecked (the list archiver didn't like it, thought it was an email address). Regards, Andrew
From fe475b7737931e0339c1ab14fa67f7946a50f5c2 Mon Sep 17 00:00:00 2001 From: Andrew Bradford <[email protected]> Date: Sun, 16 Jan 2011 11:12:36 -0500 Subject: [PATCH] Updated Iana-Etc to pull new data from IANA As per discussion on the mailing list thread: http://lists.cross-lfs.org/pipermail/clfs-dev-cross-lfs.org/2011-January/000866.html This pulls up to date /etc/protocols and /etc/services data direct from IANA rather than relying on the outdated data in the tarball. --- BOOK/final-system/common/iana-etc.xml | 24 +++++++++++++++++------- 1 files changed, 17 insertions(+), 7 deletions(-) diff --git a/BOOK/final-system/common/iana-etc.xml b/BOOK/final-system/common/iana-etc.xml index a54e452..181ae44 100644 --- a/BOOK/final-system/common/iana-etc.xml +++ b/BOOK/final-system/common/iana-etc.xml @@ -25,17 +25,26 @@ <sect2 role="installation"> <title>Installation of Iana-Etc</title> - <para os="a">The following command converts the raw data provided by IANA into - the correct formats for the <filename>/etc/protocols</filename> and - <filename>/etc/services</filename> data files:</para> + <para os="a">The <filename>protocol-numbers.dist</filename> and + <filename>port-numbers.dist</filename> files that come with Iana-Etc + are outdated. Also, IANA has moved their copy of protocol-numbers. + In order to ensure we use correct and up to date data, first modify the + Makefile and then download the updates:</para> -<screen os="b"><userinput>make</userinput></screen> +<screen os="b"><userinput>sed -i '/file=/s@protocol-numbers@&/&.txt@' Makefile +make get</userinput></screen> - <para os="c">This package does not come with a test suite.</para> + <para os="c">The following command then converts the raw data provided by + IANA into the correct formats for the <filename>/etc/protocols</filename> + and <filename>/etc/services</filename> data files:</para> - <para os="d">Install the package:</para> +<screen os="d"><userinput>make</userinput></screen> -<screen os="e"><userinput>make DESTDIR=${CLFS} install</userinput></screen> + <para os="e">This package does not come with a test suite.</para> + + <para os="f">Install the package:</para> + +<screen os="g"><userinput>make DESTDIR=${CLFS} install</userinput></screen> </sect2> @@ -83,3 +92,4 @@ </sect2> </sect1> + -- 1.5.6.5
_______________________________________________ Clfs-dev mailing list [email protected] http://lists.cross-lfs.org/listinfo.cgi/clfs-dev-cross-lfs.org
