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
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
|
diff -rwu mpiblast-1.6.0/ncbi/corelib/ncbienv.c mpiblast-1.6.0-patched/ncbi/corelib/ncbienv.c
--- mpiblast-1.6.0/ncbi/corelib/ncbienv.c 2009-11-22 01:17:48.000000000 -0500
+++ mpiblast-1.6.0-patched/ncbi/corelib/ncbienv.c 2011-08-06 17:10:08.000000000 -0400
@@ -1932,7 +1932,7 @@
static char **targv = NULL;
-#if defined(WIN_MAC)
+#if defined(WIN_MAC) || defined(OS_UNIX_DARWIN)
static FSSpec apFileSpec;
static Str255 apName;
static Handle apParam;
@@ -2047,7 +2047,7 @@
}
}
#endif /* defined(OS_UNIX_DARWIN) */
-#endif /* defined(WIN_MAC) */
+#endif /* defined(WIN_MAC) || defined(OS_UNIX_DARWIN) */
#if defined(OS_MSWIN) || defined(OS_VMS)
diff -rwu mpiblast-1.6.0/ncbi/make/makedis.csh mpiblast-1.6.0-patched/ncbi/make/makedis.csh
--- mpiblast-1.6.0/ncbi/make/makedis.csh 2010-06-28 21:04:36.000000000 -0400
+++ mpiblast-1.6.0-patched/ncbi/make/makedis.csh 2011-08-06 17:06:42.000000000 -0400
@@ -1,6 +1,6 @@
#!/bin/csh -f
#
-# $Id: makedis.csh 148594 2008-12-30 15:11:36Z ucko $
+# $Id: makedis.csh 179886 2010-01-04 17:28:02Z ucko $
#
## PUBLIC DOMAIN NOTICE
# National Center for Biotechnology Information
@@ -54,7 +54,7 @@
endif
ls -l $tar_file
- tar xvf $tar_file
+ tar xf $tar_file
else
# make sure that ncbi/build directory exists
if ( ! -d "ncbi/build" ) then
@@ -74,6 +74,7 @@
set HAVE_MAC=0
#we will try to build OpenGL version of vibrant
set HAVE_OGL=1
+set MPBL_HAVE_MAC=0
switch ($os)
case SunOS:
@@ -164,7 +165,7 @@
gcc -v
switch (`uname -m`)
case "ia64":
- if (-e `which ecc`) then
+ if (-e `which icc`) then
set platform=linux_ecc
else
set platform=linux
@@ -253,7 +254,11 @@
endif
endif
set HAVE_MOTIF=0
- set HAVE_MAC=1
+#MPIBLAST <<<
+# set HAVE_MAC=1
+ set MPBL_HAVE_MAC=1
+ set HAVE_MAC=0
+#MPIBLAST
breaksw
case NetBSD:
set platform=netbsd
@@ -319,6 +324,7 @@
goto BADPLATFORM
endif
+
set noglob
# take the file $NCBI_DOT_MK and convert it to be suitable for csh eval:
# (1) remove comments at the beginning of the lines
@@ -328,6 +334,7 @@
eval `sed -e 's/^ *#.*//g' -e 's/\$(\([a-zA-Z_]*\))/\${\1}/g' -e 's/ *= */=/g' -e 's/^\([^=]*\)=\(.*\)$/setenv \1 "\2";/' < $NCBI_DOT_MK`
unset noglob
+
# disable assert() unless ENABLE_ASSERT is set
if ("$?ENABLE_ASSERT" == 0) then
set NCBI_OPTFLAG="-DNDEBUG $NCBI_OPTFLAG"
@@ -441,13 +448,23 @@
set NET_VIB=(VIB=\"blastcl3 taxblast idfetch bl2seq asn2gb tbl2asn gene2xml $NONVIBWWWBLAST \")
endif
+# MPIBLAST <<<<<
+if ("$MPBL_HAVE_MAC" == 1) then
+set CMD='make $MFLG \
+ CFLAGS1=\"-I/Developer/Headers/FlatCarbon $NCBI_OPTFLAG $NCBI_CFLAGS1 $OGL_INCLUDE $PNG_INCLUDE\" \
+ LDFLAGS1=\"$NCBI_LDFLAGS1\" OTHERLIBS=\"$NCBI_OTHERLIBS\" \
+ SHELL=\"$NCBI_MAKE_SHELL\" LCL=\"$NCBI_DEFAULT_LCL\" \
+ RAN=\"$NCBI_RANLIB\" AR=\"$NCBI_AR\" CC=\"$NCBI_CC\" $ALL_VIB all'
+else
set CMD='make $MFLG \
CFLAGS1=\"$NCBI_OPTFLAG $NCBI_CFLAGS1 $OGL_INCLUDE $PNG_INCLUDE\" \
LDFLAGS1=\"$NCBI_LDFLAGS1\" OTHERLIBS=\"$NCBI_OTHERLIBS\" \
SHELL=\"$NCBI_MAKE_SHELL\" LCL=\"$NCBI_DEFAULT_LCL\" \
RAN=\"$NCBI_RANLIB\" AR=\"$NCBI_AR\" CC=\"$NCBI_CC\" $ALL_VIB all'
+endif
eval echo $CMD
eval echo $CMD | sh
+# MPIBLAST >>>>>
set make_stat = $status
@@ -463,12 +480,18 @@
endif
# MPIBLAST <<<<<
-
+if ("$MPBL_HAVE_MAC" == 1) then
set CMD='make $MFLG -f makempiblast.unx CFLAGS1=\"$NCBI_OPTFLAG $NCBI_CFLAGS1\" \
LDFLAGS1=\"$NCBI_LDFLAGS1\" SHELL=\"$NCBI_MAKE_SHELL\" \
LCL=\"$NCBI_DEFAULT_LCL\" RAN=\"$NCBI_RANLIB\" AR=\"$NCBI_AR\" CC=\"$NCBI_CC\"'
+else
+set CMD='make $MFLG -f makempiblast.unx CFLAGS1=\"$NCBI_OPTFLAG $NCBI_CFLAGS1\" \
+ LDFLAGS1=\"$NCBI_LDFLAGS1\" SHELL=\"$NCBI_MAKE_SHELL\" \
+ LCL=\"$NCBI_DEFAULT_LCL\" RAN=\"$NCBI_RANLIB\" AR=\"$NCBI_AR\" CC=\"$NCBI_CC\"'
+endif
eval echo $CMD
eval echo $CMD | sh
+if ($status != 0) exit $status
if( "$platform" == "bluegenel" || "$platform" == "bluegenep" ) then
exit 0
@@ -476,7 +499,7 @@
# MPIBLAST >>>>>
set CMD='make $MFLG -f makedemo.unx CFLAGS1=\"$NCBI_OPTFLAG $NCBI_CFLAGS1\" \
- LDFLAGS1=\"$NCBI_LDFLAGS1\" SHELL=\"$NCBI_MAKE_SHELL\" \
+ LDFLAGS1=\"$NCBI_LDFLAGS1\" SHELL=\"$NCBI_MAKE_SHELL\" OTHERLIBS=\"$NCBI_OTHERLIBS\" \
LCL=\"$NCBI_DEFAULT_LCL\" RAN=\"$NCBI_RANLIB\" AR=\"$NCBI_AR\" CC=\"$NCBI_CC\" $DEMO_VIB'
eval echo $CMD
eval echo $CMD | sh
@@ -495,7 +518,7 @@
set CMD='make $MFLG -f makedemo.unx CFLAGS1=\"$NCBI_OPTFLAG $NCBI_CFLAGS1\" \
- LDFLAGS1=\"$NCBI_LDFLAGS1\" SHELL=\"$NCBI_MAKE_SHELL\" \
+ LDFLAGS1=\"$NCBI_LDFLAGS1\" SHELL=\"$NCBI_MAKE_SHELL\" OTHERLIBS=\"$NCBI_OTHERLIBS\" \
LCL=\"$NCBI_DEFAULT_LCL\" RAN=\"$NCBI_RANLIB\" AR=\"$NCBI_AR\" CC=\"$NCBI_CC\" \
THREAD_OBJ=$NCBI_THREAD_OBJ THREAD_OTHERLIBS=\"$NCBI_MT_OTHERLIBS\" \
$DEMO_VIB $mtapps'
diff -rwu mpiblast-1.6.0/src/Makefile.am mpiblast-1.6.0-patched/src/Makefile.am
--- mpiblast-1.6.0/src/Makefile.am 2009-11-22 01:17:48.000000000 -0500
+++ mpiblast-1.6.0-patched/src/Makefile.am 2011-08-06 17:06:42.000000000 -0400
@@ -2,7 +2,7 @@
-D_LARGEFILE64_SOURCE -DMPIBLAST_PIO \
-I$(top_srcdir)/include/ -I@CONFIG_NCBIDIR@/include/ $(MPE_INCS) \
-I@CONFIG_NCBIDIR@/corelib/
-AM_CXXFLAGS = -DMPICH_IGNORE_CXX_SEEK -DINSTALL_PREFIX="\"@prefix@\"" \
+AM_CXXFLAGS = -DMPICH_IGNORE_CXX_SEEK -DOMPI_SKIP_MPICXX -DINSTALL_PREFIX="\"@prefix@\"" \
@COMPILE_FLAGS@ -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE \
-I$(top_srcdir)/include/ -I@CONFIG_NCBIDIR@/include/ $(MPE_INCS) \
-I@CONFIG_NCBIDIR@/corelib/
@@ -31,7 +31,7 @@
@CONFIG_NCBIDIR@/build/blast_hooks.o -lmyncbitool -lblastcompadj -lmyncbiobj \
-lmyncbi -L. -L@CONFIG_NCBIDIR@/lib/ $(MPE_LIBS) -lm @LINK_FLAGS@
mpiblast_DEPENDENCIES = @GETOPT_LONG_SYSTEM@
-mpiblast_CPPFLAGS = -DUSING_MPI -DMPICH_IGNORE_CXX_SEEK
+mpiblast_CPPFLAGS = -DUSING_MPI -DMPICH_IGNORE_CXX_SEEK -DOMPI_SKIP_MPICXX
mpiformatdb_SOURCES = mpiformatdb.cpp mpiblast_config.cpp mpiblast_config.hpp \
file_util.cpp file_util.hpp mpiblast_util.cpp mpiblast_util.hpp \
diff -rwu mpiblast-1.6.0/src/pio_intercept.h mpiblast-1.6.0-patched/src/pio_intercept.h
--- mpiblast-1.6.0/src/pio_intercept.h 2009-11-22 01:17:48.000000000 -0500
+++ mpiblast-1.6.0-patched/src/pio_intercept.h 2011-08-06 17:06:42.000000000 -0400
@@ -60,7 +60,7 @@
#include <txalign.h>
/* marcros are duplicated in ncbi files to avoid header file conflict */
-#define CHECK_NULPTR(x) if(x==NULL) fprintf(stderr, "%s, line%d: cannot allocate enough memory\n", __FILE__, __LINE__);
+#define CHECK_NULPTR(x) if(x==NULL) { perror("Cannot allocate enough memory:"); exit(-1); }
#ifndef NO_MPI
typedef struct _output_record {
|