File: Makefile

package info (click to toggle)
sdpa 7.3.20-2
  • links: PTS
  • area: main
  • in suites: forky, sid
  • size: 1,688 kB
  • sloc: cpp: 15,021; sh: 4,870; makefile: 318; ansic: 81
file content (78 lines) | stat: -rw-r--r-- 3,857 bytes parent folder | download | duplicates (3)
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
# This file is a component of SDPA
# Copyright (C) 2004-2020 SDPA Project

# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.

# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.

# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA

SDPA_MAKEFILE = ../Makefile
# This file is automatically made by './configure' script
###################################################################
# The following variables are set from 
# the arguments given to './configure' script for building SDPA
###################################################################
SDPA_PACKAGE= ${shell grep "^PACKAGE_STRING =" ${SDPA_MAKEFILE} | awk '{printf("%s.%s",$$3,$$4)}'}

SDPA_DIR    = ${shell grep "^prefix ="         ${SDPA_MAKEFILE} | cut -f2 -d= | sed 's+ ++'}
SDPA_LIB    = ${SDPA_DIR}/lib/libsdpa.a 
MUMPS_DIR   = ${shell grep "^MUMPS_DIR ="      ${SDPA_MAKEFILE} | cut -f2 -d= | sed 's+ ++'}
MUMPS_INCLUDE   = ${shell grep "^MUMPS_INCLUDE ="  ${SDPA_MAKEFILE} | cut -f2 -d= | sed 's+ ++'}
MUMPS_LIBS  = ${shell grep "^MUMPS_LIBS ="     ${SDPA_MAKEFILE} | cut -f2 -d= | sed 's+ ++'}
CC          = ${shell grep "^CC ="           ${SDPA_MAKEFILE} | cut -f2  -d=}
CFLAGS      = ${shell grep "^CFLAGS = "      ${SDPA_MAKEFILE} | cut -f2- -d=}
CXX         = ${shell grep "^CXX ="          ${SDPA_MAKEFILE} | cut -f2  -d=}
CXXFLAGS    = ${shell grep "^CXXFLAGS = "    ${SDPA_MAKEFILE} | cut -f2- -d=}
CPPFLAGS    = ${shell grep "^CPPFLAGS = "    ${SDPA_MAKEFILE} | cut -f2- -d=}
FC          = ${shell grep "^FC ="           ${SDPA_MAKEFILE} | cut -f2  -d=}
FCFLAGS     = ${shell grep "^FCFLAGS = "     ${SDPA_MAKEFILE} | cut -f2- -d=}
LAPACK_LIBS = ${shell grep "^LAPACK_LIBS = " ${SDPA_MAKEFILE} | cut -f2  -d=}
BLAS_LIBS   = ${shell grep "^BLAS_LIBS = "   ${SDPA_MAKEFILE} | cut -f2  -d=}
PTHREAD_INCLUDE= ${shell grep "^PTHREAD_INCLUDE = " ${SDPA_MAKEFILE} | cut -f2 -d=}
PTHREAD_LIBS= ${shell grep "^PTHREAD_LIBS = " ${SDPA_MAKEFILE} | cut -f2 -d=}
FCLIBS      = ${shell grep "^FCLIBS = "      ${SDPA_MAKEFILE} | cut -f2 -d=}
VERSION     = ${shell grep "^VERSION = "     ${SDPA_MAKEFILE} | cut -f2 -d=}
###################################################################

TARGET = make.inc
all: ${TARGET}
${TARGET}:
	rm -f make.inc
	echo "VERSION     = " ${VERSION}   >> ${TARGET}
	echo "SDPA_DIR    = " ${SDPA_DIR}  >> ${TARGET}
	echo "SDPA_LIB    = " ${SDPA_LIB}  >> ${TARGET} 
	echo "MUMPS_DIR   = " ${MUMPS_DIR} >> ${TARGET}
	echo "CC          = " ${CC} >> ${TARGET}
	echo "CFLAGS      = " ${CFLAGS} >> ${TARGET}
	echo "CXX         = " ${CXX} >> ${TARGET}
	echo "CXXFLAGS    = " ${CXXFLAGS} >> ${TARGET}
	echo "CPPFLAGS    = " ${CPPFLAGS} >> ${TARGET}
	echo "FC          = " ${FC} >> ${TARGET}
	echo "FCFLAGS     = " ${FCFLAGS} >> ${TARGET}
	echo "LAPACK_LIBS = " ${LAPACK_LIBS} >> ${TARGET}
	echo "BLAS_LIBS   = " ${BLAS_LIBS} >> ${TARGET}
	echo "PTHREAD_INCLUDE= " ${PTHREAD_INCLUDE} >> ${TARGET}
	echo "PTHREAD_LIBS= " ${PTHREAD_LIBS} >> ${TARGET}
	echo "FCLIBS      = " ${FCLIBS} >> ${TARGET}
	echo "MUMPS_INCLUDE = " ${MUMPS_INCLUDE} >> ${TARGET}
	echo "MUMPS_LIBS = "  ${MUMPS_LIBS} >> ${TARGET}
	echo "SDPA_LIBS = " ${SDPA_LIB} ${MUMPS_LIBS}\
	       ${LAPACK_LIBS} ${BLAS_LIBS} \
	       ${FCLIBS} ${PTHREAD_LIBS}  >> ${TARGET}

force: clean all
clean:
	rm -f make.inc *~
distclean: clean
install: all
uninstall: