aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/extras/drm/scripts/create_lk_drm.sh
diff options
context:
space:
mode:
Diffstat (limited to 'nx-X11/extras/drm/scripts/create_lk_drm.sh')
-rwxr-xr-xnx-X11/extras/drm/scripts/create_lk_drm.sh35
1 files changed, 35 insertions, 0 deletions
diff --git a/nx-X11/extras/drm/scripts/create_lk_drm.sh b/nx-X11/extras/drm/scripts/create_lk_drm.sh
new file mode 100755
index 000000000..6939faae7
--- /dev/null
+++ b/nx-X11/extras/drm/scripts/create_lk_drm.sh
@@ -0,0 +1,35 @@
+#! /bin/bash
+# script to create a Linux Kernel tree from the DRM tree for diffing etc..
+#
+# Original author - Dave Airlie (C) 2004 - airlied@linux.ie
+#
+
+if [ $# -lt 2 ] ;then
+ echo usage: $0 output_dir [2.4\|2.6]
+ exit 1
+fi
+
+if [ ! -d shared -o ! -d linux ] ;then
+ echo not in DRM toplevel
+ exit 1
+fi
+
+OUTDIR=$1/drivers/char/drm/
+VERS=$2
+
+echo "Copying kernel independent files"
+mkdir -p $OUTDIR
+
+( cd linux/ ; make drm_pciids.h )
+cp shared-core/*.[ch] $OUTDIR
+cp linux-core/*.[ch] $OUTDIR
+cp linux-core/Makefile.kernel $OUTDIR/Makefile
+
+if [ $VERS = 2.4 ] ;then
+ echo "Copying 2.4 Kernel files"
+ cp linux/Config.in $OUTDIR/
+elif [ $VERS = 2.6 ] ;then
+ echo "Copying 2.6 Kernel files"
+ cp linux/Kconfig $OUTDIR/
+fi
+