summaryrefslogtreecommitdiff
path: root/parallel/mpi-ch/patches/patch-al
blob: 85442163a38d00e6b0ad1ca31a57e0177284b94b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
$NetBSD: patch-al,v 1.7 2005/03/03 12:01:30 garbled Exp $
--- util/mpiinstall.in.orig	2004-07-02 10:34:43.000000000 -0700
+++ util/mpiinstall.in	2005-03-03 02:43:21.000000000 -0700
@@ -172,7 +172,7 @@
     bindir=$prefix/bin
     sbindir=$prefix/sbin
     includedir=$prefix/include
-    sysconfdir=$prefix/etc
+    sysconfdir=$prefix/mpi-ch/etc
     libdir=$prefix/lib
     sharedlib_dir=$libdir/shared
     messagecat_dir=$libdir
@@ -453,9 +453,11 @@
 MkDir $docdir
 MkDir $sysconfdir
 
-MkDir $prefix/examples
+MkDir $prefix/share/util
+MkDir $prefix/share/util/machines
+MkDir $prefix/share/examples/mpi-ch
 if [ -n "$CPP_DIR" -a "$buildcpp" = 1 ] ; then 
-    MkDir $prefix/examples/$CPP_DIR
+    MkDir $prefix/share/examples/mpi-ch/$CPP_DIR
     MkDir $includedir/mpi2c++
 fi
 
@@ -697,7 +699,7 @@
     #	$CPRP -r util/machines $prefix/util/machines.anl
     for file in util/machines/machines* ; do
         if [ -s $file ] ; then 
-            CopyFile $file $datadir
+            CopyFile $file $prefix/share/util/machines
 	fi
     done
     #
@@ -994,6 +996,8 @@
 CopyFile $top_srcdir/util/cleanipcs $sbindir $XMODE
 #
 # Example programs
+# We install all example programs, so we can skip these
+if [ ! true ]; then
 CopyFile $top_srcdir/installtest/Makefile.in $prefix/examples
 #
 # This SHOULD use mpireconfig...
@@ -1027,14 +1031,16 @@
 $Show "(cd $DESTDIR$prefix/examples ; /bin/rm -f mpirun ; \
 	  ln -s ../bin/mpirun mpirun )"
 echo "/bin/rm -f $prefix/examples/mpirun" >> $UNINSTALLFILE
+
+fi # no examples
 #
 echo "About to run installation test..."
 if [ "x$DESTDIR" = "x" ]; then
   # only works when DESTDIR is blank, and installing on final location.
-  $Show "(cd $DESTDIR$prefix/examples; $MAKE all ; $MAKE clean )"
+  $Show "(cd $prefix/share/examples/mpi-ch; $MAKE all ; $MAKE clean )"
   if [ @SHAREDKIND@ != "ignore" ] ; then
     echo "About to run installation test for shared libraries ..."
-    $Show "(cd $DESTDIR$prefix/examples; MPICH_USE_SHLIB="yes"; export MPICH_USE_SHLIB; $MAKE all ; $MAKE clean )"
+    $Show "(cd $prefix/share/examples/mpi-ch; MPICH_USE_SHLIB="yes"; export MPICH_USE_SHLIB; $MAKE all ; $MAKE clean )"
   fi
 fi
 #
@@ -1043,39 +1049,40 @@
 if [ -n "$CPP_DIR" -a "$buildcpp" = 1 ] ; then 
 # Removed the installation of these extra examples.  
     # C++ Example programs 
-#    CopyFile $top_srcdir/installtest/mpi-2-c++/Makefile.in $prefix/examples/$CPP_DIR
+    CopyFile $top_srcdir/installtest/mpi-2-c++/Makefile.in $prefix/share/examples/mpi-ch/$CPP_DIR
     #
     prefix=$APREFIX
-#      CPPEXDIR=$top_srcdir/$CPP_DIR/contrib/examples
+      CPPEXDIR=$top_srcdir/$CPP_DIR/contrib/examples
 #      # This isn't correct because it doesn't handle all of the fields in
 #      # the C++ examples Makefile, particularly the TEMPLATE_REP field
 #      # The intent here is to update the directories; but we also need
 #      # to update a few additional fields
-#      (cd $prefix/examples/$CPP_DIR ; $bindir/mpireconfig Makefile )
-#      echo "(cd $prefix/examples/$CPP_DIR ; $MAKE clean)" >> $UNINSTALLFILE
-#      echo "/bin/rm -f $prefix/examples/$CPP_DIR/Makefile" >> $UNINSTALLFILE
-#      prefix=$Savevar
-#      CopyFile $CPPEXDIR/hello_world.cc $prefix/examples/$CPP_DIR
-#      CopyFile $CPPEXDIR/ring.cc $prefix/examples/$CPP_DIR
-#      CopyFile $CPPEXDIR/topology.cc $prefix/examples/$CPP_DIR
-#      CopyFile $CPPEXDIR/user_bcast.cc $prefix/examples/$CPP_DIR
-#      CopyFile $CPPEXDIR/chapter_10_mpi2.cc $prefix/examples/$CPP_DIR
-#      CopyFile $CPPEXDIR/pi.cc $prefix/examples/$CPP_DIR
-#      CopyFile $CPPEXDIR/README $prefix/examples/$CPP_DIR
+	(cd $prefix/share/examples/mpi-ch/$CPP_DIR ; $bindir/mpireconfig Makefile )
+	echo "(cd $prefix/share/examples/mpi-ch/$CPP_DIR ; $MAKE clean)" >> $UNINSTALLFILE
+	echo "/bin/rm -f $prefix/share/examples/mpi-ch/$CPP_DIR/Makefile" >> $UNINSTALLFILE
+      prefix=$Savevar
+    CopyFile $CPPEXDIR/hello_world.cc $prefix/share/examples/mpi-ch/$CPP_DIR
+    CopyFile $CPPEXDIR/ring.cc $prefix/share/examples/mpi-ch/$CPP_DIR
+    CopyFile $CPPEXDIR/topology.cc $prefix/share/examples/mpi-ch/$CPP_DIR
+    CopyFile $CPPEXDIR/user_bcast.cc $prefix/share/examples/mpi-ch/$CPP_DIR
+    CopyFile $CPPEXDIR/chapter_10_mpi2.cc $prefix/share/examples/mpi-ch/$CPP_DIR
+    CopyFile $CPPEXDIR/pi.cc $prefix/share/examples/mpi-ch/$CPP_DIR
+    CopyFile $CPPEXDIR/README $prefix/share/examples/mpi-ch/$CPP_DIR
+
 #      #
 #      # Test build the C++ examples
-#      $Show "(cd $prefix/examples/$CPP_DIR ; /bin/rm -f mpirun ; \
-#  	      ln -s ../../bin/mpirun mpirun )"
-#      echo "/bin/rm -f $prefix/examples/$CPP_DIR/mpirun" >> $UNINSTALLFILE
-#      #
-#      echo "About to run C++ installation test..."
-#      $Show "(cd $prefix/examples/$CPP_DIR; $MAKE ; $MAKE clean)"
+    $Show "(cd $prefix/share/examples/mpi-ch/$CPP_DIR ; /bin/rm -f mpirun ; \
+       ln -s $bindir/mpirun mpirun )"
+    echo "/bin/rm -f $prefix/share/examples/mpi-ch/$CPP_DIR/mpirun" >> $UNINSTALLFILE
+
+      echo "About to run C++ installation test..."
+      $Show "(cd $prefix/share/examples/mpi-ch/$CPP_DIR; $MAKE ; $MAKE clean)"
 #      # A temporary fix because C++ clean doesn't remove any template 
 #      # directories.  This will eventually need to be changed into a for loop
 #      # (even better, the clean target in the Makefile should be fixed)
-#      if [ -d $prefix/examples/$CPP_DIR/ii_files ] ; then
-#          $Show rm -rf $prefix/examples/$CPP_DIR/ii_files
-#      fi
+      if [ -d $prefix/share/examples/mpi-ch/$CPP_DIR/ii_files ] ; then
+          $Show rm -rf $prefix/share/examples/mpi-ch/$CPP_DIR/ii_files
+      fi
     #
 fi
 #