[Lunar-commits] <moonbase> create-headers: After talking with Ratler and florin we have decided this

Dennis `stumbles` Veatch stumbles at lunar-linux.org
Sun Jul 11 15:05:46 CEST 2010


commit b0e736677735ca2cd61b6633ab6c6463b55fd821
Author: Dennis `stumbles` Veatch <stumbles at lunar-linux.org>
Date:   Sun Jul 11 09:05:46 2010 -0400

    create-headers: After talking with Ratler and florin we have decided this
    
    would be helpful to have in moonbase instead of crater.
---
 kernel/create-headers/BUILD        |   19 +++++++++++++++++++
 kernel/create-headers/BUILD.x86_64 |   19 +++++++++++++++++++
 kernel/create-headers/DEPENDS      |    2 ++
 kernel/create-headers/DETAILS      |   14 ++++++++++++++
 kernel/create-headers/PRE_BUILD    |   19 +++++++++++++++++++
 5 files changed, 73 insertions(+), 0 deletions(-)

diff --git a/kernel/create-headers/BUILD b/kernel/create-headers/BUILD
new file mode 100644
index 0000000..c4011f4
--- /dev/null
+++ b/kernel/create-headers/BUILD
@@ -0,0 +1,19 @@
+(
+
+  KERNEL_DIR="$SOURCE_DIRECTORY"
+
+  # Ready the headers
+  cd ${KERNEL_DIR}
+  make headers_check
+  make INSTALL_HDR_PATH=${SOURCE_DIRECTORY}/kernel-headers-$VERSION headers_install
+
+  # Remove some of them since they are provided by glibc already
+  rm -rf $SOURCE_DIRECTORY/kernel-headers-$VERSION/include/scsi
+
+  prepare_install
+
+  tar cjvf kernel-headers-$VERSION.tar.bz2 kernel-headers-$VERSION &&
+
+  install -m644 $SOURCE_DIRECTORY/kernel-headers-$VERSION.tar.bz2 $SOURCE_CACHE/
+
+) > $C_FIFO 2>&1
diff --git a/kernel/create-headers/BUILD.x86_64 b/kernel/create-headers/BUILD.x86_64
new file mode 100644
index 0000000..65ec841
--- /dev/null
+++ b/kernel/create-headers/BUILD.x86_64
@@ -0,0 +1,19 @@
+(
+
+  KERNEL_DIR="$SOURCE_DIRECTORY"
+
+  # Ready the headers
+  cd ${KERNEL_DIR}
+  make headers_check
+  make INSTALL_HDR_PATH=${SOURCE_DIRECTORY}/kernel-headers-$VERSION-x86_64 headers_install
+
+  # Remove some of them since they are provided by glibc already
+  rm -rf $SOURCE_DIRECTORY/kernel-headers-$VERSION-x86_64/include/scsi
+
+  prepare_install
+
+  tar cjvf kernel-headers-$VERSION-x86_64.tar.bz2 kernel-headers-$VERSION-x86_64 &&
+
+  install -m644 $SOURCE_DIRECTORY/kernel-headers-$VERSION-x86_64.tar.bz2 $SOURCE_CACHE/
+
+) > $C_FIFO 2>&1
diff --git a/kernel/create-headers/DEPENDS b/kernel/create-headers/DEPENDS
new file mode 100644
index 0000000..bc4315a
--- /dev/null
+++ b/kernel/create-headers/DEPENDS
@@ -0,0 +1,2 @@
+depends unifdef
+depends glibc
diff --git a/kernel/create-headers/DETAILS b/kernel/create-headers/DETAILS
new file mode 100644
index 0000000..ab5b0fb
--- /dev/null
+++ b/kernel/create-headers/DETAILS
@@ -0,0 +1,14 @@
+            MODULE=create-headers
+             MAJOR=2.6
+           VERSION=$MAJOR.34.1
+            SOURCE=linux-$VERSION.tar.bz2
+        SOURCE_URL=$KERNEL_URL/pub/linux/kernel/v$MAJOR
+          WEB_SITE=http://www.lunar-linux.org
+           ENTERED=20100711
+           UPDATED=20100711
+            SHORT="creates the latest kernel headers package"
+
+cat << EOF
+Lunar Linux module to create the kernel headers package for userspace.
+DO NOT INSTALL THIS MODULE ON YOUR OWN! DO NOT MOVE THIS TO MOONBASE!
+EOF
diff --git a/kernel/create-headers/PRE_BUILD b/kernel/create-headers/PRE_BUILD
new file mode 100644
index 0000000..2b386c0
--- /dev/null
+++ b/kernel/create-headers/PRE_BUILD
@@ -0,0 +1,19 @@
+   message " "
+   message " ${PROBLEM_COLOR}Warning! This module does not need to be run on every kernel update. The optimum time would be from one major kernel version to the next, such as 2.6.33 to 2.6.34"
+   message " "
+   if ! query "Do you wish to continue (y/n)? " n; then
+      message " "
+      message " "
+      exit 1
+   fi
+
+mk_source_dir       &&
+validate_source_dir &&
+
+cd $SOURCE_DIRECTORY &&
+
+message "${MESSAGE_COLOR}Extracting kernel sources ...${DEFAULT_COLOR}" &&
+
+tar xf $SOURCE_CACHE/$SOURCE --no-same-owner \
+                             --no-same-permissions \
+                             --strip-component=1


More information about the Lunar-commits mailing list