~ubuntu-branches/debian/sid/lammps/sid

« back to all changes in this revision

Viewing changes to src/MAKE/MACHINES/Makefile.power

  • Committer: Package Import Robot
  • Author(s): Anton Gladky
  • Date: 2015-04-29 23:44:49 UTC
  • mfrom: (5.1.3 experimental)
  • Revision ID: package-import@ubuntu.com-20150429234449-mbhy9utku6hp6oq8
Tags: 0~20150313.gitfa668e1-1
Upload into unstable.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# power = IBM Power5+, mpCC_r, native MPI, FFTW
 
2
 
 
3
SHELL = /bin/sh
 
4
.SUFFIXES: .cpp .u
 
5
 
 
6
# ---------------------------------------------------------------------
 
7
# compiler/linker settings
 
8
# specify flags and libraries needed for your compiler
 
9
 
 
10
CC =            mpCC_r
 
11
CCFLAGS =       -O3 -qnoipa -qlanglvl=oldmath
 
12
SHFLAGS =       -fPIC
 
13
DEPFLAGS =      -M
 
14
 
 
15
LINK =          mpCC_r
 
16
LINKFLAGS =     -O -qnoipa -qlanglvl=oldmath -bmaxdata:0x70000000
 
17
LIB =           -lm
 
18
SIZE =          size
 
19
 
 
20
ARCHIVE =       ar
 
21
ARFLAGS =       -rc
 
22
SHLIBFLAGS =    -shared
 
23
 
 
24
# ---------------------------------------------------------------------
 
25
# LAMMPS-specific settings, all OPTIONAL
 
26
# specify settings for LAMMPS features you will use
 
27
# if you change any -D setting, do full re-compile after "make clean"
 
28
 
 
29
# LAMMPS ifdef settings
 
30
# see possible settings in Section 2.2 (step 4) of manual
 
31
 
 
32
LMP_INC =       -DLAMMPS_GZIP
 
33
 
 
34
# MPI library
 
35
# see discussion in Section 2.2 (step 5) of manual
 
36
# MPI wrapper compiler/linker can provide this info
 
37
# can point to dummy MPI library in src/STUBS as in Makefile.serial
 
38
# use -D MPICH and OMPI settings in INC to avoid C++ lib conflicts
 
39
# INC = path for mpi.h, MPI compiler settings
 
40
# PATH = path for MPI library
 
41
# LIB = name of MPI library
 
42
 
 
43
MPI_INC =       
 
44
MPI_PATH = 
 
45
MPI_LIB =       
 
46
 
 
47
# FFT library
 
48
# see discussion in Section 2.2 (step 6) of manaul
 
49
# can be left blank to use provided KISS FFT library
 
50
# INC = -DFFT setting, e.g. -DFFT_FFTW, FFT compiler settings
 
51
# PATH = path for FFT library
 
52
# LIB = name of FFT library
 
53
 
 
54
FFT_INC =       -DFFT_FFTW -I/scr/oppe/LAMMPS/fftw-2.1.5/include
 
55
FFT_PATH =      -L/scr/oppe/LAMMPS/fftw-2.1.5/lib
 
56
FFT_LIB =       -lfftw
 
57
 
 
58
# JPEG and/or PNG library
 
59
# see discussion in Section 2.2 (step 7) of manual
 
60
# only needed if -DLAMMPS_JPEG or -DLAMMPS_PNG listed with LMP_INC
 
61
# INC = path(s) for jpeglib.h and/or png.h
 
62
# PATH = path(s) for JPEG library and/or PNG library
 
63
# LIB = name(s) of JPEG library and/or PNG library
 
64
 
 
65
JPG_INC =       
 
66
JPG_PATH =      
 
67
JPG_LIB =       
 
68
 
 
69
# ---------------------------------------------------------------------
 
70
# build rules and dependencies
 
71
# do not edit this section
 
72
 
 
73
include Makefile.package.settings
 
74
include Makefile.package
 
75
 
 
76
EXTRA_INC = $(LMP_INC) $(PKG_INC) $(MPI_INC) $(FFT_INC) $(JPG_INC) $(PKG_SYSINC)
 
77
EXTRA_PATH = $(PKG_PATH) $(MPI_PATH) $(FFT_PATH) $(JPG_PATH) $(PKG_SYSPATH)
 
78
EXTRA_LIB = $(PKG_LIB) $(MPI_LIB) $(FFT_LIB) $(JPG_LIB) $(PKG_SYSLIB)
 
79
 
 
80
# Path to src files
 
81
 
 
82
vpath %.cpp ..
 
83
vpath %.h ..
 
84
 
 
85
# Link target
 
86
 
 
87
$(EXE): $(OBJ)
 
88
        $(LINK) $(LINKFLAGS) $(EXTRA_PATH) $(OBJ) $(EXTRA_LIB) $(LIB) -o $(EXE)
 
89
        $(SIZE) $(EXE)
 
90
 
 
91
# Library targets
 
92
 
 
93
lib:    $(OBJ)
 
94
        $(ARCHIVE) $(ARFLAGS) $(EXE) $(OBJ)
 
95
 
 
96
shlib:  $(OBJ)
 
97
        $(CC) $(CCFLAGS) $(SHFLAGS) $(SHLIBFLAGS) $(EXTRA_PATH) -o $(EXE) \
 
98
        $(OBJ) $(EXTRA_LIB) $(LIB)
 
99
 
 
100
# Compilation rules
 
101
 
 
102
%.o:%.cpp
 
103
        $(CC) $(CCFLAGS) $(SHFLAGS) $(EXTRA_INC) -c $<
 
104
 
 
105
%.d:%.cpp
 
106
        $(CC) $(CCFLAGS) $(EXTRA_INC) $(DEPFLAGS) $< > $@
 
107
 
 
108
%.o:%.cu
 
109
        $(CC) $(CCFLAGS) $(SHFLAGS) $(EXTRA_INC) -c $<
 
110
 
 
111
# Individual dependencies
 
112
 
 
113
DEPENDS = $(OBJ:.o=.d)
 
114
sinclude $(DEPENDS)