diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/Makefile OpenFOAM-1.3/wmake/Makefile --- OpenFOAM-1.3.CaseInsensitive/wmake/Makefile 2005-06-21 09:10:23.000000000 -0700 +++ OpenFOAM-1.3/wmake/Makefile 2006-02-08 00:30:10.000000000 -0800 @@ -87,13 +87,13 @@ LIB = libNULL # Shared library extension -SO = so +SO = dll # Project executable -EXE = $(WM_PROJECT).out +EXE = $(WM_PROJECT).exe -# Standalone executable -SEXE = a.out +# Standalone executable extension +SEXE = a.exe #------------------------------------------------------------------------------ @@ -108,6 +108,7 @@ include $(RULES)/$(WM_LINK_LANGUAGE) MAKE_DEP = @$(MKDEP) $< | $(WM_SCRIPTS)/addCompile $< +MAKE_IDEP = @$(MKDEP) --import $< | $(WM_SCRIPTS)/addCompile $< --import #------------------------------------------------------------------------------ @@ -120,8 +121,11 @@ include $(OBJECTS_DIR)/filesMacros include $(OBJECTS_DIR)/sourceFiles include $(OBJECTS_DIR)/objectFiles +include $(OBJECTS_DIR)/importObjectFiles include $(OBJECTS_DIR)/localObjectFiles +include $(OBJECTS_DIR)/importLocalObjectFiles include $(OBJECTS_DIR)/dependencyFiles +include $(OBJECTS_DIR)/importDependencyFiles #------------------------------------------------------------------------------ # set header file include paths @@ -135,6 +139,7 @@ $(PROJECT_INC) \ $(SYS_INC) +.PHONY: dropImportDependencyFiles #------------------------------------------------------------------------------ # define link statements for executables @@ -142,7 +147,7 @@ $(EXE): $(OBJECTS) $(WM_SCRIPTS)/mkObjectDir $(EXE) - $(LINKEXE) $(OBJECTS) -L$(LIB_WM_OPTIONS_DIR) \ + $(LINKEXE) $(OBJECTS) -L$(FOAM_LIBBIN) \ $(EXE_LIBS) -l$(WM_PROJECT) $(SYS_LIBS) $(LINK_LIBS) $(GLIBS) -o $(EXE) exe: $(SEXE) @@ -151,7 +156,7 @@ $(SEXE): $(OBJECTS) $(WM_SCRIPTS)/mkObjectDir $(SEXE) $(LINKEXE) $(OBJECTS) $(EXE_LIBS) \ - $(SYS_LIBS) $(LINK_LIBS) $(GLIBS) -o $(SEXE) + $(SYS_LIBS) $(LINK_LIBS) $(GLIBS) -o $(SEXE) #------------------------------------------------------------------------------ @@ -161,11 +166,13 @@ libso: $(LIB).$(SO) @echo \`$(LIB).$(SO)\' is up to date. -$(LIB).$(SO): $(OBJECTS) +$(LIB).$(SO): $(OBJECTS) $(IMPORT_OBJECTS) $(WM_SCRIPTS)/mkObjectDir $(LIB) rm -f so_locations - cd $(OBJECTS_DIR) ; \ - $(LINKLIBSO) $(LOCAL_OBJECTS) -L$(LIB_WM_OPTIONS_DIR) $(LIB_LIBS) $(GLIB_LIBS) -o $(LIB).$(SO) + cd $(OBJECTS_DIR); \ + $(LINKLIBSO)$(LIB).a -Wl,--whole-archive $(LOCAL_OBJECTS) \ + $(IMPORT_LOCAL_OBJECTS) -Wl,--no-whole-archive -L$(FOAM_LIBBIN) \ + $(LIB_LIBS) -o $(LIB).$(SO) lib: $(LIB).a @echo \`$(LIB).a\' is up to date. @@ -203,10 +210,15 @@ # Set depedency rule and include dependency lists #------------------------------------------------------------------------------ -$(OBJECTS_DIR)/dependencies: $(DEPENDENCIES) - @echo dependencies up to data > $(OBJECTS_DIR)/dependencies +$(OBJECTS_DIR)/dependencies: $(DEPENDENCIES) dropImportDependencyFiles $(IMPORT_DEPENDENCIES) + @echo dependencies up to date > $(OBJECTS_DIR)/dependencies + +dropImportDependencyFiles: + @echo Dropping import dependency files + @rm -f $(IMPORT_DEPENDENCIES) include $(INCLUDE_DEPS) +include $(INCLUDE_IMPORT_DEPS) #------------------------------------------------------------------------------ diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/MakefileFiles OpenFOAM-1.3/wmake/MakefileFiles --- OpenFOAM-1.3.CaseInsensitive/wmake/MakefileFiles 2005-06-21 09:10:23.000000000 -0700 +++ OpenFOAM-1.3/wmake/MakefileFiles 2006-02-08 00:30:10.000000000 -0800 @@ -42,8 +42,8 @@ OPTIONS = $(WM_OPTIONS)/options SFILES = $(WM_OPTIONS)/sourceFiles -OFILES = $(WM_OPTIONS)/objectFiles -DFILES = $(WM_OPTIONS)/dependencyFiles +OFILES = $(WM_OPTIONS)/objectFiles $(WM_OPTIONS)/importObjectFiles +DFILES = $(WM_OPTIONS)/dependencyFiles $(WM_OPTIONS)/importDependencyFiles IFILES = $(WM_OPTIONS)/includeDeps #------------------------------------------------------------------------------ @@ -54,22 +54,22 @@ allFiles : $(FILES) $(OPTIONS) $(SFILES) $(OFILES) $(DFILES) $(IFILES) $(FILES) : files - @wmkdir $(WM_OPTIONS) ; $(CPP) $(GFLAGS) files > $(FILES) + @$(WM_DIR)/wmkdir $(WM_OPTIONS) ; $(CPP) $(GFLAGS) files > $(FILES) $(OPTIONS) : options @$(CPP) $(GFLAGS) options > $(OPTIONS) $(SFILES): files - @wmakeDerivedFiles + @$(WM_DIR)/wmakeDerivedFiles $(OFILES): files - @wmakeDerivedFiles + @$(WM_DIR)/wmakeDerivedFiles $(DFILES): files - @wmakeDerivedFiles + @$(WM_DIR)/wmakeDerivedFiles $(IFILES): files - @wmakeDerivedFiles + @$(WM_DIR)/wmakeDerivedFiles #------------------------------------------------------------------------------ diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/bashScripts/addCompile OpenFOAM-1.3/wmake/bashScripts/addCompile --- OpenFOAM-1.3.CaseInsensitive/wmake/bashScripts/addCompile 2006-03-29 00:16:12.000000000 -0800 +++ OpenFOAM-1.3/wmake/bashScripts/addCompile 2006-04-10 14:48:59.000000000 -0700 @@ -31,15 +31,24 @@ # It has to be written in the C-shell rather than the Bourne shell # because it uses file name manipulators. # -# Usage: wmkdep | addCompile +# The compilation target name can be modified using a switch --import +# to _import.o. +# +# Usage: wmkdep | addCompile [--import] # #------------------------------------------------------------------------------ sourceName=${1##*/} -objectName=${sourceName%.*}.o className=${sourceName%.*}.class sub=${1##*.} -depName=${1%.*}.dep +if [ ${2:-""} = "--import" ]; +then + objectName=${sourceName%.*}_import.o + depName=${1%.*}.idep +else + objectName=${sourceName%.*}.o + depName=${1%.*}.dep +fi sourceDir=${1%/*} diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/cshScripts/addCompile OpenFOAM-1.3/wmake/cshScripts/addCompile --- OpenFOAM-1.3.CaseInsensitive/wmake/cshScripts/addCompile 2005-06-21 09:10:23.000000000 -0700 +++ OpenFOAM-1.3/wmake/cshScripts/addCompile 2006-04-04 14:56:38.000000000 -0700 @@ -31,16 +31,24 @@ # It has to be written in the C-shell rather than the Bourne shell # because it uses file name manipulators. # -# Usage: wmkdep | addCompile +# The compilation target name can be modified using a switch --import +# to _import.o. +# +# Usage: wmkdep | addCompile [--import] # #------------------------------------------------------------------------------ set sourceName=$1:t -set objectName=$sourceName:r.o set className=$sourceName:r.class set sub=$1:e -set depName=$1:r.dep set sourceDir=$1:h +if ($2 == "--import") then + set objectName=$sourceName:r_import.o + set depName=$1:r.idep +else + set objectName=$sourceName:r.o + set depName=$1:r.dep +endif if ($sourceDir == $sourceName) then set sourceDir="." diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/kshScripts/addCompile OpenFOAM-1.3/wmake/kshScripts/addCompile --- OpenFOAM-1.3.CaseInsensitive/wmake/kshScripts/addCompile 2005-06-21 09:10:23.000000000 -0700 +++ OpenFOAM-1.3/wmake/kshScripts/addCompile 2006-04-04 14:56:38.000000000 -0700 @@ -31,15 +31,24 @@ # It has to be written in the C-shell rather than the Bourne shell # because it uses file name manipulators. # -# Usage: wmkdep | addCompile +# The compilation target name can be modified using a switch --import +# to _import.o. +# +# Usage: wmkdep | addCompile [--import] # #------------------------------------------------------------------------------ sourceName=${1##*/} -objectName=${sourceName%.*}.o className=${sourceName%.*}.class sub=${1##*.} -depName=${1%.*}.dep +if [ ${2:-""} = "--import" ]; +then + objectName=${sourceName%.*}_import.o + depName=${1%.*}.idep +else + objectName=${sourceName%.*}.o + depName=${1%.*}.dep +fi sourceDir=${1%/*} diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/makeWmake OpenFOAM-1.3/wmake/makeWmake --- OpenFOAM-1.3.CaseInsensitive/wmake/makeWmake 2005-06-21 09:10:23.000000000 -0700 +++ OpenFOAM-1.3/wmake/makeWmake 2006-04-10 14:50:31.000000000 -0700 @@ -59,4 +59,14 @@ cd .. +if [ $WM_ARCH = "cygwin" ]; then + makefileRules="cygwin" +else + makefileRules="General" +fi +rm -f Makefile MakefileFiles +ln -s $WM_DIR/rules/$makefileRules/Makefile Makefile +ln -s $WM_DIR/rules/$makefileRules/MakefileFiles MakefileFiles + + #------------------------------------------------------------------------------ diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/General/Makefile OpenFOAM-1.3/wmake/rules/General/Makefile --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/General/Makefile 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/General/Makefile 2006-04-01 22:50:37.000000000 -0800 @@ -0,0 +1,212 @@ +#------------------------------------------------------------------------------ +# ========= | +# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox +# \\ / O peration | +# \\ / A nd | Copyright (C) 1991-2005 OpenCFD Ltd. +# \\/ M anipulation | +#------------------------------------------------------------------------------- +# License +# This file is part of OpenFOAM. +# +# OpenFOAM 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. +# +# OpenFOAM 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 OpenFOAM; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +# +# Script +# Makefile +# +# Description +# Generic Makefile used by wmake +# +#------------------------------------------------------------------------------ +# Set shell the Makefile uses to the Bourne shell +#------------------------------------------------------------------------------ + +SHELL = /bin/sh + + +#------------------------------------------------------------------------------ +# Initialise suffices list +#------------------------------------------------------------------------------ + +.SUFFIXES: +.SUFFIXES: .o + + +#------------------------------------------------------------------------------ +# Set the directory containing the wmake scripts +#------------------------------------------------------------------------------ + +WM_SCRIPTS = $(WM_DIR)/$(WM_SHELL)Scripts + + +#------------------------------------------------------------------------------ +# declare default paths +#------------------------------------------------------------------------------ + +LIB_SRC = $(WM_PROJECT_DIR)/src +LIB_DIR = $(WM_PROJECT_DIR)/lib +LIB_WM_OPTIONS_DIR = $(LIB_DIR)/$(WM_OPTIONS) +OBJECTS_DIR = $(MAKE_DIR)/$(WM_OPTIONS) +CLASSES_DIR = $(MAKE_DIR)/classes + +SYS_INC = +SYS_LIBS = + +PROJECT_INC = +PROJECT_LIBS = + +EXE_INC = +EXE_LIBS = + +LIB_LIBS = + + +#------------------------------------------------------------------------------ +# declare all .o files depend on $(OBJECTS_DIR)/options +#------------------------------------------------------------------------------ + +EXE_DEP = $(OBJECTS_DIR)/options + + +#------------------------------------------------------------------------------ +# declare default name of libraries and executables +#------------------------------------------------------------------------------ + +# Library +LIB = libNULL + +# Shared library extension +SO = so + +# Project executable +EXE = $(WM_PROJECT).out + +# Standalone executable +SEXE = a.out + + +#------------------------------------------------------------------------------ +# set compilation and dependency building rules +#------------------------------------------------------------------------------ + +GENERAL_RULES = $(WM_DIR)/rules/General +RULES = $(WM_DIR)/rules/$(WM_ARCH)$(WM_COMPILER) + +include $(GENERAL_RULES)/general +include $(RULES)/general +include $(RULES)/$(WM_LINK_LANGUAGE) + +MAKE_DEP = @$(MKDEP) $< | $(WM_SCRIPTS)/addCompile $< + + +#------------------------------------------------------------------------------ +# Include PROJECT directory tree file and +# source, object and dependency list files. +# These are constructed by wmakeDerivedFiles +#------------------------------------------------------------------------------ + +include $(OBJECTS_DIR)/options +include $(OBJECTS_DIR)/filesMacros +include $(OBJECTS_DIR)/sourceFiles +include $(OBJECTS_DIR)/objectFiles +include $(OBJECTS_DIR)/localObjectFiles +include $(OBJECTS_DIR)/dependencyFiles + +#------------------------------------------------------------------------------ +# set header file include paths +#------------------------------------------------------------------------------ + +LIB_HEADER_DIRS = $(EXE_INC) \ + -I$(LIB_SRC)/$(WM_PROJECT)/lnInclude \ + -IlnInclude \ + -I. \ + $(GINC) \ + $(PROJECT_INC) \ + $(SYS_INC) + + +#------------------------------------------------------------------------------ +# define link statements for executables +#------------------------------------------------------------------------------ + +$(EXE): $(OBJECTS) + $(WM_SCRIPTS)/mkObjectDir $(EXE) + $(LINKEXE) $(OBJECTS) -L$(LIB_WM_OPTIONS_DIR) \ + $(EXE_LIBS) -l$(WM_PROJECT) $(SYS_LIBS) $(LINK_LIBS) $(GLIBS) -o $(EXE) + +exe: $(SEXE) + @echo \`$(SEXE)\' is up to date. + +$(SEXE): $(OBJECTS) + $(WM_SCRIPTS)/mkObjectDir $(SEXE) + $(LINKEXE) $(OBJECTS) $(EXE_LIBS) \ + $(SYS_LIBS) $(LINK_LIBS) $(GLIBS) -o $(SEXE) + + +#------------------------------------------------------------------------------ +# define link statements for libraries +#------------------------------------------------------------------------------ + +libso: $(LIB).$(SO) + @echo \`$(LIB).$(SO)\' is up to date. + +$(LIB).$(SO): $(OBJECTS) + $(WM_SCRIPTS)/mkObjectDir $(LIB) + rm -f so_locations + cd $(OBJECTS_DIR) ; \ + $(LINKLIBSO) $(LOCAL_OBJECTS) -L$(LIB_WM_OPTIONS_DIR) $(LIB_LIBS) $(GLIB_LIBS) -o $(LIB).$(SO) + +lib: $(LIB).a + @echo \`$(LIB).a\' is up to date. + +$(LIB).a: $(OBJECTS) + $(WM_SCRIPTS)/mkObjectDir $(LIB) + rm -f $(LIB).a + $(AR) $(ARFLAGS) $(LIB).a $(OBJECTS) + $(RANLIB) $(LIB).a + +libo: $(LIB).o + @echo \`$(LIB).o\' is up to date. + +$(LIB).o: $(OBJECTS) + $(WM_SCRIPTS)/mkObjectDir $(LIB) + rm -f $(LIB).o + $(LD) -r -o $(LIB).o $(OBJECTS) + +jar: $(LIB).jar + @echo \`$(LIB).jar\' is up to date. + +$(LIB).jar: $(OBJECTS) + $(WM_SCRIPTS)/mkObjectDir $(LIB) + jar cfm $(LIB).jar $(LIB_LIBS) -C $(CLASSES_DIR) . + +#------------------------------------------------------------------------------ +# Set rule to create the include directory for libraries +#------------------------------------------------------------------------------ + +lnInclude/uptodate: $(MAKE_DIR)/files $(MAKE_DIR)/options + @rm -rf lnInclude ; wmakeLnInclude `pwd` ; touch lnInclude/uptodate + + +#------------------------------------------------------------------------------ +# Set depedency rule and include dependency lists +#------------------------------------------------------------------------------ + +$(OBJECTS_DIR)/dependencies: $(DEPENDENCIES) + @echo dependencies up to date > $(OBJECTS_DIR)/dependencies + +include $(INCLUDE_DEPS) + + +#------------------------------------------------------------------------------ diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/General/MakefileFiles OpenFOAM-1.3/wmake/rules/General/MakefileFiles --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/General/MakefileFiles 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/General/MakefileFiles 2005-06-21 09:10:23.000000000 -0700 @@ -0,0 +1,75 @@ +#------------------------------------------------------------------------------ +# ========= | +# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox +# \\ / O peration | +# \\ / A nd | Copyright (C) 1991-2005 OpenCFD Ltd. +# \\/ M anipulation | +#------------------------------------------------------------------------------- +# License +# This file is part of OpenFOAM. +# +# OpenFOAM 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. +# +# OpenFOAM 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 OpenFOAM; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +# +# Script +# MakefileFiles +# +# Description +# General, easy to use make system for multi-platform development. +# +#------------------------------------------------------------------------------ + +GENERAL_RULES = $(WM_DIR)/rules/General +RULES = $(WM_DIR)/rules/$(WM_ARCH)$(WM_COMPILER) +include $(RULES)/general + +#------------------------------------------------------------------------------ +# declare names of make system control files derived from file files +#------------------------------------------------------------------------------ + +FILES = $(WM_OPTIONS)/files +OPTIONS = $(WM_OPTIONS)/options + +SFILES = $(WM_OPTIONS)/sourceFiles +OFILES = $(WM_OPTIONS)/objectFiles +DFILES = $(WM_OPTIONS)/dependencyFiles +IFILES = $(WM_OPTIONS)/includeDeps + +#------------------------------------------------------------------------------ +# Declare dependecy of all make system files on FILE +# Causes all derived files to be remade if any are changed or missing +#------------------------------------------------------------------------------ + +allFiles : $(FILES) $(OPTIONS) $(SFILES) $(OFILES) $(DFILES) $(IFILES) + +$(FILES) : files + @wmkdir $(WM_OPTIONS) ; $(CPP) $(GFLAGS) files > $(FILES) + +$(OPTIONS) : options + @$(CPP) $(GFLAGS) options > $(OPTIONS) + +$(SFILES): files + @wmakeDerivedFiles + +$(OFILES): files + @wmakeDerivedFiles + +$(DFILES): files + @wmakeDerivedFiles + +$(IFILES): files + @wmakeDerivedFiles + + +#------------------------------------------------------------------------------ diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/General/sourceToDep OpenFOAM-1.3/wmake/rules/General/sourceToDep --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/General/sourceToDep 2004-11-22 09:30:37.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/General/sourceToDep 2006-04-04 14:56:38.000000000 -0700 @@ -1,4 +1,4 @@ -.SUFFIXES: .c .cc .cxx .cpp .C .java .F .f .dep +.SUFFIXES: .c .cc .cxx .cpp .C .java .F .f .dep .idep MKDEP = $(RULES)/wmkdep -I$(*D) $(LIB_HEADER_DIRS) @@ -17,6 +17,18 @@ .C.dep: $(MAKE_DEP) +.cc.idep: + $(MAKE_IDEP) + +.cxx.idep: + $(MAKE_IDEP) + +.cpp.idep: + $(MAKE_IDEP) + +.C.idep: + $(MAKE_IDEP) + .java.dep: $(MAKE_DEP) diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/Makefile OpenFOAM-1.3/wmake/rules/cygwin/Makefile --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/Makefile 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/Makefile 2006-02-08 00:30:10.000000000 -0800 @@ -0,0 +1,224 @@ +#------------------------------------------------------------------------------ +# ========= | +# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox +# \\ / O peration | +# \\ / A nd | Copyright (C) 1991-2005 OpenCFD Ltd. +# \\/ M anipulation | +#------------------------------------------------------------------------------- +# License +# This file is part of OpenFOAM. +# +# OpenFOAM 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. +# +# OpenFOAM 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 OpenFOAM; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +# +# Script +# Makefile +# +# Description +# Generic Makefile used by wmake +# +#------------------------------------------------------------------------------ +# Set shell the Makefile uses to the Bourne shell +#------------------------------------------------------------------------------ + +SHELL = /bin/sh + + +#------------------------------------------------------------------------------ +# Initialise suffices list +#------------------------------------------------------------------------------ + +.SUFFIXES: +.SUFFIXES: .o + + +#------------------------------------------------------------------------------ +# Set the directory containing the wmake scripts +#------------------------------------------------------------------------------ + +WM_SCRIPTS = $(WM_DIR)/$(WM_SHELL)Scripts + + +#------------------------------------------------------------------------------ +# declare default paths +#------------------------------------------------------------------------------ + +LIB_SRC = $(WM_PROJECT_DIR)/src +LIB_DIR = $(WM_PROJECT_DIR)/lib +LIB_WM_OPTIONS_DIR = $(LIB_DIR)/$(WM_OPTIONS) +OBJECTS_DIR = $(MAKE_DIR)/$(WM_OPTIONS) +CLASSES_DIR = $(MAKE_DIR)/classes + +SYS_INC = +SYS_LIBS = + +PROJECT_INC = +PROJECT_LIBS = + +EXE_INC = +EXE_LIBS = + +LIB_LIBS = + + +#------------------------------------------------------------------------------ +# declare all .o files depend on $(OBJECTS_DIR)/options +#------------------------------------------------------------------------------ + +EXE_DEP = $(OBJECTS_DIR)/options + + +#------------------------------------------------------------------------------ +# declare default name of libraries and executables +#------------------------------------------------------------------------------ + +# Library +LIB = libNULL + +# Shared library extension +SO = dll + +# Project executable +EXE = $(WM_PROJECT).exe + +# Standalone executable extension +SEXE = a.exe + + +#------------------------------------------------------------------------------ +# set compilation and dependency building rules +#------------------------------------------------------------------------------ + +GENERAL_RULES = $(WM_DIR)/rules/General +RULES = $(WM_DIR)/rules/$(WM_ARCH)$(WM_COMPILER) + +include $(GENERAL_RULES)/general +include $(RULES)/general +include $(RULES)/$(WM_LINK_LANGUAGE) + +MAKE_DEP = @$(MKDEP) $< | $(WM_SCRIPTS)/addCompile $< +MAKE_IDEP = @$(MKDEP) --import $< | $(WM_SCRIPTS)/addCompile $< --import + + +#------------------------------------------------------------------------------ +# Include PROJECT directory tree file and +# source, object and dependency list files. +# These are constructed by wmakeDerivedFiles +#------------------------------------------------------------------------------ + +include $(OBJECTS_DIR)/options +include $(OBJECTS_DIR)/filesMacros +include $(OBJECTS_DIR)/sourceFiles +include $(OBJECTS_DIR)/objectFiles +include $(OBJECTS_DIR)/importObjectFiles +include $(OBJECTS_DIR)/localObjectFiles +include $(OBJECTS_DIR)/importLocalObjectFiles +include $(OBJECTS_DIR)/dependencyFiles +include $(OBJECTS_DIR)/importDependencyFiles + +#------------------------------------------------------------------------------ +# set header file include paths +#------------------------------------------------------------------------------ + +LIB_HEADER_DIRS = $(EXE_INC) \ + -I$(LIB_SRC)/$(WM_PROJECT)/lnInclude \ + -IlnInclude \ + -I. \ + $(GINC) \ + $(PROJECT_INC) \ + $(SYS_INC) + +.PHONY: dropImportDependencyFiles + +#------------------------------------------------------------------------------ +# define link statements for executables +#------------------------------------------------------------------------------ + +$(EXE): $(OBJECTS) + $(WM_SCRIPTS)/mkObjectDir $(EXE) + $(LINKEXE) $(OBJECTS) -L$(FOAM_LIBBIN) \ + $(EXE_LIBS) -l$(WM_PROJECT) $(SYS_LIBS) $(LINK_LIBS) $(GLIBS) -o $(EXE) + +exe: $(SEXE) + @echo \`$(SEXE)\' is up to date. + +$(SEXE): $(OBJECTS) + $(WM_SCRIPTS)/mkObjectDir $(SEXE) + $(LINKEXE) $(OBJECTS) $(EXE_LIBS) \ + $(SYS_LIBS) $(LINK_LIBS) $(GLIBS) -o $(SEXE) + + +#------------------------------------------------------------------------------ +# define link statements for libraries +#------------------------------------------------------------------------------ + +libso: $(LIB).$(SO) + @echo \`$(LIB).$(SO)\' is up to date. + +$(LIB).$(SO): $(OBJECTS) $(IMPORT_OBJECTS) + $(WM_SCRIPTS)/mkObjectDir $(LIB) + rm -f so_locations + cd $(OBJECTS_DIR); \ + $(LINKLIBSO)$(LIB).a -Wl,--whole-archive $(LOCAL_OBJECTS) \ + $(IMPORT_LOCAL_OBJECTS) -Wl,--no-whole-archive -L$(FOAM_LIBBIN) \ + $(LIB_LIBS) -o $(LIB).$(SO) + +lib: $(LIB).a + @echo \`$(LIB).a\' is up to date. + +$(LIB).a: $(OBJECTS) + $(WM_SCRIPTS)/mkObjectDir $(LIB) + rm -f $(LIB).a + $(AR) $(ARFLAGS) $(LIB).a $(OBJECTS) + $(RANLIB) $(LIB).a + +libo: $(LIB).o + @echo \`$(LIB).o\' is up to date. + +$(LIB).o: $(OBJECTS) + $(WM_SCRIPTS)/mkObjectDir $(LIB) + rm -f $(LIB).o + $(LD) -r -o $(LIB).o $(OBJECTS) + +jar: $(LIB).jar + @echo \`$(LIB).jar\' is up to date. + +$(LIB).jar: $(OBJECTS) + $(WM_SCRIPTS)/mkObjectDir $(LIB) + jar cfm $(LIB).jar $(LIB_LIBS) -C $(CLASSES_DIR) . + +#------------------------------------------------------------------------------ +# Set rule to create the include directory for libraries +#------------------------------------------------------------------------------ + +lnInclude/uptodate: $(MAKE_DIR)/files $(MAKE_DIR)/options + @rm -rf lnInclude ; wmakeLnInclude `pwd` ; touch lnInclude/uptodate + + +#------------------------------------------------------------------------------ +# Set depedency rule and include dependency lists +#------------------------------------------------------------------------------ + +$(OBJECTS_DIR)/dependencies: $(DEPENDENCIES) dropImportDependencyFiles $(IMPORT_DEPENDENCIES) + @echo dependencies up to date > $(OBJECTS_DIR)/dependencies + +dropImportDependencyFiles: + @echo Dropping import dependency files + @rm -f $(IMPORT_DEPENDENCIES) + +include $(INCLUDE_DEPS) +include $(INCLUDE_IMPORT_DEPS) + + +#------------------------------------------------------------------------------ diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/MakefileFiles OpenFOAM-1.3/wmake/rules/cygwin/MakefileFiles --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/MakefileFiles 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/MakefileFiles 2006-02-08 00:30:10.000000000 -0800 @@ -0,0 +1,75 @@ +#------------------------------------------------------------------------------ +# ========= | +# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox +# \\ / O peration | +# \\ / A nd | Copyright (C) 1991-2005 OpenCFD Ltd. +# \\/ M anipulation | +#------------------------------------------------------------------------------- +# License +# This file is part of OpenFOAM. +# +# OpenFOAM 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. +# +# OpenFOAM 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 OpenFOAM; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +# +# Script +# MakefileFiles +# +# Description +# General, easy to use make system for multi-platform development. +# +#------------------------------------------------------------------------------ + +GENERAL_RULES = $(WM_DIR)/rules/General +RULES = $(WM_DIR)/rules/$(WM_ARCH)$(WM_COMPILER) +include $(RULES)/general + +#------------------------------------------------------------------------------ +# declare names of make system control files derived from file files +#------------------------------------------------------------------------------ + +FILES = $(WM_OPTIONS)/files +OPTIONS = $(WM_OPTIONS)/options + +SFILES = $(WM_OPTIONS)/sourceFiles +OFILES = $(WM_OPTIONS)/objectFiles $(WM_OPTIONS)/importObjectFiles +DFILES = $(WM_OPTIONS)/dependencyFiles $(WM_OPTIONS)/importDependencyFiles +IFILES = $(WM_OPTIONS)/includeDeps + +#------------------------------------------------------------------------------ +# Declare dependecy of all make system files on FILE +# Causes all derived files to be remade if any are changed or missing +#------------------------------------------------------------------------------ + +allFiles : $(FILES) $(OPTIONS) $(SFILES) $(OFILES) $(DFILES) $(IFILES) + +$(FILES) : files + @$(WM_DIR)/wmkdir $(WM_OPTIONS) ; $(CPP) $(GFLAGS) files > $(FILES) + +$(OPTIONS) : options + @$(CPP) $(GFLAGS) options > $(OPTIONS) + +$(SFILES): files + @$(WM_DIR)/wmakeDerivedFiles + +$(OFILES): files + @$(WM_DIR)/wmakeDerivedFiles + +$(DFILES): files + @$(WM_DIR)/wmakeDerivedFiles + +$(IFILES): files + @$(WM_DIR)/wmakeDerivedFiles + + +#------------------------------------------------------------------------------ diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/X OpenFOAM-1.3/wmake/rules/cygwin/X --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/X 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/X 2006-02-08 00:30:10.000000000 -0800 @@ -0,0 +1,3 @@ +XFLAGS = +XINC = $(XFLAGS) -I/usr/X11R6/include +XLIBS = -L/usr/X11R6/lib -lXext -lX11 -lGL -lGLU diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/c OpenFOAM-1.3/wmake/rules/cygwin/c --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/c 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/c 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,16 @@ +.SUFFIXES: .c .h + +cWARN = -Wall + +cc = gcc -m32 + +include $(RULES)/c$(WM_COMPILE_OPTION) + +cFLAGS = $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) $(LIB_HEADER_DIRS) -fPIC + +ctoo = $(WM_CC_DRIVER) $(cc) $(cFLAGS) -c $$SOURCE -o $@ + +LINK_LIBS = $(cDBUG) + +LINKLIBSO = $(cc) -shared +LINKEXE = $(cc) -Xlinker -z -Xlinker nodefs diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/c++ OpenFOAM-1.3/wmake/rules/cygwin/c++ --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/c++ 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/c++ 2006-02-08 00:30:10.000000000 -0800 @@ -0,0 +1,21 @@ +.SUFFIXES: .C .cxx .cc .cpp + +c++WARN = -Wall -W -Wno-unused-parameter -Wold-style-cast + +CC = g++ -m32 + +include $(RULES)/c++$(WM_COMPILE_OPTION) + +ptFLAGS = -DNoRepository -ftemplate-depth-30 + +c++FLAGS = $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) $(LIB_HEADER_DIRS) + +Ctoo = $(WM_CC_DRIVER) $(CC) $(c++FLAGS) -c $$SOURCE -o $@ +cxxtoo = $(Ctoo) +cctoo = $(Ctoo) +cpptoo = $(Ctoo) + +LINK_LIBS = $(c++DBUG) + +LINKLIBSO = $(CC) $(c++FLAGS) -shared -Wl,--dll -Wl,-mi386pe -Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--no-undefined -Wl,--no-allow-shlib-undefined -Wl,--enable-runtime-pseudo-reloc -Wl,--out-implib, +LINKEXE = $(CC) $(c++FLAGS) diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/c++Debug OpenFOAM-1.3/wmake/rules/cygwin/c++Debug --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/c++Debug 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/c++Debug 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,2 @@ +c++DBUG = -ggdb3 -DFULLDEBUG +c++OPT = -O0 -fdefault-inline diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/c++Opt OpenFOAM-1.3/wmake/rules/cygwin/c++Opt --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/c++Opt 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/c++Opt 2006-03-08 13:29:35.000000000 -0800 @@ -0,0 +1,2 @@ +c++DBUG = +c++OPT = -O3 diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/c++Prof OpenFOAM-1.3/wmake/rules/cygwin/c++Prof --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/c++Prof 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/c++Prof 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,2 @@ +c++DBUG = -pg +c++OPT = -O2 diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/cDebug OpenFOAM-1.3/wmake/rules/cygwin/cDebug --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/cDebug 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/cDebug 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,2 @@ +cDBUG = -ggdb -DFULLDEBUG +cOPT = -O1 -finline-functions diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/cOpt OpenFOAM-1.3/wmake/rules/cygwin/cOpt --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/cOpt 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/cOpt 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,2 @@ +cDBUG = +cOPT = -O3 diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/cProf OpenFOAM-1.3/wmake/rules/cygwin/cProf --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/cProf 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/cProf 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,2 @@ +cDBUG = -pg +cOPT = -O2 diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/general OpenFOAM-1.3/wmake/rules/cygwin/general --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/general 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/general 2006-04-02 01:18:49.000000000 -0800 @@ -0,0 +1,18 @@ +CPP = cpp -D$(WM_ARCH) +LD = ld -mi386pe + +GLIBS = -liberty + +include $(RULES)/X + +include $(GENERAL_RULES)/sourceToDep + +include $(GENERAL_RULES)/java +include $(GENERAL_RULES)/flex +include $(GENERAL_RULES)/flex++ +include $(GENERAL_RULES)/byacc +include $(GENERAL_RULES)/btyacc++ +include $(GENERAL_RULES)/moc + +include $(RULES)/c +include $(RULES)/c++ diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/mplib OpenFOAM-1.3/wmake/rules/cygwin/mplib --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/mplib 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/mplib 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,3 @@ +PFLAGS = +PINC = +PLIBS = diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/mplibLAM OpenFOAM-1.3/wmake/rules/cygwin/mplibLAM --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/mplibLAM 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/mplibLAM 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(LAM_ARCH_PATH)/include +PLIBS = -L$(LAM_ARCH_PATH)/lib -lmpi -llam -lpthread -lutil diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/mplibMPICH OpenFOAM-1.3/wmake/rules/cygwin/mplibMPICH --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/mplibMPICH 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/mplibMPICH 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPICH_ARCH_PATH)/include +PLIBS = -L$(MPICH_ARCH_PATH)/lib -lmpich diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/mplibOPENMPI OpenFOAM-1.3/wmake/rules/cygwin/mplibOPENMPI --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwin/mplibOPENMPI 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwin/mplibOPENMPI 2006-02-16 12:38:11.000000000 -0800 @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(OPENMPI_ARCH_PATH)/include +PLIBS = -L$(OPENMPI_ARCH_PATH)/lib -lmpi diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/X OpenFOAM-1.3/wmake/rules/cygwinGcc4/X --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/X 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/X 2006-02-08 00:30:10.000000000 -0800 @@ -0,0 +1,3 @@ +XFLAGS = +XINC = $(XFLAGS) -I/usr/X11R6/include +XLIBS = -L/usr/X11R6/lib -lXext -lX11 -lGL -lGLU diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/c OpenFOAM-1.3/wmake/rules/cygwinGcc4/c --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/c 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/c 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,16 @@ +.SUFFIXES: .c .h + +cWARN = -Wall + +cc = gcc -m32 + +include $(RULES)/c$(WM_COMPILE_OPTION) + +cFLAGS = $(GFLAGS) $(cWARN) $(cOPT) $(cDBUG) $(LIB_HEADER_DIRS) -fPIC + +ctoo = $(WM_CC_DRIVER) $(cc) $(cFLAGS) -c $$SOURCE -o $@ + +LINK_LIBS = $(cDBUG) + +LINKLIBSO = $(cc) -shared +LINKEXE = $(cc) -Xlinker -z -Xlinker nodefs diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/c++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/c++ --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/c++ 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/c++ 2006-02-08 00:30:10.000000000 -0800 @@ -0,0 +1,21 @@ +.SUFFIXES: .C .cxx .cc .cpp + +c++WARN = -Wall -W -Wno-unused-parameter -Wold-style-cast + +CC = g++ -m32 + +include $(RULES)/c++$(WM_COMPILE_OPTION) + +ptFLAGS = -DNoRepository -ftemplate-depth-30 + +c++FLAGS = $(GFLAGS) $(c++WARN) $(c++OPT) $(c++DBUG) $(ptFLAGS) $(LIB_HEADER_DIRS) + +Ctoo = $(WM_CC_DRIVER) $(CC) $(c++FLAGS) -c $$SOURCE -o $@ +cxxtoo = $(Ctoo) +cctoo = $(Ctoo) +cpptoo = $(Ctoo) + +LINK_LIBS = $(c++DBUG) + +LINKLIBSO = $(CC) $(c++FLAGS) -shared -Wl,--dll -Wl,-mi386pe -Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--no-undefined -Wl,--no-allow-shlib-undefined -Wl,--enable-runtime-pseudo-reloc -Wl,--out-implib, +LINKEXE = $(CC) $(c++FLAGS) diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/c++Debug OpenFOAM-1.3/wmake/rules/cygwinGcc4/c++Debug --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/c++Debug 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/c++Debug 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,2 @@ +c++DBUG = -ggdb3 -DFULLDEBUG +c++OPT = -O0 -fdefault-inline diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/c++Opt OpenFOAM-1.3/wmake/rules/cygwinGcc4/c++Opt --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/c++Opt 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/c++Opt 2006-03-08 13:29:35.000000000 -0800 @@ -0,0 +1,2 @@ +c++DBUG = +c++OPT = -O3 diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/c++Prof OpenFOAM-1.3/wmake/rules/cygwinGcc4/c++Prof --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/c++Prof 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/c++Prof 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,2 @@ +c++DBUG = -pg +c++OPT = -O2 diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/cDebug OpenFOAM-1.3/wmake/rules/cygwinGcc4/cDebug --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/cDebug 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/cDebug 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,2 @@ +cDBUG = -ggdb -DFULLDEBUG +cOPT = -O1 -finline-functions diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/cOpt OpenFOAM-1.3/wmake/rules/cygwinGcc4/cOpt --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/cOpt 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/cOpt 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,2 @@ +cDBUG = +cOPT = -O3 diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/cProf OpenFOAM-1.3/wmake/rules/cygwinGcc4/cProf --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/cProf 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/cProf 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,2 @@ +cDBUG = -pg +cOPT = -O2 diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/general OpenFOAM-1.3/wmake/rules/cygwinGcc4/general --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/general 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/general 2006-04-02 01:18:43.000000000 -0800 @@ -0,0 +1,18 @@ +CPP = cpp -D$(WM_ARCH) +LD = ld -mi386pe + +GLIBS = -liberty + +include $(RULES)/X + +include $(GENERAL_RULES)/sourceToDep + +include $(GENERAL_RULES)/java +include $(GENERAL_RULES)/flex +include $(GENERAL_RULES)/flex++ +include $(GENERAL_RULES)/byacc +include $(GENERAL_RULES)/btyacc++ +include $(GENERAL_RULES)/moc + +include $(RULES)/c +include $(RULES)/c++ diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/mplib OpenFOAM-1.3/wmake/rules/cygwinGcc4/mplib --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/mplib 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/mplib 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,3 @@ +PFLAGS = +PINC = +PLIBS = diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/mplibLAM OpenFOAM-1.3/wmake/rules/cygwinGcc4/mplibLAM --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/mplibLAM 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/mplibLAM 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(LAM_ARCH_PATH)/include +PLIBS = -L$(LAM_ARCH_PATH)/lib -lmpi -llam -lpthread -lutil diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/mplibMPICH OpenFOAM-1.3/wmake/rules/cygwinGcc4/mplibMPICH --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/mplibMPICH 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/mplibMPICH 2004-11-22 09:30:37.000000000 -0800 @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(MPICH_ARCH_PATH)/include +PLIBS = -L$(MPICH_ARCH_PATH)/lib -lmpich diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/mplibOPENMPI OpenFOAM-1.3/wmake/rules/cygwinGcc4/mplibOPENMPI --- OpenFOAM-1.3.CaseInsensitive/wmake/rules/cygwinGcc4/mplibOPENMPI 1969-12-31 16:00:00.000000000 -0800 +++ OpenFOAM-1.3/wmake/rules/cygwinGcc4/mplibOPENMPI 2006-02-16 12:38:11.000000000 -0800 @@ -0,0 +1,3 @@ +PFLAGS = +PINC = -I$(OPENMPI_ARCH_PATH)/include +PLIBS = -L$(OPENMPI_ARCH_PATH)/lib -lmpi diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/src/lex.yy.c OpenFOAM-1.3/wmake/src/lex.yy.c --- OpenFOAM-1.3.CaseInsensitive/wmake/src/lex.yy.c 2006-02-15 00:39:17.000000000 -0800 +++ OpenFOAM-1.3/wmake/src/lex.yy.c 2006-04-04 14:56:38.000000000 -0700 @@ -9,7 +9,7 @@ #define YY_FLEX_MINOR_VERSION 5 #include - +#include /* cfront 1.2 defines "c_plusplus" instead of "__cplusplus" */ #ifdef c_plusplus @@ -22,7 +22,9 @@ #ifdef __cplusplus #include +#ifndef _WIN32 #include +#endif /* Use prototypes in function declarations. */ #define YY_USE_PROTOS @@ -62,6 +64,7 @@ #define YY_PROTO(proto) () #endif + /* Returned upon end-of-file. */ #define YY_NULL 0 @@ -674,9 +677,12 @@ The algorithm uses flex to scan for includes and searches the files found. Each file is entererd into a hash table so that files are scaned only once. This is why this program is faster than cpp. + + The compilation target in the dep-file will default to *_import.o if + a switch --import is used. Usage - wmkdep [ -Idirectory ... -Idirectory] filename + wmkdep [--import] [ -Idirectory ... -Idirectory] filename \*----------------------------------------------------------------------------*/ @@ -699,7 +705,7 @@ #define JFNAME 3 #define FFNAME 4 -#line 703 "lex.yy.c" +#line 709 "lex.yy.c" /* Macros after this point can all be overridden by user definitions in * section 1. @@ -799,9 +805,20 @@ YY_FATAL_ERROR( "input in flex scanner failed" ); \ result = n; \ } \ - else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \ - && ferror( yyin ) ) \ - YY_FATAL_ERROR( "input in flex scanner failed" ); + else \ + { \ + errno=0; \ + while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \ + { \ + if( errno != EINTR) \ + { \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + break; \ + } \ + errno=0; \ + clearerr(yyin); \ + } \ + } #endif /* No semi-colon after return; correct usage is to write "yyterminate();" - @@ -853,10 +870,10 @@ register char *yy_cp, *yy_bp; register int yy_act; -#line 60 "wmkdep.l" +#line 63 "wmkdep.l" -#line 860 "lex.yy.c" +#line 877 "lex.yy.c" if ( yy_init ) { @@ -942,100 +959,100 @@ case 1: YY_RULE_SETUP -#line 62 "wmkdep.l" +#line 65 "wmkdep.l" ; /* remove c++ style one line comments */ YY_BREAK case 2: YY_RULE_SETUP -#line 64 "wmkdep.l" +#line 67 "wmkdep.l" BEGIN(CMNT); /* start removing c style comment */ YY_BREAK case 3: YY_RULE_SETUP -#line 65 "wmkdep.l" +#line 68 "wmkdep.l" ; YY_BREAK case 4: YY_RULE_SETUP -#line 66 "wmkdep.l" +#line 69 "wmkdep.l" BEGIN(INITIAL); /* end removing c style comment */ YY_BREAK case 5: YY_RULE_SETUP -#line 68 "wmkdep.l" +#line 71 "wmkdep.l" BEGIN(CFNAME); /* c-file name */ YY_BREAK case 6: YY_RULE_SETUP -#line 69 "wmkdep.l" +#line 72 "wmkdep.l" { BEGIN(INITIAL); nextFile(yytext); } /*"*/ YY_BREAK case 7: YY_RULE_SETUP -#line 71 "wmkdep.l" +#line 74 "wmkdep.l" BEGIN(JFNAME); /* java-file name */ YY_BREAK case 8: YY_RULE_SETUP -#line 72 "wmkdep.l" +#line 75 "wmkdep.l" BEGIN(INITIAL); YY_BREAK case 9: YY_RULE_SETUP -#line 73 "wmkdep.l" +#line 76 "wmkdep.l" BEGIN(INITIAL); YY_BREAK case 10: YY_RULE_SETUP -#line 74 "wmkdep.l" +#line 77 "wmkdep.l" BEGIN(INITIAL); YY_BREAK case 11: YY_RULE_SETUP -#line 75 "wmkdep.l" +#line 78 "wmkdep.l" BEGIN(INITIAL); YY_BREAK case 12: YY_RULE_SETUP -#line 76 "wmkdep.l" +#line 79 "wmkdep.l" BEGIN(INITIAL); YY_BREAK case 13: YY_RULE_SETUP -#line 77 "wmkdep.l" +#line 80 "wmkdep.l" BEGIN(INITIAL); YY_BREAK case 14: YY_RULE_SETUP -#line 78 "wmkdep.l" +#line 81 "wmkdep.l" { BEGIN(INITIAL); importFile(yytext); } /*"*/ YY_BREAK case 15: YY_RULE_SETUP -#line 79 "wmkdep.l" +#line 82 "wmkdep.l" { BEGIN(INITIAL); importDirectory(yytext); } /*"*/ YY_BREAK case 16: YY_RULE_SETUP -#line 81 "wmkdep.l" +#line 84 "wmkdep.l" BEGIN(FFNAME); /* FORTRAN-file name */ YY_BREAK case 17: YY_RULE_SETUP -#line 82 "wmkdep.l" +#line 85 "wmkdep.l" { BEGIN(INITIAL); nextFile(yytext); } /*'*/ YY_BREAK case 18: YY_RULE_SETUP -#line 84 "wmkdep.l" +#line 87 "wmkdep.l" ; YY_BREAK case 19: YY_RULE_SETUP -#line 86 "wmkdep.l" +#line 89 "wmkdep.l" ECHO; YY_BREAK -#line 1039 "lex.yy.c" +#line 1056 "lex.yy.c" case YY_STATE_EOF(INITIAL): case YY_STATE_EOF(CMNT): case YY_STATE_EOF(CFNAME): @@ -1605,11 +1622,15 @@ } +#ifndef _WIN32 +#include +#else #ifndef YY_ALWAYS_INTERACTIVE #ifndef YY_NEVER_INTERACTIVE extern int isatty YY_PROTO(( int )); #endif #endif +#endif #ifdef YY_USE_PROTOS void yy_init_buffer( YY_BUFFER_STATE b, FILE *file ) @@ -1927,7 +1948,7 @@ return 0; } #endif -#line 86 "wmkdep.l" +#line 89 "wmkdep.l" @@ -1942,7 +1963,7 @@ int main(int argc, char* argv[]) { char *dotPtr, *slashPtr; - int i; + int i, importObject, memToAdd; if (argc == 1) { @@ -1969,17 +1990,20 @@ directories = (char**)malloc(sizeof(char*)*nDirectories); nDirectories = 0; - + importObject = 0; + for (i = 1; i < argc; i++) { if (strncmp(argv[i], "-I", 2) == 0) { directories[nDirectories++] = strdup(argv[i] + 2); } + else if (strncmp(argv[i], "--import", 8) == 0) + { + importObject = 1; + } } - - if ((dotPtr = strrchr(sourceFile, '.')) == NULL) { fprintf @@ -2012,10 +2036,11 @@ /* initialise depFile to zero and use strncat rather than strncpy because there is a bug in the SGI strncat that if 0 preceeds the . it inserts a space */ - depFile = (char*)malloc(strlen(sourceFile) + 3); + memToAdd = (importObject)? 4: 3; /* "dep" or "idep" suffix */ + depFile = (char*)malloc(strlen(sourceFile) + memToAdd); depFile[0] = 0; strncat(depFile, sourceFile, (dotPtr - sourceFile)/sizeof(char)); - strcat(depFile, ".dep"); + strcat(depFile, (importObject)? ".idep": ".dep"); if (strcmp(sourceExt, "java") == 0) { @@ -2028,10 +2053,12 @@ } else { - objectFile = (char*)malloc(strlen(sourceFile) + 16); + /* prefix and ".o" or "_import.o" suffix */ + memToAdd = (importObject)? 25: 18; + objectFile = (char*)malloc(strlen(sourceFile) + memToAdd); strcpy(objectFile, "$(OBJECTS_DIR)/"); strncat(objectFile, slashPtr, (dotPtr - slashPtr)/sizeof(char)); - strcat(objectFile, ".o"); + strcat(objectFile, (importObject)? "_import.o": ".o"); printf("%s: %s\n", objectFile, depFile); } diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/src/wmkdep.l OpenFOAM-1.3/wmake/src/wmkdep.l --- OpenFOAM-1.3.CaseInsensitive/wmake/src/wmkdep.l 2005-06-30 08:07:55.000000000 -0700 +++ OpenFOAM-1.3/wmake/src/wmkdep.l 2006-04-04 14:56:38.000000000 -0700 @@ -34,9 +34,12 @@ The algorithm uses flex to scan for includes and searches the files found. Each file is entererd into a hash table so that files are scaned only once. This is why this program is faster than cpp. + + The compilation target in the dep-file will default to *_import.o if + a switch --import is used. Usage - wmkdep [ -Idirectory ... -Idirectory] filename + wmkdep [--import] [ -Idirectory ... -Idirectory] filename \*----------------------------------------------------------------------------*/ @@ -97,7 +100,7 @@ int main(int argc, char* argv[]) { char *dotPtr, *slashPtr; - int i; + int i, importObject, memToAdd; if (argc == 1) { @@ -124,17 +127,20 @@ directories = (char**)malloc(sizeof(char*)*nDirectories); nDirectories = 0; - + importObject = 0; + for (i = 1; i < argc; i++) { if (strncmp(argv[i], "-I", 2) == 0) { directories[nDirectories++] = strdup(argv[i] + 2); } + else if (strncmp(argv[i], "--import", 8) == 0) + { + importObject = 1; + } } - - if ((dotPtr = strrchr(sourceFile, '.')) == NULL) { fprintf @@ -167,10 +173,11 @@ /* initialise depFile to zero and use strncat rather than strncpy because there is a bug in the SGI strncat that if 0 preceeds the . it inserts a space */ - depFile = (char*)malloc(strlen(sourceFile) + 3); + memToAdd = (importObject)? 4: 3; /* "dep" or "idep" suffix */ + depFile = (char*)malloc(strlen(sourceFile) + memToAdd); depFile[0] = 0; strncat(depFile, sourceFile, (dotPtr - sourceFile)/sizeof(char)); - strcat(depFile, ".dep"); + strcat(depFile, (importObject)? ".idep": ".dep"); if (strcmp(sourceExt, "java") == 0) { @@ -183,10 +190,12 @@ } else { - objectFile = (char*)malloc(strlen(sourceFile) + 16); + /* prefix and ".o" or "_import.o" suffix */ + memToAdd = (importObject)? 25: 18; + objectFile = (char*)malloc(strlen(sourceFile) + memToAdd); strcpy(objectFile, "$(OBJECTS_DIR)/"); strncat(objectFile, slashPtr, (dotPtr - slashPtr)/sizeof(char)); - strcat(objectFile, ".o"); + strcat(objectFile, (importObject)? "_import.o": ".o"); printf("%s: %s\n", objectFile, depFile); } diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/tcshScripts/addCompile OpenFOAM-1.3/wmake/tcshScripts/addCompile --- OpenFOAM-1.3.CaseInsensitive/wmake/tcshScripts/addCompile 2006-03-29 00:16:12.000000000 -0800 +++ OpenFOAM-1.3/wmake/tcshScripts/addCompile 2006-04-10 14:48:58.000000000 -0700 @@ -31,16 +31,24 @@ # It has to be written in the C-shell rather than the Bourne shell # because it uses file name manipulators. # -# Usage: wmkdep | addCompile +# The compilation target name can be modified using a switch --import +# to _import.o. +# +# Usage: wmkdep | addCompile [--import] # #------------------------------------------------------------------------------ set sourceName=$1:t -set objectName=$sourceName:r.o set className=$sourceName:r.class set sub=$1:e -set depName=$1:r.dep set sourceDir=$1:h +if ($2 == "--import") then + set objectName=$sourceName:r_import.o + set depName=$1:r.idep +else + set objectName=$sourceName:r.o + set depName=$1:r.dep +endif if ($sourceDir == $sourceName) then set sourceDir="." diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/wclean OpenFOAM-1.3/wmake/wclean --- OpenFOAM-1.3.CaseInsensitive/wmake/wclean 2005-06-21 09:10:24.000000000 -0700 +++ OpenFOAM-1.3/wmake/wclean 2006-04-04 14:56:38.000000000 -0700 @@ -96,6 +96,7 @@ rm -rf $MakeDir/$WM_OPTIONS $MakeDir/classes find . -name "*.dep" -exec rm {} \; +find . -name '*.idep' -exec rm {} \; if [ "$makeOption" = "lib" -o "$makeOption" = "libso" -o "$makeOption" = "libo" ] then diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/wcleanAll OpenFOAM-1.3/wmake/wcleanAll --- OpenFOAM-1.3.CaseInsensitive/wmake/wcleanAll 2005-08-08 07:50:18.000000000 -0700 +++ OpenFOAM-1.3/wmake/wcleanAll 2006-04-04 14:56:38.000000000 -0700 @@ -53,6 +53,7 @@ find . -name '*~' -exec rm {} \; find . -name '*.dep' -exec rm {} \; +find . -name '*.idep' -exec rm {} \; find `find . -depth \( -name "Make.[A-Za-z]*" -o -name "Make" \) -type d -print` -depth \( -type d ! -name "*Make.[A-Za-z]*" ! -name "*Make" \) -exec rm -rf {} \; diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/wcleanAlmostAll OpenFOAM-1.3/wmake/wcleanAlmostAll --- OpenFOAM-1.3.CaseInsensitive/wmake/wcleanAlmostAll 2005-08-08 07:51:02.000000000 -0700 +++ OpenFOAM-1.3/wmake/wcleanAlmostAll 2006-04-04 14:56:38.000000000 -0700 @@ -53,6 +53,7 @@ #find . -name '*~' -exec rm {} \; find . -name '*.dep' -exec rm {} \; +find . -name '*.idep' -exec rm {} \; find `find . -depth \( -name "Make[.A-Za-z]*" -o -name "Make" \) -type d -print` -depth \( -type d ! -name "*Make[.A-Za-z]*" ! -name "*Make" \) -exec rm -r {} \; diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/wmake OpenFOAM-1.3/wmake/wmake --- OpenFOAM-1.3.CaseInsensitive/wmake/wmake 2006-03-22 14:41:08.000000000 -0800 +++ OpenFOAM-1.3/wmake/wmake 2006-04-04 14:56:38.000000000 -0700 @@ -185,10 +185,10 @@ if [ "$makeOption" = "lib" -o "$makeOption" = "libso" -o "$makeOption" = "libo" ] then - $make -f $WM_DIR/Makefile MAKE_DIR=$MakeDir INCLUDE_DEPS=$OBJECTS_DIR/dontIncludeDeps lnInclude/uptodate + $make -f $WM_DIR/Makefile MAKE_DIR=$MakeDir INCLUDE_DEPS=$OBJECTS_DIR/dontIncludeDeps INCLUDE_IMPORT_DEPS=$OBJECTS_DIR/dontIncludeDeps lnInclude/uptodate fi -$make -f $WM_DIR/Makefile MAKE_DIR=$MakeDir INCLUDE_DEPS=$OBJECTS_DIR/dontIncludeDeps $OBJECTS_DIR/dependencies +$make -f $WM_DIR/Makefile MAKE_DIR=$MakeDir INCLUDE_DEPS=$OBJECTS_DIR/dontIncludeDeps INCLUDE_IMPORT_DEPS=$OBJECTS_DIR/dontIncludeDeps $OBJECTS_DIR/dependencies retVal=$? if [ $retVal -ne 0 ]; then @@ -202,7 +202,7 @@ #------------------------------------------------------------------------------ echo $makeOption -$make -f $WM_DIR/Makefile MAKE_DIR=$MakeDir INCLUDE_DEPS=$OBJECTS_DIR/includeDeps $makeOption +$make -f $WM_DIR/Makefile MAKE_DIR=$MakeDir INCLUDE_DEPS=$OBJECTS_DIR/includeDeps INCLUDE_IMPORT_DEPS=$OBJECTS_DIR/includeImportDeps $makeOption retVal=$? if [ $retVal -ne 0 ]; then diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/wmakeDerivedFiles OpenFOAM-1.3/wmake/wmakeDerivedFiles --- OpenFOAM-1.3.CaseInsensitive/wmake/wmakeDerivedFiles 2005-06-21 09:10:23.000000000 -0700 +++ OpenFOAM-1.3/wmake/wmakeDerivedFiles 2006-04-04 14:56:38.000000000 -0700 @@ -66,76 +66,99 @@ # make sourceFiles # ~~~~~~~~~~~~~~~~ -echo "SOURCE = " > tmpSourceFile -cat files.$$ >> tmpSourceFile - -sed -e 's/$/\\/' \ - -e '$s/\\//' \ - tmpSourceFile > sourceFiles - -rm tmpSourceFile - +echo "SOURCE =" > sourceFiles +cat files.$$ | sed -e 's/(import)\s*//' >> sourceFiles # make objectFiles # ~~~~~~~~~~~~~~~~ -if [ $nJava -ne 0 ] -then - sed -e 's%^%$(CLASSES_DIR)/%' \ - -e 's%\.[a-zA-Z]*$%\.class%' \ - files.$$ > tmpObjectFiles +echo "OBJECTS =" > objectFiles +if [ $nJava -ne 0 ]; then + grep -v "(import)" files.$$ | \ + sed -e 's%^%$(CLASSES_DIR)/%' \ + -e 's%\.[a-zA-Z]*$%\.class%' \ + >> objectFiles else - sed -e 's%.*/%%' \ - -e 's%^%$(OBJECTS_DIR)/%' \ - -e 's%\.[a-zA-Z]*$%\.o%' \ - files.$$ > tmpObjectFiles + grep -v "(import)" files.$$ | \ + sed -e 's%.*/%%' \ + -e 's%^%$(OBJECTS_DIR)/%' \ + -e 's%\.[a-zA-Z]*$%\.o%' \ + >> objectFiles fi -echo "OBJECTS = " > tmpObjectFiles2 -cat tmpObjectFiles >> tmpObjectFiles2 - -sed -e 's/$/\\/' \ - -e '$s/\\//' \ - tmpObjectFiles2 > objectFiles - -rm tmpObjectFiles tmpObjectFiles2 - +# make importObjectFiles +# ~~~~~~~~~~~~~~~~~~~~~~ +echo "IMPORT_OBJECTS =" > importObjectFiles +if [ $nJava -eq 0 ]; then + grep "(import)" files.$$ | \ + sed -e 's/(import)\s*//' \ + -e 's%.*/%%' \ + -e 's%^%$(OBJECTS_DIR)/%' \ + -e 's%\.[a-zA-Z]*$%\_import.o%' \ + >> importObjectFiles +fi # make localObjectFiles # ~~~~~~~~~~~~~~~~~~~~~ -sed -e 's%.*/%%' \ - -e 's%\.[a-zA-Z]*$%\.o%' \ - files.$$ > tmpLocalObjectFiles - -echo "LOCAL_OBJECTS = " > tmpLocalObjectFiles2 -cat tmpLocalObjectFiles >> tmpLocalObjectFiles2 - -sed -e 's/$/\\/' \ - -e '$s/\\//' \ - tmpLocalObjectFiles2 > localObjectFiles - -rm tmpLocalObjectFiles tmpLocalObjectFiles2 - +echo "LOCAL_OBJECTS =" > localObjectFiles +grep -v "(import)" files.$$ | \ +sed -e 's%.*/%%' \ + -e 's%\.[a-zA-Z]*$%\.o%' \ + >> localObjectFiles + +# make importLocalObjectFiles +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~ +echo "IMPORT_LOCAL_OBJECTS =" > importLocalObjectFiles +grep "(import)" files.$$ | \ +sed -e 's%.*/%%' \ + -e 's%\.[a-zA-Z]*$%\_import.o%' \ + >> importLocalObjectFiles # make dependencyFiles # ~~~~~~~~~~~~~~~~~~~~ -sed 's/\.[a-zA-Z]*$/\.dep/' \ - files.$$ > tmpDependencyFiles - -echo "DEPENDENCIES = " > tmpDependencyFiles2 -cat tmpDependencyFiles >> tmpDependencyFiles2 - -sed -e 's/$/\\/' \ - -e '$s/\\//' \ - tmpDependencyFiles2 > dependencyFiles - -rm tmpDependencyFiles tmpDependencyFiles2 - - +echo "DEPENDENCIES =" > dependencyFiles +grep -v "(import)" files.$$ | \ +sed -e 's/\.[a-zA-Z]*$/\.dep/' \ + >> dependencyFiles + +# make importDependencyFiles +# ~~~~~~~~~~~~~~~~~~~~~~~~~~ +echo "IMPORT_DEPENDENCIES =" > importDependencyFiles +grep "(import)" files.$$ | \ +sed -e 's/(import)\s*//' \ + -e 's/\.[a-zA-Z]*$/\.idep/' \ + >> importDependencyFiles + +# add line breakes where necessary +# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +for file_to_filter in sourceFiles \ + objectFiles \ + importObjectFiles \ + localObjectFiles \ + importLocalObjectFiles \ + dependencyFiles \ + importDependencyFiles; do \ + if [ -e $file_to_filter ]; then + sed -e 's/$/\\/' \ + -e '$s/\\//' \ + $file_to_filter > filtered_file; + mv filtered_file $file_to_filter; + fi +done + # make includeDeps # ~~~~~~~~~~~~~~~~ -sed -e 's/\.[a-zA-Z]*$/.dep/' \ - -e 's/^/include /' \ - files.$$ > includeDeps +grep -v "(import)" files.$$ | \ +sed -e 's/\.[a-zA-Z]*$/.dep/' \ + -e 's/^/include /' \ + > includeDeps + +# make includeImportDeps +# ~~~~~~~~~~~~~~~~~~~~~~ +grep "(import)" files.$$ | \ +sed -e 's/(import)\s*//' \ + -e 's/\.[a-zA-Z]*$/.idep/' \ + -e 's/^/include /' \ + > includeImportDeps rm files.$$ diff -Naur OpenFOAM-1.3.CaseInsensitive/wmake/wmakeLnInclude OpenFOAM-1.3/wmake/wmakeLnInclude --- OpenFOAM-1.3.CaseInsensitive/wmake/wmakeLnInclude 2005-06-21 09:10:24.000000000 -0700 +++ OpenFOAM-1.3/wmake/wmakeLnInclude 2006-02-07 23:06:53.000000000 -0800 @@ -81,7 +81,12 @@ echo cd $INCDIR -find .. -name lnInclude -prune -o \( -name '*.[hcHIMC]' -o -name '*.type' \) -exec ln $LNOPTION {} . \; +find .. -name lnInclude -prune -o \( \ + -name '*.[hcHIMC]' \ + -o -name '*.type' \ + -o -name '*.cc' \ + -o -name '*.hh' \ +\) -exec ln $LNOPTION {} . \; #------------------------------------------------------------------------------