From 1a72b4d20a0dfbe6db17b19ad040a9417ae6bf60 Mon Sep 17 00:00:00 2001 From: Weston Ortiz Date: Mon, 31 Aug 2015 08:35:56 -0600 Subject: [PATCH] Add an example makefile for building brkfix with Trilinos --- Makefile.Trilinos | 78 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) create mode 100644 Makefile.Trilinos diff --git a/Makefile.Trilinos b/Makefile.Trilinos new file mode 100644 index 0000000..a9a1bb3 --- /dev/null +++ b/Makefile.Trilinos @@ -0,0 +1,78 @@ +#/************************************************************************ * +#* Goma - Multiphysics finite element software * +#* Sandia National Laboratories * +#* * +#* Copyright (c) 2014 Sandia Corporation. * +#* * +#* Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation, * +#* the U.S. Government retains certain rights in this software. * +#* * +#* This software is distributed under the GNU General Public License. * +#\************************************************************************/ + +# Makefile for brk/fix, a tool to add nodes to an EXODUS FE database +# +# Note: Usually you should use the Makefile automatically generated by +# running configure. This one is for quick and dirty development +# work. +# + SHELL = /bin/sh + +# PURE = purify -cache-dir="/tmp" + RM = rm -f + + CC = mpicc +# CC = /home/sntools/extras/mpi/mpich-1.2.7p1-gcc-3.4.6-32Bit/bin/mpicc + +# ACCESS = /usr/local/eng_sci/struct/current +# ACCESS = /home/goma/production/linux/SEAMS_2006-03-16-32-GCC + + GOMA_LIBS = /home/goma/production + + TRILINOS_TOP ?= $(GOMA_LIBS)/trilinos-12.2.1-Built + + include $(TRILINOS_TOP)/include/Makefile.export.Trilinos + + TRILINOS_INC ?= $(subst -I, -isystem, $(Trilinos_INCLUDE_DIRS) $(Trilinos_TPL_INCLUDE_DIRS)) + TRILINOS_LIB ?= $(Trilinos_LIBRARY_DIRS) $(Trilinos_TPL_LIBRARY_DIRS) \ + $(Trilinos_LIBRARIES) $(Trilinos_TPL_LIBRARIES) + + INCLUDES = $(_INC) -I. $(TRILINOS_INC) + + CDEBUGFLAGS = -g -Wall + + COPTIMIZEFLAGS = -Wall + +# DEFINES = -DHAVE_CONFIG_H=1 -DPOTATO_CHIP_DIET + DEFINES = -DHAVE_CONFIG_H=1 + + CFLAGS = $(CDEBUGFLAGS) $(COPTIMIZEFLAGS) $(CCOPTIONS) $(DEFINES) $(INCLUDES) + + LIBS = $(TRILINOS_LIB) + + FOBJS = fix.o rd_exo.o wr_exo.o rd_dpi.o wr_dpi.o utils.o \ + aalloc.o eh.o bbb.o exo_utils.o + + OBJS = brk.o rd_exo.o wr_exo.o rd_in.o wr_graph_file.o mk_dm.o \ + wr_coords.o ppi.o sam_perea.o wr_dpi.o \ + utils.o aalloc.o eh.o exo_utils.o exo_conn.o emuck.o \ + rd_dpi.o + +all: brk fix + +tags: + find . -name "*.[c]" -exec etags -a '{}' \; + +fix: $(FOBJS) + $(RM) $@;\ + $(CC) $(COPTIMIZEFLAGS) -o $@ $(FOBJS) $(LIBS) $(Trilinos_EXTRA_LD_FLAGS) + +brk: $(OBJS) + $(RM) $@;\ + $(PURE) $(CC) $(COPTIMIZEFLAGS) -o $@ $(OBJS) $(LIBS) $(Trilinos_EXTRA_LD_FLAGS) + +clean: + -rm -f *.o *~ tmp* core junk* *.BAK *% + +realclean: + -rm -f *.fem *.pcon *.psplot *.o *~ tmp* junk* *.BAK *%