1
1
openmpi/src/tools/win_makefile

111 строки
3.2 KiB
Plaintext
Исходник Обычный вид История

#!/bin/sh
#
# This is a simple makefile for windows which makes all the components which are
# required for super computing. Too lazy to open up visual studio each and every
# time to compile a component, so just adding this to the svn repository
#
topdir = `echo $(CURDIR) | sed 's/^\//C:\/cygwin\//g' | sed 's/\/src\/tools//g'`
install_dir = ${prefix}
libdir = ${prefix}/lib
bindir = ${prefix}/bin
incdir = ${prefix}/include
# list of components to build with the c compiler
C_SUBDIRS = \
mpirun \
ompid
# list of components to build with the cpp compiler
# (because of the problem with OBJ_CLASS_INSTANCE)
CPP_SUBDIRS = \
ompi_info
CC = cl
INCL = \
/I"${topdir}/src/win32/generated_include" \
/I"${topdir}/src/win32/" \
/I"${topdir}/src" \
/I"${topdir}/include"
CFLAGS = \
/DWIN32 \
/DOMPI_SYSCONFDIR="\"${prefix}/share\"" \
/nologo \
/c
CPPFLAGS = \
/DWIN32 \
/DOMPI_SYSCONFDIR="\"${prefix}/share\"" \
/c \
/TP \
/nologo \
/EHsc
ADD_INCL = \
/DOMPI_WANT_F90_BINDINGS="\"not implemented\"" \
/DOMPI_WANT_F90_BINDINGS="\"not implemented\"" \
/DOMPI_CONFIGURE_USER="\"not implemented\"" \
/DOMPI_CONFIGURE_DATE="\"not implemented\"" \
/DOMPI_CONFIGURE_HOST="\"not implemented\"" \
/DOMPI_F90="\"not implemented\"" \
/DOMPI_WANT_F90_BINDINGS="\"not implemented\"" \
/DOMPI_BUILD_CFLAGS="\"not implemented\"" \
/DOMPI_BUILD_CXXFLAGS="\"not implemented\"" \
/DOMPI_BUILD_FFLAGS="\"not implemented\"" \
/DOMPI_BUILD_FCFLAGS="\"not implemented\"" \
/DOMPI_BUILD_LDFLAGS="\"not implemented\"" \
/DOMPI_BUILD_LIBS="\"not implemented\"" \
/DOMPI_MAJOR_VERSION="\"not implemented\"" \
/DOMPI_MINOR_VERSION="\"not implemented\"" \
/DOMPI_RELEASE_VERSION="\"not implemented\"" \
/DOMPI_ALPHA_VERSION="\"not implemented\"" \
/DOMPI_BETA_VERSION="\"not implemented\"" \
/DOMPI_SVN_VERSION="\"not implemented\"" \
/DOMPI_PREFIX="\"${prefix}\"" \
/DOMPI_BINDIR="\"${bindir}\"" \
/DOMPI_LIBDIR="\"${libdir}\"" \
/DOMPI_INCDIR="\"${incdir}\"" \
/DOMPI_PKGLIBDIR="\"${libdir}\""
# link with ompi.lib to resolve external symbols
OMPILIB = \
"${topdir}/vcproj/ompi/Debug/ompi.lib"
LINK = link
LINKFLAGS = \
/DLL \
/DEFAULTLIB:${OMPILIB}
all: \
clibs \
cpplibs
clibs: ${C_SUBDIRS}
@for dirs in ${C_SUBDIRS}; do \
(echo "Entering $$dirs"; cd $$dirs; ${CC} ${CFLAGS} ${INCL} *.c; ${LINK} ${LINKFLAGS} *.obj); \
done
cpplibs: ${CPP_SUBDIRS}
@for dirs in ${CPP_SUBDIRS}; do \
(echo "Entering $$dirs"; cd $$dirs; ${CC} ${CPPFLAGS} ${INCL} ${ADD_INCL} *.cc; ${LINK} ${LINKFLAGS} *.obj); \
done
install:
@for dirs in ${CPP_SUBDIRS}; do \
(${CC} ${CPPFLAGS} ${INCL} ${ADD_INCL} *.cc; ${LINK} ${LINKFLAGS} *.obj); \
done
.PHONY: clean
clean:
@for dirs in ${C_SUBDIRS}; do \
(echo "Entering $$dirs"; cd $$dirs; rm -rf *.lib *.obj *.exp;); \
done
@for dirs in ${C_PPSUBDIRS}; do \
(echo "Entering $$dirs"; cd $$dirs; rm -rf *.lib *.obj *.exp;); \
done