Q1. Is there a Problem with my make file?
or
Q2. Is there some error in code?
I am using Debian 6.02 (Squeeze) amd - 64 bit.
Yesterday I downloaded OpenSees - Release 1 from below command:
svn co svn://opensees.berkeley.edu/usr/local/svn/OpenSees/trunk OpenSees
I picked ../MAKES/Makefile.def.Ubuntu9.04 for Makefile.def.
I customized the Makefile.def as shown below:
############################################################################
#
# Program: OpenSees
#
# Purpose: A Top-level Makefile to create the libraries needed
# to use the OpenSees framework. Works on Linux version 6.1
# and below.
#
# Written: fmk
# Created: 10/99
#
# Send bug reports, comments or suggestions to fmckenna@ce.berkeley.edu
#
############################################################################
# %---------------------------------%
# | SECTION 1: PROGRAM |
# %---------------------------------%
#
# Specify the location and name of the OpenSees interpreter program
# that will be created (if this all works!)
OpenSees_PROGRAM = $(HOME)/bin/OpenSees
OPERATING_SYSTEM = LINUX
GRAPHICS = UsingOpenGL
PROGRAMMING_MODE = SEQUENTIAL
DEBUG_MODE = NO_DEBUG
RELIABILITY = NO_RELIABILITY
# %---------------------------------%
# | SECTION 2: PATHS |
# %---------------------------------%
#
# Note: if vendor supplied BLAS and LAPACK libraries or if you have
# any of the libraries already leave the directory location blank AND
# remove the directory from DIRS.
BASE = /usr/local
HOME = /home/faisal
FE = $(HOME)/opensees-svn/OpenSees/SRC
BLASdir = $(HOME)/opensees-svn/OpenSees/OTHER/BLAS
CBLASdir = $(HOME)/opensees-svn/OpenSees/OTHER/CBLAS
LAPACKdir = $(HOME)/opensees-svn/OpenSees/OTHER/LAPACK
SUPERLUdir = $(HOME)/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC
ARPACKdir = $(HOME)/opensees-svn/OpenSees/OTHER/ARPACK
UMFPACKdir = $(HOME)/opensees-svn/OpenSees/OTHER/UMFPACK
METISdir = $(HOME)/opensees-svn/OpenSees/OTHER/METIS
AMDdir = $(HOME)/opensees-svn/OpenSees/OTHER/AMD
SRCdir = $(HOME)/opensees-svn/OpenSees/SRC
DIRS = $(BLASdir) $(CBLASdir) $(LAPACKdir) $(AMDdir) \
$(SUPERLUdir) $(ARPACKdir) $(UMFPACKdir) $(SRCdir) $(METISdir)
# %-------------------------------------------------------%
# | SECTION 3: LIBRARIES |
# | |
# | The following section defines the libraries that will |
# | be created and/or linked with when the libraries are |
# | being created or linked with. |
# %-------------------------------------------------------%
#
# Note: if vendor supplied BLAS and LAPACK libraries leave the
# libraries blank. You have to get your own copy of the tcl/tk
# library!!
#
# Note: For libraries that will be created (any in DIRS above)
# make sure the directory exsists where you want the library to go!
FE_LIBRARY = $(HOME)/lib/libOpenSees.a
NDARRAY_LIBRARY = $(HOME)/lib/libndarray.a # BJ_UCD jeremic@ucdavis.edu
MATMOD_LIBRARY = $(HOME)/lib/libmatmod.a # BJ_UCD jeremic@ucdavis.edu
BJMISC_LIBRARY = $(HOME)/lib/libBJmisc.a # BJ_UCD jeremic@ucdavis.edu
LAPACK_LIBRARY = $(HOME)/lib/libLapack.a
BLAS_LIBRARY = $(HOME)/lib/libBlas.a
SUPERLU_LIBRARY = $(HOME)/lib/libSuperLU.a
CBLAS_LIBRARY = $(HOME)/lib/libCBlas.a
ARPACK_LIBRARY = $(HOME)/lib/libArpack.a
UMFPACK_LIBRARY = $(HOME)/lib/libUmfpack.a
METIS_LIBRARY = $(HOME)/lib/libMetis.a
AMD_LIBRARY = $(HOME)/lib/libAMD.a
TCL_LIBRARY = /usr/lib/libtk8.4.so.0 /usr/lib/libX11.so /usr/lib/libtcl8.4.so.0
BLITZ_LIBRARY = /usr/lib/libblitz.so.0
GRAPHIC_LIBRARY = /usr/lib/libGL.so.1 /usr/lib/libGLU.so.1
# WATCH OUT .. These libraries are removed when 'make wipe' is invoked.
WIPE_LIBS = $(FE_LIBRARY) \
$(LAPACK_LIBRARY) \
$(BLAS_LIBRARY) \
$(CBLAS_LIBRARY) \
$(SUPERLU_LIBRARY) \
$(ARPACK_LIBRARY) \
$(UMFPACK_LIBRARY) \
$(AMD_LIBRARY) \
$(METIS_LIBRARY)
# %---------------------------------------------------------%
# | SECTION 4: COMPILERS |
# | |
# | The following macros specify compilers, linker/loaders, |
# | the archiver, and their options. You need to make sure |
# | these are correct for your system. |
# %---------------------------------------------------------%
# Compilers
CC++ = /usr/bin/g++
CC = /usr/bin/gcc
FC = /usr/bin/gfortran-4.4
AR = ar
ARFLAGS = cqls
RANLIB = ranlib
RANLIBFLAGS =
# Compiler Flags
#
# NOTES:
# C++ FLAGS TAKE need _UNIX or _WIN32 for preprocessor dircetives
# - the _WIN32 for the Windows95/98 or NT operating system.
# C FLAGS used -DUSE_VENDOR_BLAS (needed in SuperLU) if UNIX in C++ FLAGS
#
# modified as optimizaton currently causing problems with Steeln01 code
ifeq ($(DEBUG_MODE), DEBUG)
C++FLAGS = -Wall -D_LINUX -D_UNIX -D_TCL84 \
$(GRAPHIC_FLAG) $(RELIABILITY_FLAG) $(DEBUG_FLAG) $(PROGRAMMING_FLAG) \
-g -pg
CFLAGS = -Wall -pg $(GRAPHIC_FLAG) $(RELIABILITY_FLAG) $(DEBUG_FLAG) $(PROGRAMMING_FLAG)
FFLAGS = -Wall
# Linker
LINKER = $(CC++)
LINKFLAGS = -g -pg
else
C++FLAGS = -Wall -D_LINUX -D_UNIX -D_TCL84 \
$(GRAPHIC_FLAG) $(RELIABILITY_FLAG) $(DEBUG_FLAG) \
$(PROGRAMMING_FLAG) -O3 -ffloat-store
CFLAGS = -Wall -O2
FFLAGS = -Wall -O
# Linker
LINKER = $(CC++)
LINKFLAGS = -rdynamic -Wl
endif
GRAPHIC_FLAG = -D_GLX
# Misc
MAKE = make
CD = cd
ECHO = echo
RM = rm
RMFLAGS = -f
SHELL = /bin/sh
# %---------------------------------------------------------%
# | SECTION 5: COMPILATION |
# | |
# | The following macros specify the macros used in |
# | to compile the source code into object code. |
# %---------------------------------------------------------%
.SUFFIXES:
.SUFFIXES: .C .c .f .f90 .cpp .o .cpp
#
# %------------------%
# | Default command. |
# %------------------%
#
.DEFAULT:
@$(ECHO) "Unknown target $@, try: make help"
#
# %-------------------------------------------%
# | Command to build .o files from .f files. |
# %-------------------------------------------%
#
.cpp.o:
@$(ECHO) Making $@ from $<
$(CC++) $(C++FLAGS) $(INCLUDES) -c $< -o $@
.C.o:
@$(ECHO) Making $@ from $<
$(CC++) $(C++FLAGS) $(INCLUDES) -c $< -o $@
.c.o:
@$(ECHO) Making $@ from $<
$(CC) $(CFLAGS) -c $< -o $@
.f.o:
@$(ECHO) Making $@ from $<
$(FC) $(FFLAGS) -c $< -o $@
# %---------------------------------------------------------%
# | SECTION 6: OTHER LIBRARIES |
# | |
# | The following macros specify other libraries that must |
# | be linked with when creating executables. These are |
# | platform specific and typically order does matter!! |
# %---------------------------------------------------------%
MACHINE_LINKLIBS = -L$(BASE)/lib \
-L$(HOME)/lib
MACHINE_NUMERICAL_LIBS = -lm \
$(ARPACK_LIBRARY) \
$(SUPERLU_LIBRARY) \
$(UMFPACK_LIBRARY) \
$(LAPACK_LIBRARY) $(BLAS_LIBRARY) $(CBLAS_LIBRARY) \
$(AMD_LIBRARY) \
$(GRAPHIC_LIBRARY)\
-ldl -lgfortran -lpng
MACHINE_SPECIFIC_LIBS =
# %---------------------------------------------------------%
# | SECTION 7: INCLUDE FILES |
# | |
# | The following macros specify include files needed for |
# | compilation. |
# %---------------------------------------------------------%
MACHINE_INCLUDES = -I/usr/include \
-I$(BASE)/include \
-I/usr/include/cxx \
-I$(HOME)/include -I$(HOME)/blitz
# this file contains all the OpenSees/SRC includes
include $(FE)/Makefile.incl
TCL_INCLUDES = -I/usr/include/tcl8.4 -I/usr/include/
INCLUDES = $(TCL_INCLUDES) $(FE_INCLUDES) $(MACHINE_INCLUDES)
==========================================================================
But when I make, I get following error in the end:
/home/faisal/opensees-svn/OpenSees/SRC/system_of_eqn/linearSOE/sparseGEN/SuperLU.h:48:23: error: slu_ddefs.h: No such file or directory
In file included from commands.cpp:47:
/home/faisal/opensees-svn/OpenSees/SRC/modelbuilder/tcl/TclModelBuilder.cpp: In function ‘int TclCommand_addNodalLoad(void*, Tcl_Interp*, int, const char**)’:
/home/faisal/opensees-svn/OpenSees/SRC/modelbuilder/tcl/TclModelBuilder.cpp
/home/faisal/opensees-svn/OpenSees/SRC/modelbuilder/tcl/TclModelBuilder.cpp: In function ‘int TclCommand_addSP(void*, Tcl_Interp*, int, const char**)’:
/home/faisal/opensees-svn/OpenSees/SRC/modelbuilder/tcl/TclModelBuilder.cpp
/home/faisal/opensees-svn/OpenSees/SRC/modelbuilder/tcl/TclModelBuilder.cpp: In function ‘int TclCommand_addImposedMotionSP(void*, Tcl_Interp*, int, const char**)’:
/home/faisal/opensees-svn/OpenSees/SRC/modelbuilder/tcl/TclModelBuilder.cpp
/home/faisal/opensees-svn/OpenSees/SRC/modelbuilder/tcl/TclModelBuilder.cpp: In function ‘int TclCommand_Package(void*, Tcl_Interp*, int, const char**)’:
/home/faisal/opensees-svn/OpenSees/SRC/modelbuilder/tcl/TclModelBuilder.cpp
/home/faisal/opensees-svn/OpenSees/SRC/modelbuilder/tcl/TclModelBuilder.cpp
In file included from /home/faisal/opensees-svn/OpenSees/SRC/system_of_eqn/linearSOE/sparseGEN/SuperLU.h:49,
from commands.cpp:228:
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h: At global scope:
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:43: error: ‘int_t’ does not name a type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:44: error: ‘int_t’ does not name a type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:54: error: ‘int_t’ does not name a type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:56: error: ISO C++ forbids declaration of ‘int_t’ with no type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:56: error: expected ‘;’ before ‘*’ token
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:57: error: ISO C++ forbids declaration of ‘int_t’ with no type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:57: error: expected ‘;’ before ‘*’ token
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:67: error: ‘int_t’ does not name a type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:69: error: ISO C++ forbids declaration of ‘int_t’ with no type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:69: error: expected ‘;’ before ‘*’ token
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:70: error: ISO C++ forbids declaration of ‘int_t’ with no type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:70: error: expected ‘;’ before ‘*’ token
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:81: error: ‘int_t’ does not name a type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:82: error: ‘int_t’ does not name a type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:84: error: ISO C++ forbids declaration of ‘int_t’ with no type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:84: error: expected ‘;’ before ‘*’ token
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:85: error: ISO C++ forbids declaration of ‘int_t’ with no type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:85: error: expected ‘;’ before ‘*’ token
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:87: error: ISO C++ forbids declaration of ‘int_t’ with no type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:87: error: expected ‘;’ before ‘*’ token
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:88: error: ISO C++ forbids declaration of ‘int_t’ with no type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:88: error: expected ‘;’ before ‘*’ token
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:90: error: ISO C++ forbids declaration of ‘int_t’ with no type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:90: error: expected ‘;’ before ‘*’ token
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:106: error: ‘int_t’ does not name a type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:108: error: ISO C++ forbids declaration of ‘int_t’ with no type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:108: error: expected ‘;’ before ‘*’ token
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:110: error: ISO C++ forbids declaration of ‘int_t’ with no type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:110: error: expected ‘;’ before ‘*’ token
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:112: error: ISO C++ forbids declaration of ‘int_t’ with no type
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:112: error: expected ‘;’ before ‘*’ token
/home/faisal/opensees-svn/OpenSees/OTHER/SuperLU_3.0/SRC/supermatrix.h:123: error: ‘int_t’ does not name a type
In file included from commands.cpp:228:
/home/faisal/opensees-svn/OpenSees/SRC/system_of_eqn/linearSOE/sparseGEN/SuperLU.h:78: error: ‘superlu_options_t’ does not name a type
/home/faisal/opensees-svn/OpenSees/SRC/system_of_eqn/linearSOE/sparseGEN/SuperLU.h:79: error: ‘SuperLUStat_t’ does not name a type
commands.cpp: In function ‘int specifySOE(void*, Tcl_Interp*, int, const char**)’:
commands.cpp
commands.cpp: In function ‘int specifyIntegrator(void*, Tcl_Interp*, int, const char**)’:
commands.cpp:5018: warning: unused variable ‘result’
commands.cpp: In function ‘int eigenAnalysis(void*, Tcl_Interp*, int, const char**)’:
commands.cpp:5465: warning: unused variable ‘npRow’
commands.cpp:5466: warning: unused variable ‘npCol’
commands.cpp: In function ‘int removeObject(void*, Tcl_Interp*, int, const char**)’:
commands.cpp:5795: warning: unused variable ‘nodTag’
commands.cpp: In function ‘int sensNodeDisp(void*, Tcl_Interp*, int, const char**)’:
commands.cpp:6506: warning: deprecated conversion from string constant to ‘char*’
commands.cpp: In function ‘int sensNodeVel(void*, Tcl_Interp*, int, const char**)’:
commands.cpp:6555: warning: deprecated conversion from string constant to ‘char*’
commands.cpp: In function ‘int sensNodeAccel(void*, Tcl_Interp*, int, const char**)’:
commands.cpp:6604: warning: deprecated conversion from string constant to ‘char*’
commands.cpp: In function ‘int sectionForce(void*, Tcl_Interp*, int, const char**)’:
commands.cpp:6734: warning: deprecated conversion from string constant to ‘char*’
commands.cpp:6778: warning: deprecated conversion from string constant to ‘char*’
commands.cpp: In function ‘int sectionDeformation(void*, Tcl_Interp*, int, const char**)’:
commands.cpp:6802: warning: deprecated conversion from string constant to ‘char*’
commands.cpp:6846: warning: deprecated conversion from string constant to ‘char*’
commands.cpp: At global scope:
commands.cpp
make[2]: *** [commands.o] Error 1
make[2]: Leaving directory `/home/faisal/opensees-svn/OpenSees/SRC/tcl'
make[1]: *** [tcl] Error 2
make[1]: Leaving directory `/home/faisal/opensees-svn/OpenSees/SRC/modelbuilder/tcl'
make: *** [all] Error 2
=======================================================================================
Kindly help me to solve this problem and compile the code.