From db672b1e335dca0a4b92707ac788b177668372d1 Mon Sep 17 00:00:00 2001 From: Stefan Fiedler Date: Fri, 25 Nov 2005 17:21:23 +0000 Subject: [PATCH] Stefan Fiedler: add brlcad (7.6.2), a CSG solid modeling system developed by the U.S. military Index: package/stf/brlcad/fix-itcl-functionality-test.patch =================================================================== [2005103006071209815] (https://www.rocklinux.net/submaster) git-svn-id: http://www.rocklinux.org/svn/rock-linux/trunk@6640 c5f82cb5-29bc-0310-9cd0-bff59a50e3bc --- package/stf/brlcad/brlcad.conf | 16 ++ package/stf/brlcad/brlcad.desc | 51 +++++ .../brlcad/fix-itcl-functionality-test.patch | 22 ++ package/stf/brlcad/head-tail.patch | 198 ++++++++++++++++++ .../brlcad/ignore-libtk-config-error.patch | 10 + 5 files changed, 297 insertions(+) create mode 100644 package/stf/brlcad/brlcad.conf create mode 100644 package/stf/brlcad/brlcad.desc create mode 100644 package/stf/brlcad/fix-itcl-functionality-test.patch create mode 100644 package/stf/brlcad/head-tail.patch create mode 100644 package/stf/brlcad/ignore-libtk-config-error.patch diff --git a/package/stf/brlcad/brlcad.conf b/package/stf/brlcad/brlcad.conf new file mode 100644 index 000000000..f0f5b9394 --- /dev/null +++ b/package/stf/brlcad/brlcad.conf @@ -0,0 +1,16 @@ +# brlcad installed below /usr creates shared file conflicts with other packages +prefix="/opt/brlcad" +set_confopt + +pkginstalled tcl && var_append extraconfopt " " "--disable-tcl" +pkginstalled tk && var_append extraconfopt " " "--disable-tk" +pkginstalled tcltk && var_append extraconfopt " " "--disable-tcl --disable-tk" +pkginstalled itcl && var_append extraconfopt " " "--disable-itcl" + +# does not work?! +pkginstalled sun-jdk15 && var_append extraconfopt " " "--with-jdk=/opt/jdk1.5.*" + +var_append extraconfopt "--enable-pro-engineer-plugin --enable-optimized" + +# the first run of configure is only necessary to create include/brlcad_config.h +hook_add preconf 3 "./configure ; rm -f config.cache.*" diff --git a/package/stf/brlcad/brlcad.desc b/package/stf/brlcad/brlcad.desc new file mode 100644 index 000000000..5651b3972 --- /dev/null +++ b/package/stf/brlcad/brlcad.desc @@ -0,0 +1,51 @@ + +[COPY] --- ROCK-COPYRIGHT-NOTE-BEGIN --- +[COPY] +[COPY] This copyright note is auto-generated by ./scripts/Create-CopyPatch. +[COPY] Please add additional copyright information _after_ the line containing +[COPY] the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by +[COPY] the ./scripts/Create-CopyPatch script. Do not edit this copyright text! +[COPY] +[COPY] ROCK Linux: rock-src/package/stf/libzvbi/libzvbi.desc +[COPY] ROCK Linux is Copyright (C) 1998 - 2005 Clifford Wolf +[COPY] +[COPY] This program is free software; you can redistribute it and/or modify +[COPY] it under the terms of the GNU General Public License as published by +[COPY] the Free Software Foundation; either version 2 of the License, or +[COPY] (at your option) any later version. A copy of the GNU General Public +[COPY] License can be found at Documentation/COPYING. +[COPY] +[COPY] Many people helped and are helping developing ROCK Linux. Please +[COPY] have a look at http://www.rocklinux.org/ and the Documentation/TEAM +[COPY] file for details. +[COPY] +[COPY] --- ROCK-COPYRIGHT-NOTE-END --- + +[I] a powerful Constructive Solid Geometry (CSG) solid modeling system + +[T] The BRL-CAD package is a powerful Constructive Solid Geometry (CSG) solid +[T] modeling system with over 20 years development and production use by the +[T] U.S. military. BRL-CAD includes an interactive geometry editor, parallel +[T] ray-tracing support for rendering and geometric analysis, path-tracing for +[T] realistic image synthesis, network distributed framebuffer support, +[T] image-processing and signal-processing tools. The entire package is +[T] distributed in source code form. + +[U] http://brlcad.sourceforge.net/ +[U] http://sourceforge.net/projects/brlcad/ + +[A] Morrison, Christopher Sean { Open Source Point of Contact } +[A] Butler, Lee { U.S. Army Research Laboratory Point of Contact } +[A] Muuss, Michael John { original architect } +[A] and many more { see AUTHORS file } + +[M] Stefan Fiedler + +[C] extra/scientific + +[L] GPL +[S] Stable +[V] 7.6.2 +[P] O -?---5---9 550.000 + +[D] 0 brlcad-7.6.2.tar.bz2 http://dl.sourceforge.net/sourceforge/brlcad/ diff --git a/package/stf/brlcad/fix-itcl-functionality-test.patch b/package/stf/brlcad/fix-itcl-functionality-test.patch new file mode 100644 index 000000000..55173e5b6 --- /dev/null +++ b/package/stf/brlcad/fix-itcl-functionality-test.patch @@ -0,0 +1,22 @@ +--- brlcad-7.6.2/configure 2005-09-29 08:47:39.000000000 +0200 ++++ brlcad-7.6.2-p2/configure 2005-10-29 03:28:14.000000000 +0200 +@@ -26736,7 +26736,7 @@ + PRECPPFLAGS="$CPPFLAGS" + if test "x$itcl_link_works" = "xyes" ; then + LIBS="$LIBS $LIBITCL $LIBTCL" +- CPPFLAGS="$CPPFLAGS -Iinclude" ++ CPPFLAGS="$CPPFLAGS -DHAVE_CONFIG_H -Iinclude" + fi + if test "$cross_compiling" = yes; then + { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling +--- brlcad-7.6.2/configure.ac 2005-09-29 08:37:35.000000000 +0200 ++++ brlcad-7.6.2-p2/configure.ac 2005-10-29 03:28:39.000000000 +0200 +@@ -1986,7 +1986,7 @@ + PRECPPFLAGS="$CPPFLAGS" + if test "x$itcl_link_works" = "xyes" ; then + LIBS="$LIBS $LIBITCL $LIBTCL" +- CPPFLAGS="$CPPFLAGS -Iinclude" ++ CPPFLAGS="$CPPFLAGS -DHAVE_CONFIG_H -Iinclude" + fi + AC_TRY_RUN([ + #include diff --git a/package/stf/brlcad/head-tail.patch b/package/stf/brlcad/head-tail.patch new file mode 100644 index 000000000..b5527824d --- /dev/null +++ b/package/stf/brlcad/head-tail.patch @@ -0,0 +1,198 @@ +diff -dur brlcad-7.6.2/aclocal.m4 brlcad-7.6.2-p/aclocal.m4 +--- brlcad-7.6.2/aclocal.m4 2005-09-29 08:47:16.000000000 +0200 ++++ brlcad-7.6.2-p/aclocal.m4 2005-10-28 02:14:23.000000000 +0200 +@@ -5056,7 +5056,7 @@ + lt_cv_file_magic_cmd='/usr/bin/file -L' + case "$host_os" in + rhapsody* | darwin1.[[012]]) +- lt_cv_file_magic_test_file=`echo /System/Library/Frameworks/System.framework/Versions/*/System | head -1` ++ lt_cv_file_magic_test_file=`echo /System/Library/Frameworks/System.framework/Versions/*/System | head -n1` + ;; + *) # Darwin 1.3 on + lt_cv_file_magic_test_file='/usr/lib/libSystem.dylib' +diff -dur brlcad-7.6.2/bench/benchmark brlcad-7.6.2-p/bench/benchmark +--- brlcad-7.6.2/bench/benchmark 2005-09-29 08:50:43.000000000 +0200 ++++ brlcad-7.6.2-p/bench/benchmark 2005-10-28 02:17:04.000000000 +0200 +@@ -833,13 +833,13 @@ + echo " summary ... performance results summary, 2 lines per run" + + if test $perf_ret != 0 ; then +- tail -1 summary ++ tail -n1 summary + exit $perf_ret + else + echo +- tail -2 summary ++ tail -n2 summary + fi +-vgr="`tail -1 summary | awk '{print int($9+0.5)}'`" ++vgr="`tail -n1 summary | awk '{print int($9+0.5)}'`" + if test ! "x$vgr" = "x" ; then + echo + echo "#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#" +diff -dur brlcad-7.6.2/bench/run.sh brlcad-7.6.2-p/bench/run.sh +--- brlcad-7.6.2/bench/run.sh 2005-09-29 08:37:35.000000000 +0200 ++++ brlcad-7.6.2-p/bench/run.sh 2005-10-28 02:16:02.000000000 +0200 +@@ -833,13 +833,13 @@ + echo " summary ... performance results summary, 2 lines per run" + + if test $perf_ret != 0 ; then +- tail -1 summary ++ tail -n1 summary + exit $perf_ret + else + echo +- tail -2 summary ++ tail -n2 summary + fi +-vgr="`tail -1 summary | awk '{print int($9+0.5)}'`" ++vgr="`tail -n1 summary | awk '{print int($9+0.5)}'`" + if test ! "x$vgr" = "x" ; then + echo + echo "#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#*#" +diff -dur brlcad-7.6.2/configure brlcad-7.6.2-p/configure +--- brlcad-7.6.2/configure 2005-09-29 08:47:39.000000000 +0200 ++++ brlcad-7.6.2-p/configure 2005-10-29 02:18:27.000000000 +0200 +@@ -11087,7 +11107,7 @@ + lt_cv_file_magic_cmd='/usr/bin/file -L' + case "$host_os" in + rhapsody* | darwin1.[012]) +- lt_cv_file_magic_test_file=`echo /System/Library/Frameworks/System.framework/Versions/*/System | head -1` ++ lt_cv_file_magic_test_file=`echo /System/Library/Frameworks/System.framework/Versions/*/System | head -n1` + ;; + *) # Darwin 1.3 on + lt_cv_file_magic_test_file='/usr/lib/libSystem.dylib' +diff -dur brlcad-7.6.2/doc/html/manuals/Anim_Tutorial/chapt2.html brlcad-7.6.2-p/doc/html/manuals/Anim_Tutorial/chapt2.html +--- brlcad-7.6.2/doc/html/manuals/Anim_Tutorial/chapt2.html 2005-09-29 08:37:35.000000000 +0200 ++++ brlcad-7.6.2-p/doc/html/manuals/Anim_Tutorial/chapt2.html 2005-10-28 02:13:53.000000000 +0200 +@@ -300,7 +300,7 @@ + illustration purposes + only the commands for the first two frames are shown here. +
+-% head -12 moss.rtanim
++% head -n12 moss.rtanim
+ viewsize 200;
+ eye_pt 90.7107 70.7107 0;
+ orientation 0.270598 0.653281 0.653281 0.270598;
+diff -dur brlcad-7.6.2/doc/html/manuals/mged/animmate/object_tut.html brlcad-7.6.2-p/doc/html/manuals/mged/animmate/object_tut.html
+--- brlcad-7.6.2/doc/html/manuals/mged/animmate/object_tut.html	2005-09-29 08:37:35.000000000 +0200
++++ brlcad-7.6.2-p/doc/html/manuals/mged/animmate/object_tut.html	2005-10-28 02:13:40.000000000 +0200
+@@ -120,7 +120,7 @@
+ From a shell window, take a look at foo.script. It should look something
+ like the following:
+ 
+-%> head -20 foo.script
++%> head -n20 foo.script
+ start 0;
+ clean;
+ anim all.g/cone.r matrix lmul
+diff -dur brlcad-7.6.2/doc/html/manuals/mged/animmate/rt_tut.html brlcad-7.6.2-p/doc/html/manuals/mged/animmate/rt_tut.html
+--- brlcad-7.6.2/doc/html/manuals/mged/animmate/rt_tut.html	2005-09-29 08:37:35.000000000 +0200
++++ brlcad-7.6.2-p/doc/html/manuals/mged/animmate/rt_tut.html	2005-10-28 02:13:25.000000000 +0200
+@@ -65,7 +65,7 @@
+ scriptsort also inserts a call to the shell script
+ end_of_frame.sh after each frame of the animation.
+ 
+-%> head -10 anim.script
++%> head -n10 anim.script
+ start 0;clean ;
+ anim all.g/cone.r matrix lmul -0.268148 -0.841061 -0.469801 17.995962 0.889157 -0.403767 0.215341 -112.596747 -0.370805 -0.359984 0.856105 -3.321956 0.000000 0.000000 0.000000 1.000000 ;
+ end;
+@@ -77,7 +77,7 @@
+ end;
+ start 3;clean ;
+ %> scriptsort -f < anim.script > anim_and_shell.script
+-%> head -10 anim_and_shell.script
++%> head -n10 anim_and_shell.script
+ start 0;clean ;
+ anim all.g/cone.r matrix lmul -0.268148 -0.841061 -0.469801 17.995962 0.889157 -0.403767 0.215341 -112.596747 -0.370805 -0.359984 0.856105 -3.321956 0.000000 0.000000 0.000000 1.000000 ;
+ end;
+diff -dur brlcad-7.6.2/sh/header.sh brlcad-7.6.2-p/sh/header.sh
+--- brlcad-7.6.2/sh/header.sh	2005-09-29 08:37:36.000000000 +0200
++++ brlcad-7.6.2-p/sh/header.sh	2005-10-28 02:12:23.000000000 +0200
+@@ -240,9 +240,9 @@
+ ###################################
+ copyright=""
+ currentyear="`date | awk '{print $6}'`"
+-copyrightline="`grep -i copyright $FILE | grep -v -i notice | grep -v -i '\.SH' | head -1`"
++copyrightline="`grep -i copyright $FILE | grep -v -i notice | grep -v -i '\.SH' | head -n1`"
+ if [ "x$copyrightline" = "x" ] ; then
+-    copyrightline="`grep -i copyright $FILE | grep -v -i united | grep -v -i '\.SH' | head -1`"
++    copyrightline="`grep -i copyright $FILE | grep -v -i united | grep -v -i '\.SH' | head -n1`"
+ fi
+ if [ "x$copyrightline" = "x" ] ; then
+     startyear="$currentyear"
+@@ -392,13 +392,13 @@
+ ###################################
+ # see if the license block exists #
+ ###################################
+-foundtitle="`head -5 $FILE | grep "$title" | wc | awk '{print $1}'`"
++foundtitle="`head -n5 $FILE | grep "$title" | wc | awk '{print $1}'`"
+ prepend=no
+ if [ "x$foundtitle" = "x0" ] ; then
+     prepend=yes
+ else
+-    licline="`echo "$block" | tail -7 | head -1`"
+-    foundfileheader="`head -50 $FILE | grep "$licline" | wc | awk '{print $1}'`"
++    licline="`echo "$block" | tail -n7 | head -n1`"
++    foundfileheader="`head -n50 $FILE | grep "$licline" | wc | awk '{print $1}'`"
+     if [ "x$foundfileheader" = "x0" ] ; then
+ 	prepend=yes
+ 	echo "$FILE already has a title"
+@@ -424,9 +424,9 @@
+ 
+ closeit=0
+ skip=1
+-lineone="`cat ${FILE}.backup | head -1`"
+-linetwo="`cat ${FILE}.backup | head -2 | tail -1`"
+-linethree="`cat ${FILE}.backup | head -3 | tail -1`"
++lineone="`cat ${FILE}.backup | head -n1`"
++linetwo="`cat ${FILE}.backup | head -n2 | tail -n1`"
++linethree="`cat ${FILE}.backup | head -n3 | tail -n1`"
+ case "$lineone" in 
+     "/*"*${title})
+         echo "Found C comment start with file header"
+diff -dur brlcad-7.6.2/sh/make_dmg.sh brlcad-7.6.2-p/sh/make_dmg.sh
+--- brlcad-7.6.2/sh/make_dmg.sh	2005-09-29 08:37:36.000000000 +0200
++++ brlcad-7.6.2-p/sh/make_dmg.sh	2005-10-28 02:11:45.000000000 +0200
+@@ -153,7 +153,7 @@
+     exit 1
+ fi
+ 
+-hdidDisk=`hdid -nomount "${DMG}.sparseimage" | head -1 | grep '/dev/disk[0-9]*' | awk '{print $1}'`
++hdidDisk=`hdid -nomount "${DMG}.sparseimage" | head -n1 | grep '/dev/disk[0-9]*' | awk '{print $1}'`
+ if [ ! "x$?" = "x0" ] ; then
+     echo "ERROR: unable to successfully get the hdid device name"
+     exit 1
+@@ -181,7 +181,7 @@
+     exit 1
+ fi
+ 
+-hdidMountedDisk=`hdid ${DMG}.sparseimage | head -1 | grep '/dev/disk[0-9]*' | awk '{print $1}'`
++hdidMountedDisk=`hdid ${DMG}.sparseimage | head -n1 | grep '/dev/disk[0-9]*' | awk '{print $1}'`
+ if [ ! "x$?" = "x0" ] ; then
+     echo "ERROR: unable to successfully get the mounted hdid device name"
+     exit 1
+diff -dur brlcad-7.6.2/sh/vers.sh brlcad-7.6.2-p/sh/vers.sh
+--- brlcad-7.6.2/sh/vers.sh	2005-09-29 08:37:36.000000000 +0200
++++ brlcad-7.6.2-p/sh/vers.sh	2005-10-28 02:16:27.000000000 +0200
+@@ -68,7 +68,7 @@
+ # Obtain RELEASE number
+ if test -r $path_to_vers_sh/../configure.ac ; then
+ 	for i in 1 2 3 4 ; do
+-		version_script="`grep VERSION $path_to_vers_sh/../configure.ac | grep -v SUBST | head -$i | tail -1`"
++		version_script="`grep VERSION $path_to_vers_sh/../configure.ac | grep -v SUBST | head -n$i | tail -n1`"
+ 		eval "$version_script"
+ 	done
+ 	if test ! "x$BRLCAD_VERSION" = "x" ; then
+--- brlcad-7.6.2/sh/header.sh~	2005-10-29 03:46:56.000000000 +0200
++++ brlcad-7.6.2/sh/header.sh	2005-10-29 03:52:48.000000000 +0200
+@@ -624,7 +624,7 @@
+     echo "${block}" >> $FILE
+ fi
+ 
+-tail +${skip} ${FILE}.backup >> $FILE
++tail -n+${skip} ${FILE}.backup >> $FILE
+ 
+ 
+ exit 0
diff --git a/package/stf/brlcad/ignore-libtk-config-error.patch b/package/stf/brlcad/ignore-libtk-config-error.patch
new file mode 100644
index 000000000..da41efa85
--- /dev/null
+++ b/package/stf/brlcad/ignore-libtk-config-error.patch
@@ -0,0 +1,10 @@
+--- ./configure~	2005-10-29 06:35:42.000000000 +0200
++++ ./configure	2005-10-29 08:05:52.000000000 +0200
+@@ -26602,7 +26602,6 @@
+     }
+     if (Tk_Init(interp) == TCL_ERROR) {
+ 	fprintf(stderr, "Tk_Init returned error\n");
+-	return 1;
+     }
+ 
+ #if TK_MAJOR_VERSION < 8