OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [orpsocv2/] [bench/] [sysc/] [src/] [Modules.make] - Diff between revs 63 and 64

Only display areas with differences | Details | Blame | View Log

Rev 63 Rev 64
# Make file for SystemC modules not associated directly with Verilator
# Make file for SystemC modules not associated directly with Verilator
#
#
# Copyright (C) 2009 Embecosm Limited
# Copyright (C) 2009 Embecosm Limited
#
#
# Contributor Jeremy Bennett 
# Contributor Jeremy Bennett 
#
#
# This file is part of the cycle accurate model of the OpenRISC 1000 based
# This file is part of the cycle accurate model of the OpenRISC 1000 based
# system-on-chip, ORPSoC, built using Verilator.
# system-on-chip, ORPSoC, built using Verilator.
#
#
# This program is free software; you can redistribute it and/or modify it
# 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
# under the terms of the GNU General Public License as published by the Free
# Software Foundation; either version 3 of the License, or (at your option)
# Software Foundation; either version 3 of the License, or (at your option)
# any later version.
# any later version.
#
#
# This program is distributed in the hope that it will be useful, but WITHOUT
# This program is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
# more details.
# more details.
#
#
# You should have received a copy of the GNU General Public License along
# You should have received a copy of the GNU General Public License along
# with this program.  If not, see . */
# with this program.  If not, see . */
# The C/C++ parts of this program are commented throughout in a fashion
# The C/C++ parts of this program are commented throughout in a fashion
# suitable for processing with Doxygen.
# suitable for processing with Doxygen.
# Tools and flags
# Tools and flags
ARFLAGS = rcs
ARFLAGS = rcs
#CXXFLAGS += $(OPT_FAST) $(OPT_SLOW) $(OPT) $(PROF_FLAGS)
#CXXFLAGS += $(OPT_FAST) $(OPT_SLOW) $(OPT) $(PROF_FLAGS)
ifdef VLT_CPPFLAGS
ifdef VLT_CPPFLAGS
CXXFLAGS += $(VLT_CPPFLAGS)
CXXFLAGS += $(VLT_CPPFLAGS)
endif
endif
CPPFLAGS += -DTARGET_BIG_ENDIAN
CPPFLAGS += -DTARGET_BIG_ENDIAN
CXX ?= g++
CXX ?= g++
#PROF_OPTS ?= -fbranch-probabilities -fvpt -funroll-loops -fpeel-loops -ftracer -O3
#PROF_OPTS ?= -fbranch-probabilities -fvpt -funroll-loops -fpeel-loops -ftracer -O3
OPT_ALL ?= $(OPT_SLOW) $(OPT_FAST) $(OPT)
OPT_ALL ?= $(OPT_SLOW) $(OPT_FAST) $(OPT)
# Sub-directories
# Sub-directories
SYSC_INC_DIR = ../include
SYSC_INC_DIR = ../include
INCDIRS   = -I$(SYSTEMC)/include -I$(SYSC_INC_DIR)
INCDIRS   = -I$(SYSTEMC)/include -I$(SYSC_INC_DIR)
# Local objects
# Local objects
OBJS = DebugUnitSC.o \
OBJS = DebugUnitSC.o \
        GdbServerSC.o \
        GdbServerSC.o \
        JtagSC.o          \
        JtagSC.o          \
        TapAction.o       \
        TapAction.o       \
        TapActionDRScan.o \
        TapActionDRScan.o \
        TapActionIRScan.o \
        TapActionIRScan.o \
        TapActionReset.o  \
        TapActionReset.o  \
        TapStateMachine.o \
        TapStateMachine.o \
        MemCache.o \
        MemCache.o \
        MpHash.o \
        MpHash.o \
        Or1200MonitorSC.o \
        Or1200MonitorSC.o \
        ResetSC.o \
        ResetSC.o \
        RspConnection.o \
        RspConnection.o \
        RspPacket.o \
        RspPacket.o \
        SprCache.o \
        SprCache.o \
        Utils.o \
        Utils.o \
        UartSC.o
        UartSC.o
LIB  = libmodules.a
LIB  = libmodules.a
ifdef VLT_DEBUG
ifdef VLT_DEBUG
CXXFLAGS += -g
CXXFLAGS += -g
endif
endif
# -----------------------------------------------------------------------------
# -----------------------------------------------------------------------------
# Rule to make dependency files
# Rule to make dependency files
%.d: %.cpp
%.d: %.cpp
        @set -e; rm -f $@; \
        @set -e; rm -f $@; \
                $(CXX) -MM $(CPPFLAGS) $(INCDIRS) $< > $@.$$$$; \
                $(CXX) -MM $(CPPFLAGS) $(INCDIRS) $< > $@.$$$$; \
                sed 's,\($*\)\.o[ :]*,\1.o $@ : ,g' < $@.$$$$ > $@; \
                sed 's,\($*\)\.o[ :]*,\1.o $@ : ,g' < $@.$$$$ > $@; \
                rm -f $@.$$$$
                rm -f $@.$$$$
# Rule to make object files
# Rule to make object files
%.o: %.cpp
%.o: %.cpp
        $(CXX) $(CPPFLAGS) $(PROF_OPTS) $(INCDIRS) $(CXXFLAGS) -c  $<
        $(CXX) $(CPPFLAGS) $(PROF_OPTS) $(INCDIRS) $(CXXFLAGS) -c  $<
# -----------------------------------------------------------------------------
# -----------------------------------------------------------------------------
# Make the library
# Make the library
$(LIB): $(OBJS)
$(LIB): $(OBJS)
        $(AR) $(ARFLAGS) $@ $+
        $(AR) $(ARFLAGS) $@ $+
# -----------------------------------------------------------------------------
# -----------------------------------------------------------------------------
# Tidy up
# Tidy up
.PHONY: clean
.PHONY: clean
clean:
clean:
        $(RM) *.d *.d.*
        $(RM) *.d *.d.*
        $(RM) *.o *.gcno *.gcda
        $(RM) *.o *.gcno *.gcda
        $(RM) $(LIB)
        $(RM) $(LIB)
# -----------------------------------------------------------------------------
# -----------------------------------------------------------------------------
# More modest tidy up for branch profiling
# More modest tidy up for branch profiling
.PHONY: prof-clean
.PHONY: prof-clean
prof-clean:
prof-clean:
        $(RM) *.o
        $(RM) *.o
        $(RM) $(LIB)
        $(RM) $(LIB)
# -----------------------------------------------------------------------------
# -----------------------------------------------------------------------------
# Include the dependency files
# Include the dependency files
include $(OBJS:.o=.d)
# Comment out for now. include $(OBJS:.o=.d)
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.