[lfs-book] r9944 - in trunk/BOOK: . chapter01 chapter06 udev-config

ken at linuxfromscratch.org ken at linuxfromscratch.org
Mon Aug 20 16:51:26 PDT 2012


Author: ken
Date: 2012-08-20 17:51:22 -0600 (Mon, 20 Aug 2012)
New Revision: 9944

Modified:
   trunk/BOOK/chapter01/changelog.xml
   trunk/BOOK/chapter06/glibc.xml
   trunk/BOOK/general.ent
   trunk/BOOK/udev-config/ChangeLog
   trunk/BOOK/udev-config/Makefile
Log:
Correct how timezones are installed - this fixes various errors in test-suites. Thanks to Markku Pesonen for noting how Debian install timezones.

Modified: trunk/BOOK/chapter01/changelog.xml
===================================================================
--- trunk/BOOK/chapter01/changelog.xml	2012-08-20 19:01:25 UTC (rev 9943)
+++ trunk/BOOK/chapter01/changelog.xml	2012-08-20 23:51:22 UTC (rev 9944)
@@ -44,6 +44,9 @@
           <para>[bdubbs] - Add patch to fix Flex regression test
           failures.</para>
         </listitem>
+        <listitem>
+          <para>[ken] - Fix how the timezones are installed.</para>
+        </listitem>
       </itemizedlist>
     </listitem>
 

Modified: trunk/BOOK/chapter06/glibc.xml
===================================================================
--- trunk/BOOK/chapter06/glibc.xml	2012-08-20 19:01:25 UTC (rev 9943)
+++ trunk/BOOK/chapter06/glibc.xml	2012-08-20 23:51:22 UTC (rev 9944)
@@ -315,13 +315,55 @@
     <para>Install timezone data:</para>
 <screen><userinput>tar -xf ../tzdata&tzdata-version;.tar.gz
 
+mkdir -pv /usr/share/zoneinfo/{posix,right} &&
 for tz in etcetera southamerica northamerica europe africa antarctica \
   asia australasia backward pacificnew solar87 solar88 solar89 systemv; do
-    zic -L leapseconds -d /usr/share/zoneinfo -y "sh yearistype.sh" ${tz}
+    zic -L /dev/null -d /usr/share/zoneinfo -y "sh yearistype.sh" ${tz} &&
+    zic -L /dev/null -d /usr/share/zoneinfo/posix -y "sh yearistype.sh" ${tz} &&
+    zic -L leapseconds -d /usr/share/zoneinfo/right -y "sh yearistype.sh" ${tz}
 done
-cp -v *.tab /usr/share/zoneinfo</userinput></screen>
+cp -v zone.tab /usr/share/zoneinfo &&
+zic -d /usr/share/zoneinfo -p America/New_York</userinput></screen>
 
-    <para>One way to determine the local time zone, run the following
+    <variablelist>
+      <title>The meaning of the zic commands:</title>
+
+      <varlistentry>
+        <term><parameter>zic -L /dev/null ...</parameter></term>
+        <listitem>
+          <para>This creates posix timezones, without any leap seconds.  It is
+          conventional to put these in both
+          <filename class="directory">zoneinfo</filename> and
+          <filename class="directory">zoneinfo/posix</filename>. It is
+          necessary to put the POSIX timezones in
+          <filename class="directory">zoneinfo</filename>, otherwise various
+          test-suites will report errors. On an embedded system, where space is
+          tight and you do not intend to ever update the timezones, you could save
+          1.9MB by not using the <filename class="directory">posix</filename>
+          directory, but some applications or test-suites might give less good
+          results</para>
+        </listitem>
+      </varlistentry>
+      <varlistentry>
+        <term><parameter>zic -L leapseconds ...</parameter></term>
+        <listitem>
+          <para>This creates right timezones, including leap seconds. On an
+          embedded system, where space is tight and you do not intend to
+          ever update the timezones, or care about the correct time, you could
+          save 1.9MB by omitting the <filename class="directory">right</filename>
+          directory.</para>
+        </listitem>
+      </varlistentry>
+      <varlistentry>
+        <term><parameter>zic ... -p ...</parameter></term>
+        <listitem>
+          <para>This creates the <filename>posixrules</filename> file.</para>
+        </listitem>
+      </varlistentry>
+    </variablelist>
+
+
+    <para>One way to determine the local time zone is to run the following
     script:</para>
 
 <screen role="nodump"><userinput>tzselect</userinput></screen>

Modified: trunk/BOOK/general.ent
===================================================================
--- trunk/BOOK/general.ent	2012-08-20 19:01:25 UTC (rev 9943)
+++ trunk/BOOK/general.ent	2012-08-20 23:51:22 UTC (rev 9944)
@@ -1,5 +1,5 @@
-<!ENTITY version "SVN-20120816">
-<!ENTITY releasedate "August 16, 2012">
+<!ENTITY version "SVN-20120820">
+<!ENTITY releasedate "August 20, 2012">
 <!ENTITY copyrightdate "1999-2012"><!-- jhalfs needs a literal dash, not – -->
 <!ENTITY milestone "7.2">
 <!ENTITY generic-version "development"> <!-- Use "development", "testing", or "x.y[-pre{x}]" -->

Modified: trunk/BOOK/udev-config/ChangeLog
===================================================================
--- trunk/BOOK/udev-config/ChangeLog	2012-08-20 19:01:25 UTC (rev 9943)
+++ trunk/BOOK/udev-config/ChangeLog	2012-08-20 23:51:22 UTC (rev 9944)
@@ -1,3 +1,8 @@
+2012-06-13	Ken Moffat <ken at linuxfromscratch.org>
+	* add rule_generator/: with persistent net and cd alias rules
+	  and functions which were removed from udev-182 after it was merged
+	  into systemd.
+
 2010-01-26	Matt Burgess <matthew at linuxfromscratch.org>
 	* 55-lfs.rules: Remove lots of rules that have been merged upstream.
 	* 61-cdrom.rules: Remove as upstream has a replacement.

Modified: trunk/BOOK/udev-config/Makefile
===================================================================
--- trunk/BOOK/udev-config/Makefile	2012-08-20 19:01:25 UTC (rev 9943)
+++ trunk/BOOK/udev-config/Makefile	2012-08-20 23:51:22 UTC (rev 9944)
@@ -4,6 +4,7 @@
 RULES_DIR = /etc/udev/rules.d
 INSTALL = install
 INSTALL_DATA = $(INSTALL) -m644
+INSTALL_EXEC = $(INSTALL) -m755
 RULES_FILES = \
 	55-lfs.rules
 DOC_FILES = $(RULES_FILES:.rules=.txt)
@@ -11,6 +12,14 @@
 # Location to install the docs
 DOC_DIR = $(PREFIX)/share/doc/udev-config
 
+# for files shipped with udev up to version 182
+SYS_LIB = /lib/udev
+SYS_RULES_DIR = $(SYS_LIB)/rules.d
+SYS_RULES = 75-cd-aliases-generator.rules \
+            75-persistent-net-generator.rules
+SYS_FUNCTIONS = rule_generator.functions
+SYS_SCRIPTS = write_cd_rules write_net_rules
+
 all:
 
 install: install-rules
@@ -20,6 +29,17 @@
 	for rule in $(RULES_FILES); do \
 		$(INSTALL_DATA) $$rule $(DESTDIR)$(RULES_DIR) || exit 1; \
 	done;
+	$(INSTALL) -d $(DESTDIR)$(SYS_LIB)
+	for function in $(SYS_FUNCTIONS); do \
+		$(INSTALL_DATA) rule_generator/$$function $(DESTDIR)$(SYS_LIB) || exit 1; \
+	done;
+	for script in $(SYS_SCRIPTS); do \
+		$(INSTALL_EXEC) rule_generator/$$script $(DESTDIR)$(SYS_LIB) || exit 1; \
+	done;
+	$(INSTALL) -d $(DESTDIR)$(SYS_RULES_DIR)
+	for rule in $(SYS_RULES); do \
+		$(INSTALL_DATA) rule_generator/$$rule $(DESTDIR)$(SYS_RULES_DIR) || exit 1; \
+	done;
 
 install-doc:
 	$(INSTALL) -d $(DESTDIR)$(DOC_DIR)




More information about the lfs-book mailing list