Commit 177da869 authored by sebastien's avatar sebastien
Browse files

trunk:

* use autoconf to create the preprocessor Makefile
* the preprocessor now displays the version number
* the top-level Makefile triggers compilation of the preprocessor and of the documentation


git-svn-id: https://www.dynare.org/svn/dynare/trunk@2621 ac1d8469-bf42-47a9-8791-bf33cf982152
parent 331edd8d
......@@ -91,7 +91,7 @@ main(int argc, char** argv)
}
}
cout << "Starting Dynare ..." << endl
cout << "Starting Dynare (version " << PACKAGE_VERSION << ")." << endl
<< "Starting preprocessing of the model file ..." << endl;
// Construct basename (i.e. remove file extension if there is one)
......
CXXFLAGS = -Wall
ifeq ($(shell uname -o), Cygwin)
# Detection of uninitialized variables is buggy in Cygwin and generates spurious warnings
CXXFLAGS += -Wno-uninitialized
CXXFLAGS += -mno-cygwin
endif
ifeq ($(CROSS_WIN32), yes)
CXX = i586-mingw32msvc-g++
AR = i586-mingw32msvc-ar
# Detection of uninitialized variables is buggy in MinGW and generates spurious warnings
CXXFLAGS += -Wno-uninitialized
endif
ifeq ($(DEBUG),yes)
CXXFLAGS += -ggdb
else
CXXFLAGS += -O3
endif
ifeq ($(VALGRIND), yes)
CXXFLAGS = -Wall -O -g -fno-inline
endif
ifeq ($(shell uname -o), Cygwin)
DYNARE_M = dynare_m.exe
else
DYNARE_M = dynare_m
endif
ifeq ($(CROSS_WIN32), yes)
DYNARE_M = dynare_m.exe
endif
CXX = @CXX@
CXXFLAGS = @CXXFLAGS@
CPPFLAGS = @CPPFLAGS@ @DEFS@
LDFLAGS = @LDFLAGS@
FLEX = @FLEX@
BISON = @BISON@
DYNARE_M = dynare_m@EXEEXT@
MAIN_OBJS = \
DynareFlex.o \
......@@ -79,16 +54,16 @@ $(DYNARE_M): $(MAIN_OBJS) $(MACRO_OBJS)
# Build rules for Flex and Bison files
DynareFlex.cc: DynareFlex.ll
flex -oDynareFlex.cc DynareFlex.ll
$(FLEX) -oDynareFlex.cc DynareFlex.ll
DynareBison.cc DynareBison.hh location.hh stack.hh position.hh: DynareBison.yy
bison --verbose -o DynareBison.cc DynareBison.yy
$(BISON) --verbose -o DynareBison.cc DynareBison.yy
macro/MacroFlex.cc: macro/MacroFlex.ll
cd macro && flex -oMacroFlex.cc MacroFlex.ll
cd macro && $(FLEX) -oMacroFlex.cc MacroFlex.ll
macro/MacroBison.cc macro/MacroBison.hh macro/location.hh macro/stack.hh macro/position.hh: macro/MacroBison.yy
cd macro && bison --verbose -o MacroBison.cc MacroBison.yy
cd macro && $(BISON) --verbose -o MacroBison.cc MacroBison.yy
# Dependencies
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment