Changeset 8


Ignore:
Timestamp:
Jun 25, 2008, 1:08:04 PM (16 years ago)
Author:
nipo
Message:

Checkin autotools magic

Location:
branches/with_autoconf
Files:
8 added
11 deleted
71 edited
2 copied
2 moved

Legend:

Unmodified
Added
Removed
  • branches/with_autoconf/INSTALL

    r1 r8  
    1 SystemCASS Installation
    2 =======================
    3 
    4 To install SystemCASS on linux, do the following steps:
    5 
    6   1. Set the following environment variable(s):
    7 
    8      TARGET_ARCH : architecture name.
    9 
    10      SYSTEMCASS  : SystemCASS top directory.
    11 
    12      ALLIANCE (optional) : ALLIANCE top directory
    13                            See also 'PAT trace output' section.
    14 
    15      For example :
    16 
    17        setenv TARGET_ARCH linux
    18        setenv SYSTEMCASS /users/tools/systemcass/
    19 
    20   2. Change to the top level directory (systemcass)
    21 
    22   3. Type the following command:
    23 
    24        (cd src ; make)
    25 
    26 
    27 PAT trace ouput
    28 ===============
    29 
    30 PAT trace output is disable by default.
    31 Set the environment variable 'ALLIANCE' to ALLIANCE top directory,
    32 then make again.
    33 
     1Installation Instructions
     2*************************
     3
     4Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005 Free
     5Software Foundation, Inc.
     6
     7This file is free documentation; the Free Software Foundation gives
     8unlimited permission to copy, distribute and modify it.
     9
     10Basic Installation
     11==================
     12
     13These are generic installation instructions.
     14
     15   The `configure' shell script attempts to guess correct values for
     16various system-dependent variables used during compilation.  It uses
     17those values to create a `Makefile' in each directory of the package.
     18It may also create one or more `.h' files containing system-dependent
     19definitions.  Finally, it creates a shell script `config.status' that
     20you can run in the future to recreate the current configuration, and a
     21file `config.log' containing compiler output (useful mainly for
     22debugging `configure').
     23
     24   It can also use an optional file (typically called `config.cache'
     25and enabled with `--cache-file=config.cache' or simply `-C') that saves
     26the results of its tests to speed up reconfiguring.  (Caching is
     27disabled by default to prevent problems with accidental use of stale
     28cache files.)
     29
     30   If you need to do unusual things to compile the package, please try
     31to figure out how `configure' could check whether to do them, and mail
     32diffs or instructions to the address given in the `README' so they can
     33be considered for the next release.  If you are using the cache, and at
     34some point `config.cache' contains results you don't want to keep, you
     35may remove or edit it.
     36
     37   The file `configure.ac' (or `configure.in') is used to create
     38`configure' by a program called `autoconf'.  You only need
     39`configure.ac' if you want to change it or regenerate `configure' using
     40a newer version of `autoconf'.
     41
     42The simplest way to compile this package is:
     43
     44  1. `cd' to the directory containing the package's source code and type
     45     `./configure' to configure the package for your system.  If you're
     46     using `csh' on an old version of System V, you might need to type
     47     `sh ./configure' instead to prevent `csh' from trying to execute
     48     `configure' itself.
     49
     50     Running `configure' takes awhile.  While running, it prints some
     51     messages telling which features it is checking for.
     52
     53  2. Type `make' to compile the package.
     54
     55  3. Optionally, type `make check' to run any self-tests that come with
     56     the package.
     57
     58  4. Type `make install' to install the programs and any data files and
     59     documentation.
     60
     61  5. You can remove the program binaries and object files from the
     62     source code directory by typing `make clean'.  To also remove the
     63     files that `configure' created (so you can compile the package for
     64     a different kind of computer), type `make distclean'.  There is
     65     also a `make maintainer-clean' target, but that is intended mainly
     66     for the package's developers.  If you use it, you may have to get
     67     all sorts of other programs in order to regenerate files that came
     68     with the distribution.
     69
     70Compilers and Options
     71=====================
     72
     73Some systems require unusual options for compilation or linking that the
     74`configure' script does not know about.  Run `./configure --help' for
     75details on some of the pertinent environment variables.
     76
     77   You can give `configure' initial values for configuration parameters
     78by setting variables in the command line or in the environment.  Here
     79is an example:
     80
     81     ./configure CC=c89 CFLAGS=-O2 LIBS=-lposix
     82
     83   *Note Defining Variables::, for more details.
     84
     85Compiling For Multiple Architectures
     86====================================
     87
     88You can compile the package for more than one kind of computer at the
     89same time, by placing the object files for each architecture in their
     90own directory.  To do this, you must use a version of `make' that
     91supports the `VPATH' variable, such as GNU `make'.  `cd' to the
     92directory where you want the object files and executables to go and run
     93the `configure' script.  `configure' automatically checks for the
     94source code in the directory that `configure' is in and in `..'.
     95
     96   If you have to use a `make' that does not support the `VPATH'
     97variable, you have to compile the package for one architecture at a
     98time in the source code directory.  After you have installed the
     99package for one architecture, use `make distclean' before reconfiguring
     100for another architecture.
     101
     102Installation Names
     103==================
     104
     105By default, `make install' installs the package's commands under
     106`/usr/local/bin', include files under `/usr/local/include', etc.  You
     107can specify an installation prefix other than `/usr/local' by giving
     108`configure' the option `--prefix=PREFIX'.
     109
     110   You can specify separate installation prefixes for
     111architecture-specific files and architecture-independent files.  If you
     112pass the option `--exec-prefix=PREFIX' to `configure', the package uses
     113PREFIX as the prefix for installing programs and libraries.
     114Documentation and other data files still use the regular prefix.
     115
     116   In addition, if you use an unusual directory layout you can give
     117options like `--bindir=DIR' to specify different values for particular
     118kinds of files.  Run `configure --help' for a list of the directories
     119you can set and what kinds of files go in them.
     120
     121   If the package supports it, you can cause programs to be installed
     122with an extra prefix or suffix on their names by giving `configure' the
     123option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
     124
     125Optional Features
     126=================
     127
     128Some packages pay attention to `--enable-FEATURE' options to
     129`configure', where FEATURE indicates an optional part of the package.
     130They may also pay attention to `--with-PACKAGE' options, where PACKAGE
     131is something like `gnu-as' or `x' (for the X Window System).  The
     132`README' should mention any `--enable-' and `--with-' options that the
     133package recognizes.
     134
     135   For packages that use the X Window System, `configure' can usually
     136find the X include and library files automatically, but if it doesn't,
     137you can use the `configure' options `--x-includes=DIR' and
     138`--x-libraries=DIR' to specify their locations.
     139
     140Specifying the System Type
     141==========================
     142
     143There may be some features `configure' cannot figure out automatically,
     144but needs to determine by the type of machine the package will run on.
     145Usually, assuming the package is built to be run on the _same_
     146architectures, `configure' can figure that out, but if it prints a
     147message saying it cannot guess the machine type, give it the
     148`--build=TYPE' option.  TYPE can either be a short name for the system
     149type, such as `sun4', or a canonical name which has the form:
     150
     151     CPU-COMPANY-SYSTEM
     152
     153where SYSTEM can have one of these forms:
     154
     155     OS KERNEL-OS
     156
     157   See the file `config.sub' for the possible values of each field.  If
     158`config.sub' isn't included in this package, then this package doesn't
     159need to know the machine type.
     160
     161   If you are _building_ compiler tools for cross-compiling, you should
     162use the option `--target=TYPE' to select the type of system they will
     163produce code for.
     164
     165   If you want to _use_ a cross compiler, that generates code for a
     166platform different from the build platform, you should specify the
     167"host" platform (i.e., that on which the generated programs will
     168eventually be run) with `--host=TYPE'.
     169
     170Sharing Defaults
     171================
     172
     173If you want to set default values for `configure' scripts to share, you
     174can create a site shell script called `config.site' that gives default
     175values for variables like `CC', `cache_file', and `prefix'.
     176`configure' looks for `PREFIX/share/config.site' if it exists, then
     177`PREFIX/etc/config.site' if it exists.  Or, you can set the
     178`CONFIG_SITE' environment variable to the location of the site script.
     179A warning: not all `configure' scripts look for a site script.
     180
     181Defining Variables
     182==================
     183
     184Variables not defined in a site shell script can be set in the
     185environment passed to `configure'.  However, some packages may run
     186configure again during the build, and the customized values of these
     187variables may be lost.  In order to avoid this problem, you should set
     188them in the `configure' command line, using `VAR=value'.  For example:
     189
     190     ./configure CC=/usr/local2/bin/gcc
     191
     192causes the specified `gcc' to be used as the C compiler (unless it is
     193overridden in the site shell script).  Here is a another example:
     194
     195     /bin/bash ./configure CONFIG_SHELL=/bin/bash
     196
     197Here the `CONFIG_SHELL=/bin/bash' operand causes subsequent
     198configuration-related scripts to be executed by `/bin/bash'.
     199
     200`configure' Invocation
     201======================
     202
     203`configure' recognizes the following options to control how it operates.
     204
     205`--help'
     206`-h'
     207     Print a summary of the options to `configure', and exit.
     208
     209`--version'
     210`-V'
     211     Print the version of Autoconf used to generate the `configure'
     212     script, and exit.
     213
     214`--cache-file=FILE'
     215     Enable the cache: use and save the results of the tests in FILE,
     216     traditionally `config.cache'.  FILE defaults to `/dev/null' to
     217     disable caching.
     218
     219`--config-cache'
     220`-C'
     221     Alias for `--cache-file=config.cache'.
     222
     223`--quiet'
     224`--silent'
     225`-q'
     226     Do not print messages saying which checks are being made.  To
     227     suppress all normal output, redirect it to `/dev/null' (any error
     228     messages will still be shown).
     229
     230`--srcdir=DIR'
     231     Look for the package's source code in directory DIR.  Usually
     232     `configure' can determine that directory automatically.
     233
     234`configure' also accepts some other, not widely useful, options.  Run
     235`configure --help' for more details.
     236
  • branches/with_autoconf/doc/SystemCASS.tex

    r7 r8  
    129129
    130130\begin{figure}[hbtp]\center\leavevmode
    131 \includegraphics[width=.7\textwidth,angle=270]{figures/SystemeType}
     131\includegraphics[width=.7\textwidth,angle=270]{SystemeType}
    132132\caption{Typical embedded system build around VCI interfaces.}
    133133\label{system}
     
    140140
    141141\begin{figure}[hbtp]\center\leavevmode
    142 \includegraphics[width=.6\linewidth]{figures/Automate}
     142\includegraphics[width=.6\linewidth]{Automate}
    143143\caption{Finite State Machine Modeling}
    144144\label{Automate}
  • branches/with_autoconf/examples/Makefile

    r1 r8  
    1 # EXAMPLES   
    2 EXAMPLES = \
    3            soclib_date04/timer4_gmn_handmade/ \
    4 #
    5 
    6 # RULES
    7 main : 
    8         @for i in $(EXAMPLES) ; do \
    9           echo "Making \'$$i\'" ; \
    10           (cd $$i ; make -f Makefile.casc) ; \
     1# Makefile.in generated by automake 1.10 from Makefile.am.
     2# examples/Makefile.  Generated from Makefile.in by configure.
     3
     4# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
     5# 2003, 2004, 2005, 2006  Free Software Foundation, Inc.
     6# This Makefile.in is free software; the Free Software Foundation
     7# gives unlimited permission to copy and/or distribute it,
     8# with or without modifications, as long as this notice is preserved.
     9
     10# This program is distributed in the hope that it will be useful,
     11# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
     12# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
     13# PARTICULAR PURPOSE.
     14
     15
     16
     17pkgdatadir = $(datadir)/systemcass
     18pkglibdir = $(libdir)/systemcass
     19pkgincludedir = $(includedir)/systemcass
     20am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
     21install_sh_DATA = $(install_sh) -c -m 644
     22install_sh_PROGRAM = $(install_sh) -c
     23install_sh_SCRIPT = $(install_sh) -c
     24INSTALL_HEADER = $(INSTALL_DATA)
     25transform = $(program_transform_name)
     26NORMAL_INSTALL = :
     27PRE_INSTALL = :
     28POST_INSTALL = :
     29NORMAL_UNINSTALL = :
     30PRE_UNINSTALL = :
     31POST_UNINSTALL = :
     32build_triplet = i386-apple-darwin9.3.0
     33host_triplet = i386-apple-darwin9.3.0
     34target_triplet = i386-apple-darwin9.3.0
     35subdir = examples
     36DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
     37ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
     38am__aclocal_m4_deps = $(top_srcdir)/configure.ac
     39am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
     40        $(ACLOCAL_M4)
     41mkinstalldirs = $(install_sh) -d
     42CONFIG_HEADER = $(top_builddir)/config.h
     43CONFIG_CLEAN_FILES =
     44SOURCES =
     45DIST_SOURCES =
     46RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
     47        html-recursive info-recursive install-data-recursive \
     48        install-dvi-recursive install-exec-recursive \
     49        install-html-recursive install-info-recursive \
     50        install-pdf-recursive install-ps-recursive install-recursive \
     51        installcheck-recursive installdirs-recursive pdf-recursive \
     52        ps-recursive uninstall-recursive
     53RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
     54  distclean-recursive maintainer-clean-recursive
     55ETAGS = etags
     56CTAGS = ctags
     57DIST_SUBDIRS = $(SUBDIRS)
     58DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
     59ACLOCAL = ${SHELL} /Users/nipo/projects/systemcass-autoconf/missing --run aclocal-1.10
     60ALLIANCE_CFLAGS =
     61ALLIANCE_PATH =
     62AMTAR = ${SHELL} /Users/nipo/projects/systemcass-autoconf/missing --run tar
     63AR = ar
     64AUTOCONF = ${SHELL} /Users/nipo/projects/systemcass-autoconf/missing --run autoconf
     65AUTOHEADER = ${SHELL} /Users/nipo/projects/systemcass-autoconf/missing --run autoheader
     66AUTOMAKE = ${SHELL} /Users/nipo/projects/systemcass-autoconf/missing --run automake-1.10
     67AWK = gawk
     68CC = gcc
     69CCDEPMODE = depmode=gcc3
     70CFLAGS =  -I/opt/local/include -I/sw/include
     71CPP = gcc -E
     72CPPFLAGS =
     73CXX = g++
     74CXXCPP = g++ -E
     75CXXDEPMODE = depmode=gcc3
     76CXXFLAGS = -g -O2
     77CYGPATH_W = echo
     78DEFS = -DHAVE_CONFIG_H
     79DEPDIR = .deps
     80ECHO = /sw/bin/echo
     81ECHO_C = \c
     82ECHO_N =
     83ECHO_T =
     84EGREP = /usr/bin/grep -E
     85EXEEXT =
     86F77 =
     87FFLAGS =
     88GREP = /usr/bin/grep
     89INSTALL = /sw/bin/ginstall -c
     90INSTALL_DATA = ${INSTALL} -m 644
     91INSTALL_PROGRAM = ${INSTALL}
     92INSTALL_SCRIPT = ${INSTALL}
     93INSTALL_STRIP_PROGRAM = $(install_sh) -c -s
     94LDFLAGS =  -L/opt/local/lib -L/sw/lib
     95LIBOBJS =
     96LIBS =
     97LIBTOOL = $(SHELL) $(top_builddir)/libtool
     98LN_S = ln -s
     99LTLIBOBJS =
     100MAKEINFO = ${SHELL} /Users/nipo/projects/systemcass-autoconf/missing --run makeinfo
     101MKDIR_P = /sw/bin/mkdir -p
     102OBJEXT = o
     103PACKAGE = systemcass
     104PACKAGE_BUGREPORT =
     105PACKAGE_NAME = SystemCASS
     106PACKAGE_STRING = SystemCASS 1.0.0
     107PACKAGE_TARNAME = systemcass
     108PACKAGE_VERSION = 1.0.0
     109PATH_SEPARATOR = :
     110RANLIB = ranlib
     111SC_LIB_TARGET = macosx
     112SET_MAKE =
     113SHELL = /bin/sh
     114SOCLIB_PATH =
     115STRIP = strip
     116VERSION = 1.0.0
     117abs_builddir = /Users/nipo/projects/systemcass-autoconf/examples
     118abs_srcdir = /Users/nipo/projects/systemcass-autoconf/examples
     119abs_top_builddir = /Users/nipo/projects/systemcass-autoconf
     120abs_top_srcdir = /Users/nipo/projects/systemcass-autoconf
     121ac_ct_CC = gcc
     122ac_ct_CXX = g++
     123ac_ct_F77 =
     124am__include = include
     125am__leading_dot = .
     126am__quote =
     127am__tar = ${AMTAR} chof - "$$tardir"
     128am__untar = ${AMTAR} xf -
     129bindir = ${exec_prefix}/bin
     130build = i386-apple-darwin9.3.0
     131build_alias =
     132build_cpu = i386
     133build_os = darwin9.3.0
     134build_vendor = apple
     135builddir = .
     136datadir = ${datarootdir}
     137datarootdir = ${prefix}/share
     138docdir = ${datarootdir}/doc/${PACKAGE_TARNAME}
     139dvidir = ${docdir}
     140exec_prefix = ${prefix}
     141has_bibtex = yes
     142has_dvips = yes
     143has_fig2dev = yes
     144has_latex = yes
     145has_ps2pdf = yes
     146host = i386-apple-darwin9.3.0
     147host_alias =
     148host_cpu = i386
     149host_os = darwin9.3.0
     150host_vendor = apple
     151htmldir = ${docdir}
     152includedir = ${prefix}/include
     153infodir = ${datarootdir}/info
     154install_sh = $(SHELL) /Users/nipo/projects/systemcass-autoconf/install-sh
     155libdir = ${exec_prefix}/lib
     156libexecdir = ${exec_prefix}/libexec
     157localedir = ${datarootdir}/locale
     158localstatedir = ${prefix}/var
     159mandir = ${datarootdir}/man
     160mkdir_p = /sw/bin/mkdir -p
     161oldincludedir = /usr/include
     162pdfdir = ${docdir}
     163prefix = /usr/local
     164program_transform_name = s,x,x,
     165psdir = ${docdir}
     166sbindir = ${exec_prefix}/sbin
     167sharedstatedir = ${prefix}/com
     168srcdir = .
     169sysconfdir = ${prefix}/etc
     170target = i386-apple-darwin9.3.0
     171target_alias =
     172target_cpu = i386
     173target_os = darwin9.3.0
     174target_vendor = apple
     175top_builddir = ..
     176top_srcdir = ..
     177SUBDIRS = soclib_date04
     178all: all-recursive
     179
     180.SUFFIXES:
     181$(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
     182        @for dep in $?; do \
     183          case '$(am__configure_deps)' in \
     184            *$$dep*) \
     185              cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
     186                && exit 0; \
     187              exit 1;; \
     188          esac; \
     189        done; \
     190        echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign  examples/Makefile'; \
     191        cd $(top_srcdir) && \
     192          $(AUTOMAKE) --foreign  examples/Makefile
     193.PRECIOUS: Makefile
     194Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
     195        @case '$?' in \
     196          *config.status*) \
     197            cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
     198          *) \
     199            echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
     200            cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
     201        esac;
     202
     203$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
     204        cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
     205
     206$(top_srcdir)/configure:  $(am__configure_deps)
     207        cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
     208$(ACLOCAL_M4):  $(am__aclocal_m4_deps)
     209        cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
     210
     211mostlyclean-libtool:
     212        -rm -f *.lo
     213
     214clean-libtool:
     215        -rm -rf .libs _libs
     216
     217# This directory's subdirectories are mostly independent; you can cd
     218# into them and run `make' without going through this Makefile.
     219# To change the values of `make' variables: instead of editing Makefiles,
     220# (1) if the variable is set in `config.status', edit `config.status'
     221#     (which will cause the Makefiles to be regenerated when you run `make');
     222# (2) otherwise, pass the desired values on the `make' command line.
     223$(RECURSIVE_TARGETS):
     224        @failcom='exit 1'; \
     225        for f in x $$MAKEFLAGS; do \
     226          case $$f in \
     227            *=* | --[!k]*);; \
     228            *k*) failcom='fail=yes';; \
     229          esac; \
     230        done; \
     231        dot_seen=no; \
     232        target=`echo $@ | sed s/-recursive//`; \
     233        list='$(SUBDIRS)'; for subdir in $$list; do \
     234          echo "Making $$target in $$subdir"; \
     235          if test "$$subdir" = "."; then \
     236            dot_seen=yes; \
     237            local_target="$$target-am"; \
     238          else \
     239            local_target="$$target"; \
     240          fi; \
     241          (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
     242          || eval $$failcom; \
     243        done; \
     244        if test "$$dot_seen" = "no"; then \
     245          $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
     246        fi; test -z "$$fail"
     247
     248$(RECURSIVE_CLEAN_TARGETS):
     249        @failcom='exit 1'; \
     250        for f in x $$MAKEFLAGS; do \
     251          case $$f in \
     252            *=* | --[!k]*);; \
     253            *k*) failcom='fail=yes';; \
     254          esac; \
     255        done; \
     256        dot_seen=no; \
     257        case "$@" in \
     258          distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
     259          *) list='$(SUBDIRS)' ;; \
     260        esac; \
     261        rev=''; for subdir in $$list; do \
     262          if test "$$subdir" = "."; then :; else \
     263            rev="$$subdir $$rev"; \
     264          fi; \
     265        done; \
     266        rev="$$rev ."; \
     267        target=`echo $@ | sed s/-recursive//`; \
     268        for subdir in $$rev; do \
     269          echo "Making $$target in $$subdir"; \
     270          if test "$$subdir" = "."; then \
     271            local_target="$$target-am"; \
     272          else \
     273            local_target="$$target"; \
     274          fi; \
     275          (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
     276          || eval $$failcom; \
     277        done && test -z "$$fail"
     278tags-recursive:
     279        list='$(SUBDIRS)'; for subdir in $$list; do \
     280          test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
    11281        done
    12 
    13 clean :
    14         @for i in $(EXAMPLES) ; do \
    15          echo "Cleaning $$i..." ; \
    16          (cd $$i ; make -f Makefile.casc clean) ; \
     282ctags-recursive:
     283        list='$(SUBDIRS)'; for subdir in $$list; do \
     284          test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
    17285        done
     286
     287ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
     288        list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
     289        unique=`for i in $$list; do \
     290            if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
     291          done | \
     292          $(AWK) '    { files[$$0] = 1; } \
     293               END { for (i in files) print i; }'`; \
     294        mkid -fID $$unique
     295tags: TAGS
     296
     297TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
     298                $(TAGS_FILES) $(LISP)
     299        tags=; \
     300        here=`pwd`; \
     301        if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
     302          include_option=--etags-include; \
     303          empty_fix=.; \
     304        else \
     305          include_option=--include; \
     306          empty_fix=; \
     307        fi; \
     308        list='$(SUBDIRS)'; for subdir in $$list; do \
     309          if test "$$subdir" = .; then :; else \
     310            test ! -f $$subdir/TAGS || \
     311              tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \
     312          fi; \
     313        done; \
     314        list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
     315        unique=`for i in $$list; do \
     316            if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
     317          done | \
     318          $(AWK) '    { files[$$0] = 1; } \
     319               END { for (i in files) print i; }'`; \
     320        if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
     321          test -n "$$unique" || unique=$$empty_fix; \
     322          $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
     323            $$tags $$unique; \
     324        fi
     325ctags: CTAGS
     326CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
     327                $(TAGS_FILES) $(LISP)
     328        tags=; \
     329        here=`pwd`; \
     330        list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
     331        unique=`for i in $$list; do \
     332            if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
     333          done | \
     334          $(AWK) '    { files[$$0] = 1; } \
     335               END { for (i in files) print i; }'`; \
     336        test -z "$(CTAGS_ARGS)$$tags$$unique" \
     337          || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
     338             $$tags $$unique
     339
     340GTAGS:
     341        here=`$(am__cd) $(top_builddir) && pwd` \
     342          && cd $(top_srcdir) \
     343          && gtags -i $(GTAGS_ARGS) $$here
     344
     345distclean-tags:
     346        -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
     347
     348distdir: $(DISTFILES)
     349        @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
     350        topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
     351        list='$(DISTFILES)'; \
     352          dist_files=`for file in $$list; do echo $$file; done | \
     353          sed -e "s|^$$srcdirstrip/||;t" \
     354              -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
     355        case $$dist_files in \
     356          */*) $(MKDIR_P) `echo "$$dist_files" | \
     357                           sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
     358                           sort -u` ;; \
     359        esac; \
     360        for file in $$dist_files; do \
     361          if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
     362          if test -d $$d/$$file; then \
     363            dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
     364            if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
     365              cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
     366            fi; \
     367            cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
     368          else \
     369            test -f $(distdir)/$$file \
     370            || cp -p $$d/$$file $(distdir)/$$file \
     371            || exit 1; \
     372          fi; \
     373        done
     374        list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
     375          if test "$$subdir" = .; then :; else \
     376            test -d "$(distdir)/$$subdir" \
     377            || $(MKDIR_P) "$(distdir)/$$subdir" \
     378            || exit 1; \
     379            distdir=`$(am__cd) $(distdir) && pwd`; \
     380            top_distdir=`$(am__cd) $(top_distdir) && pwd`; \
     381            (cd $$subdir && \
     382              $(MAKE) $(AM_MAKEFLAGS) \
     383                top_distdir="$$top_distdir" \
     384                distdir="$$distdir/$$subdir" \
     385                am__remove_distdir=: \
     386                am__skip_length_check=: \
     387                distdir) \
     388              || exit 1; \
     389          fi; \
     390        done
     391check-am: all-am
     392check: check-recursive
     393all-am: Makefile
     394installdirs: installdirs-recursive
     395installdirs-am:
     396install: install-recursive
     397install-exec: install-exec-recursive
     398install-data: install-data-recursive
     399uninstall: uninstall-recursive
     400
     401install-am: all-am
     402        @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
     403
     404installcheck: installcheck-recursive
     405install-strip:
     406        $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
     407          install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
     408          `test -z '$(STRIP)' || \
     409            echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
     410mostlyclean-generic:
     411
     412clean-generic:
     413
     414distclean-generic:
     415        -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
     416
     417maintainer-clean-generic:
     418        @echo "This command is intended for maintainers to use"
     419        @echo "it deletes files that may require special tools to rebuild."
     420clean: clean-recursive
     421
     422clean-am: clean-generic clean-libtool mostlyclean-am
     423
     424distclean: distclean-recursive
     425        -rm -f Makefile
     426distclean-am: clean-am distclean-generic distclean-tags
     427
     428dvi: dvi-recursive
     429
     430dvi-am:
     431
     432html: html-recursive
     433
     434info: info-recursive
     435
     436info-am:
     437
     438install-data-am:
     439
     440install-dvi: install-dvi-recursive
     441
     442install-exec-am:
     443
     444install-html: install-html-recursive
     445
     446install-info: install-info-recursive
     447
     448install-man:
     449
     450install-pdf: install-pdf-recursive
     451
     452install-ps: install-ps-recursive
     453
     454installcheck-am:
     455
     456maintainer-clean: maintainer-clean-recursive
     457        -rm -f Makefile
     458maintainer-clean-am: distclean-am maintainer-clean-generic
     459
     460mostlyclean: mostlyclean-recursive
     461
     462mostlyclean-am: mostlyclean-generic mostlyclean-libtool
     463
     464pdf: pdf-recursive
     465
     466pdf-am:
     467
     468ps: ps-recursive
     469
     470ps-am:
     471
     472uninstall-am:
     473
     474.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) install-am \
     475        install-strip
     476
     477.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
     478        all all-am check check-am clean clean-generic clean-libtool \
     479        ctags ctags-recursive distclean distclean-generic \
     480        distclean-libtool distclean-tags distdir dvi dvi-am html \
     481        html-am info info-am install install-am install-data \
     482        install-data-am install-dvi install-dvi-am install-exec \
     483        install-exec-am install-html install-html-am install-info \
     484        install-info-am install-man install-pdf install-pdf-am \
     485        install-ps install-ps-am install-strip installcheck \
     486        installcheck-am installdirs installdirs-am maintainer-clean \
     487        maintainer-clean-generic mostlyclean mostlyclean-generic \
     488        mostlyclean-libtool pdf pdf-am ps ps-am tags tags-recursive \
     489        uninstall uninstall-am
     490
     491# Tell versions [3.59,3.63) of GNU make to not export all variables.
     492# Otherwise a system limit (for SysV at least) may be exceeded.
     493.NOEXPORT:
  • branches/with_autoconf/src/alias.cc

    r3 r8  
    3333 */
    3434
    35 #include"alias.h"
    36 #include<string>
    37 //#include<cstdarg.h>
    38 //#include<cstdio.h>
    39 #include<iostream>
     35#include "alias.h"
     36#include <string>
     37//#include <cstdarg.h>
     38//#include <cstdio.h>
     39#include <iostream>
     40#ifdef HAVE_CONFIG_H
     41#include "config.h"
     42#endif
    4043
    4144const char * alias ()
  • branches/with_autoconf/src/bit2string.cc

    r1 r8  
    4141#include <stdlib.h>
    4242#include <iostream>
     43#ifdef HAVE_CONFIG_H
     44#include "config.h"
     45#endif
    4346       
    4447using namespace std;
  • branches/with_autoconf/src/casc.h

    r4 r8  
    4848EXTERN void simulate_1_cycle (void)
    4949{
    50 #ifdef CHECK_FSM_RULES
     50#ifdef CONFIG_CHECK_FSM_RULES
    5151        casc_fsm_step = TRANSITION;
    5252#endif
    5353  transition ();
    5454  update     ();
    55 #ifdef CHECK_FSM_RULES
     55#ifdef CONFIG_CHECK_FSM_RULES
    5656        casc_fsm_step = GEN_MOORE;
    5757#endif
    5858  moore_generation ();
    59 #ifdef CHECK_FSM_RULES
     59#ifdef CONFIG_CHECK_FSM_RULES
    6060        casc_fsm_step = GEN_MEALY;
    6161#endif
    6262  mealy_generation ();
    63 #ifdef CHECK_FSM_RULES
     63#ifdef CONFIG_CHECK_FSM_RULES
    6464        casc_fsm_step = STIMULI;
    6565#endif
  • branches/with_autoconf/src/data_field.h

    r1 r8  
    1313#define __DATA_FIELD_H__
    1414
    15 #include <endianness.h>
    16 
    1715template<int      WIDTH,
    1816         int      PADDING,
    1917         typename data_type>
    20 struct val_field { /* try to work with little endianess */
    21 #if defined(little_endian)
    22   /* little endian */
    23 //  data_type pad:PADDING;
     18struct val_field {
    2419  data_type valW:WIDTH;
    25 #elif defined(big_endian)
    26   /* big endian */
    27   data_type pad:PADDING;
    28   data_type valW:WIDTH;
    29 #else
    30 #error You must define endianness.
    31 #endif
    3220};
    3321
  • branches/with_autoconf/src/dump_dot.cc

    r4 r8  
    4040#include "simplify_string.h"
    4141#include "sc_ver.h" // sc_version
     42#ifdef HAVE_CONFIG_H
     43#include "config.h"
     44#endif
    4245
    4346typedef std::list<sc_core::sc_port_base*> port_list_t;
  • branches/with_autoconf/src/dump_used_env.cc

    r1 r8  
    3535
    3636#include "dump_used_env.h"
     37#ifdef HAVE_CONFIG_H
     38#include "config.h"
     39#endif
    3740
    3841std::string
  • branches/with_autoconf/src/dump_used_options.cc

    r1 r8  
    3535
    3636#include "dump_used_options.h"
     37#ifdef HAVE_CONFIG_H
     38#include "config.h"
     39#endif
    3740
    3841namespace sc_core {
     
    6568  "DUMP_STAGE, "
    6669#endif
    67 #ifdef CHECK_FSM_RULES     
    68   "CHECK_FSM_RULES, "
     70#ifdef CONFIG_CHECK_FSM_RULES     
     71  "CONFIG_CHECK_FSM_RULES, "
    6972#endif
    7073#ifdef COMPIL_DEBUG 
    7174  "COMPIL_DEBUG,"       
    7275#endif
    73 #ifdef DEBUG
    74   "DEBUG, "         
     76#ifdef CONFIG_DEBUG
     77  "CONFIG_DEBUG, "         
    7578#endif
    7679#ifdef UINT64             
  • branches/with_autoconf/src/entity.cc

    r1 r8  
    3535 */
    3636
    37 #include<iomanip>
    38 #include<list>
    39 #include<map>
    40 #include<vector>
    41 
    42 #include"assert.h"
    43 #include"entity.h"
    44 #include"sc_port.h"
    45 #include"sc_signal.h"
    46 #include"sc_module.h"
     37#include <iomanip>
     38#include <list>
     39#include <map>
     40#include <vector>
     41
     42#include <cassert>
     43#include "entity.h"
     44#include "sc_port.h"
     45#include "sc_signal.h"
     46#include "sc_module.h"
     47#ifdef HAVE_CONFIG_H
     48#include "config.h"
     49#endif
    4750
    4851using namespace std;
     
    174177    typedef std::map<const tab_t *,equi_list_t::iterator,predic4tab_t2equi_t_t> tab_t2equi_it_t;
    175178    static tab_t2equi_it_t tab2equi_map;
    176     ASSERT(pointer != NULL);
     179    assert(pointer != NULL);
    177180
    178181    // boost
     
    239242        {
    240243                equi_t::const_iterator top_iter = e.begin ();
    241 #ifdef DEBUG
     244#ifdef CONFIG_DEBUG
    242245                if (top_iter == e.end ()) {
    243246                        cerr << "Internal error : no signal in " << e << endl;
     
    356359        }
    357360       
    358 #if defined(DUMP_SIGNALS_STATS)
     361#if defined(DUMP_SIGNAL_STATS)
    359362        static unsigned int equi_real_size;
    360363#endif
     
    388391    unsigned int table_size = get_sizeof_signals_table ();
    389392                equi_table = new tab_t[table_size]; //(0xCD);
    390 #if defined(DUMP_SIGNALS_STATS)
     393#if defined(DUMP_SIGNAL_STATS)
    391394                equi_real_size = table_size;
    392395#endif
     
    402405  bind_equi_to_table (equi_t &e, tab_t * const pointer)
    403406  {
    404     ASSERT(pointer != NULL);
     407    assert(pointer != NULL);
    405408    equi_t::iterator i;
    406409    for (i = e.begin (); i != e.end (); ++i) {
     
    454457    o << ")";
    455458#else
    456    ASSERT(e.object != NULL);
     459   assert(e.object != NULL);
    457460   o << e.object->name ();
    458461#endif
     
    493496  print_table_stats (ostream &o)
    494497  {
    495 #if defined(DUMP_SIGNALS_STATS)
     498#if defined(DUMP_SIGNAL_STATS)
    496499                int nb_reg = 0;
    497500                int nb_sig = 0;
     
    536539        }
    537540        const entity &ent = *(eq.begin ());
    538 #ifdef DEBUG
     541#ifdef CONFIG_DEBUG
    539542        if (ent.type != sc_core::entity::SIGNAL)
    540543                exit(28);
     
    543546        const char *sig_name = ent.object->name ();
    544547        const char *sep  = strchr (sig_name,'.');
    545 #ifdef DEBUG
     548#ifdef CONFIG_DEBUG
    546549        if (sep == NULL) {
    547550                exit (30);
     
    594597#endif
    595598
    596 #if defined(DUMP_SIGNALS_STATS)
     599#if defined(DUMP_SIGNAL_STATS)
    597600static unsigned int equi_real_size;
    598601#endif
     
    602605{
    603606#if 0
    604 //defined(DEBUG)
     607//defined(CONFIG_DEBUG)
    605608  equi_list_t::iterator x_equi = get_equi (x);
    606609  if ((x_equi != equi_list.end())) {
     
    639642tbind (sc_port_base &x,T &y)
    640643{
    641 //  ASSERT(x.get_pointer () != NULL); // x pointer may be NULL
    642 //  ASSERT(y.get_pointer () != NULL); // y pointer may be NULL
     644//  assert(x.get_pointer () != NULL); // x pointer may be NULL
     645//  assert(y.get_pointer () != NULL); // y pointer may be NULL
    643646  equi_list_t::iterator x_equi = get_equi (x);
    644647  equi_list_t::iterator y_equi = get_equi (y);
  • branches/with_autoconf/src/entity.h

    r1 r8  
    1414#define __ENTITY_H__
    1515
    16 #include<iostream>
    17 #include<list>
    18 #include"sc_fwd.h"
    19 #include"sc_port.h"
    20 #include"sc_signal.h"
     16#include <iostream>
     17#include <list>
     18#include "sc_fwd.h"
     19#include "sc_port.h"
     20#include "sc_signal.h"
    2121
    2222namespace sc_core {
  • branches/with_autoconf/src/fsm_rules.h

    r1 r8  
    1313#define __FSM_RULES_H__
    1414
    15 #ifdef CHECK_FSM_RULES
     15#ifdef HAVE_CONFIG_H
     16#include "config.h"
     17#endif
     18
     19#ifdef CONFIG_CHECK_FSM_RULES
    1620
    1721namespace sc_core {
  • branches/with_autoconf/src/gen_code.cc

    r1 r8  
    3535 */
    3636
    37 #include<stdio.h>
    38 #include<stdlib.h>
    39 #include<iostream>
    40 #include<fstream>
    41 
    42 #include"internal.h"
    43 #include"gen_code.h"
    44 #include"sc_module.h"
    45 #include"sc_ver.h"
    46 #include"process_dependency.h"
    47 
    48 #ifdef CHECK_FSM_RULES
    49 #define fsm_check_flag "-DCHECK_FSM_RULES"
     37#include <stdio.h>
     38#include <stdlib.h>
     39#include <iostream>
     40#include <fstream>
     41
     42#include "internal.h"
     43#include "gen_code.h"
     44#include "sc_module.h"
     45#include "sc_ver.h"
     46#include "process_dependency.h"
     47#ifdef HAVE_CONFIG_H
     48#include "config.h"
     49#endif
     50
     51#ifdef CONFIG_CHECK_FSM_RULES
     52#include "fsm_rules.h"
     53#define fsm_check_flag "-DCONFIG_CHECK_FSM_RULES"
    5054#else
    5155#define fsm_check_flag
    5256#endif
    5357
    54 #define casc_cflags CFLAGS " " fsm_check_flag
    55 
    56 #if defined(darwin)
    57 #define macosx
    58 #endif
     58#define casc_cflags GENERATED_MODULE_CFLAGS " " fsm_check_flag
    5959
    6060using namespace std;
     
    8686                << m.module->name() << "->" << m.name << "()\\n\");\n";
    8787  o << " p.integer = " << func << ";\n";
    88 #if CPP_CALL
     88#ifdef CPP_CALL
    8989  o << " (((sc_module*)(" << m.module << "))->*(p.pmf)) (); /* "
    9090                << m.module->name () << "->" << m.name << "() */\n";
     
    138138  }
    139139
    140 #ifdef DEBUG
     140#ifdef CONFIG_DEBUG
    141141  cerr << "opened temporary filename : " << temp << "\n";
    142142#endif
     
    263263
    264264  o << "// generated by " << sc_version () << endl
    265                 << "#include<casc.h>\n\n"
    266                 << "#include<stdio.h>\n\n"
    267 //              << "#include<iostream>\n\n"
     265                << "#include <casc.h>\n\n"
     266                << "#include <stdio.h>\n\n"
     267//              << "#include <iostream>\n\n"
    268268                << "namespace sc_core {\n"
    269269    << " typedef void (sc_module::*SC_ENTRY_FUNC)();\n"
     
    324324
    325325  o << "// generated by " << sc_version () << endl
    326                 << "#include<casc.h>\n\n"
    327                 << "#include<stdio.h>\n\n"
    328 //              << "#include<iostream>\n\n"
     326                << "#include <casc.h>\n\n"
     327                << "#include <stdio.h>\n\n"
     328//              << "#include <iostream>\n\n"
    329329                << "namespace sc_core {\n"
    330330    << " typedef void (sc_module::*SC_ENTRY_FUNC)();\n"
     
    372372//  const char *target_arch = getenv ("TARGET_ARCH");
    373373        const char *default_compiler =
    374 #if CPP_CALL
     374#ifdef CPP_CALL
    375375                "g++";
    376376#else
     
    413413  /* COMPILE */
    414414  /* ******* */
    415 #if defined(macosx)
    416     sprintf(compil_str,
    417                                 "(cd %s ; %s %s -DSCHEDULING_BY_CASC -I%s/include -fno-common -dynamic -o %s -c %s)",
    418         temporary_dir,
    419                                 compiler,
    420                                 casc_cflags,
    421                                 systemc_dir,
    422                                 target_name,
    423                                 source_name);
    424 //    sprintf(compil_str,"");
    425 #elif defined(linux)
    426     sprintf(compil_str,
    427                                 "(cd %s ; libtool --mode=compile %s %s -DSCHEDULING_BY_CASC -I%s/include -shared -o %s -c %s)",
    428         temporary_dir,
    429                                 compiler,
    430                                 casc_cflags,
    431                                 systemc_dir,
    432                                 target_name,
    433                                 source_name);
     415  const char *commandline_template =
     416#if defined(CONFIG_OS_DARWIN)
     417          "(cd %s ;"                     " %s %s -DSCHEDULING_BY_CASC -I%s/include -fno-common -dynamic -o %s -c %s)"
     418#elif defined(CONFIG_OS_LINUX)
     419          "(cd %s ; libtool --mode=compile %s %s -DSCHEDULING_BY_CASC -I%s/include -shared -o %s -c %s)"
    434420#else
    435     sprintf(compil_str,
    436                                 "(cd %s ; %s %s -DSCHEDULING_BY_CASC -I%s/include -dynamiclib -o %s -c %s)",
    437         temporary_dir,
    438                                 compiler,
    439                                 casc_cflags,
    440                                 systemc_dir,
    441                                 target_name,
    442                                 source_name);
    443 #endif
     421          "(cd %s ;"                     " %s %s -DSCHEDULING_BY_CASC -I%s/include -dynamiclib -o %s -c %s)"
     422#endif
     423          ;
     424  sprintf(compil_str,
     425                  commandline_template,
     426                  temporary_dir,
     427                  compiler,
     428                  casc_cflags,
     429                  systemc_dir,
     430                  target_name,
     431                  source_name);
    444432
    445433  if (dump_stage)
     
    456444  sprintf (target_name, "%s.so", base_name);
    457445
    458 #if defined(linux)
     446#ifdef CONFIG_OS_LINUX
    459447  sprintf (source_name, "%s.lo", base_name);
    460448  sprintf(compil_str, "(cd %s ; pwd ; libtool --mode=link %s %s -shared -rdynamic -o %s %s)", /* -L. -L%s/lib-%s */
     
    555543  for (i = 0; i < n; ++i)
    556544  {
    557 #if 0 //defined(DEBUG)
     545#if 0 //defined(CONFIG_DEBUG)
    558546    sc_module *m = (sc_module*)(fc.instance[i]);
    559547    cerr << m->name () << endl;
     
    570558void static_simulate_1_cycle (void)
    571559{
    572 #ifdef CHECK_FSM_RULES
     560#ifdef CONFIG_CHECK_FSM_RULES
    573561        casc_fsm_step = TRANSITION;
    574562#endif
    575563  call_functions (pf[0]); // transition
    576564  update     ();
    577 #ifdef CHECK_FSM_RULES
     565#ifdef CONFIG_CHECK_FSM_RULES
    578566        casc_fsm_step = GEN_MOORE;
    579567#endif
    580568  call_functions (pf[1]); // moore generation
    581 #ifdef CHECK_FSM_RULES
     569#ifdef CONFIG_CHECK_FSM_RULES
    582570        casc_fsm_step = GEN_MEALY;
    583571#endif
    584572  call_functions (pf[2]); // mealy generation
    585 #ifdef CHECK_FSM_RULES
     573#ifdef CONFIG_CHECK_FSM_RULES
    586574        casc_fsm_step = STIMULI;
    587575#endif
     
    629617void quasistatic_simulate_1_cycle (void)
    630618{
    631 #ifdef CHECK_FSM_RULES
     619#ifdef CONFIG_CHECK_FSM_RULES
    632620        casc_fsm_step = TRANSITION;
    633621#endif
     
    639627  }
    640628  update     ();
    641 #ifdef CHECK_FSM_RULES
     629#ifdef CONFIG_CHECK_FSM_RULES
    642630        casc_fsm_step = GEN_MOORE;
    643631#endif
     
    647635    Call (m);
    648636  }
    649 #ifdef CHECK_FSM_RULES
     637#ifdef CONFIG_CHECK_FSM_RULES
    650638        casc_fsm_step = GEN_MEALY;
    651639#endif
    652640  quasistatic_mealy_generation ();
    653 #ifdef CHECK_FSM_RULES
     641#ifdef CONFIG_CHECK_FSM_RULES
    654642        casc_fsm_step = STIMULI;
    655643#endif
  • branches/with_autoconf/src/gen_code.h

    r1 r8  
    1414#define __GEN_CODE_H__
    1515
    16 #include"internal.h"
    17 #include"global_functions.h"
    18 #include"graph.h"
    19 #include"sc_port.h"
    20 #include"sc_trace.h"
    21 #include"process_dependency.h"
     16#include "internal.h"
     17#include "global_functions.h"
     18#include "graph.h"
     19#include "sc_port.h"
     20#include "sc_trace.h"
     21#include "process_dependency.h"
    2222
    2323//-------------------------------------------------------------------
     
    105105internal_sc_cycle0( double duration )  // in default time units
    106106{
    107 #ifdef DEBUG
     107#ifdef CONFIG_DEBUG
    108108        // Check dynamic linkage
    109109  if ((func_combinationals == NULL) || (func_simulate_1_cycle == NULL)) {
     
    121121#endif
    122122        update ();
    123 #ifdef CHECK_FSM_RULES
     123#ifdef CONFIG_CHECK_FSM_RULES
    124124                casc_fsm_step = GEN_MEALY;
    125125#endif
     
    132132  if (is_posted_write ()) {
    133133    update ();
    134 #ifdef CHECK_FSM_RULES
     134#ifdef CONFIG_CHECK_FSM_RULES
    135135                casc_fsm_step = GEN_MEALY;
    136136#endif
  • branches/with_autoconf/src/global_functions.cc

    r4 r8  
    3535 */
    3636
    37 #include<iostream>
    38 #include<dlfcn.h>
    39 #include"schedulers.h" // get_scheduling & run_schedule_editor
    40 #include"sc_module.h" // check_all_method_process
    41 #include"gen_code.h"  // gen_scheduling_code_for_dynamic_link & gen_scheduling_code_for_static_func
    42 #include"sc_clock_ext.h" // clock list
    43 #include"usage.h"
    44 #include"module_hierarchy2dot.h"
    45 #include"assert.h"
     37#include <iostream>
     38#include <dlfcn.h>
     39#include "schedulers.h" // get_scheduling & run_schedule_editor
     40#include "sc_module.h" // check_all_method_process
     41#include "gen_code.h"  // gen_scheduling_code_for_dynamic_link & gen_scheduling_code_for_static_func
     42#include "sc_clock_ext.h" // clock list
     43#include "usage.h"
     44#include "module_hierarchy2dot.h"
     45#include "assert.h"
     46#ifdef HAVE_CONFIG_H
     47#include "config.h"
     48#endif
     49
     50#ifdef CONFIG_CHECK_FSM_RULES
     51#include "fsm_rules.h"
     52#endif
    4653
    4754using namespace std;
     
    218225   
    219226  char lib_absolutepath[256];
    220 #if defined(darwin) //macosx)
     227#if defined(CONFIG_OS_DARWIN)
    221228  sprintf(lib_absolutepath, "/tmp/%s.so", base_name);
    222 #elif defined(linux)
     229#elif defined(CONFIG_OS_LINUX)
    223230  sprintf(lib_absolutepath, "/tmp/%s.so", base_name);
    224231#else
     
    255262  }
    256263  // Init variables to be able to run combinational functions
    257 #ifdef CHECK_FSM_RULES
     264#ifdef CONFIG_CHECK_FSM_RULES
    258265        casc_fsm_step = STIMULI;
    259266#endif
  • branches/with_autoconf/src/global_functions.h

    r4 r8  
    1313#define __GLOBAL_FUNCTIONS_H__
    1414
    15 #include"sc_fwd.h"
    16 #include"sc_time.h"
     15#include "sc_fwd.h"
     16#include "sc_time.h"
    1717
    1818extern int sc_main(int, char **);
  • branches/with_autoconf/src/graph.cc

    r1 r8  
    113113#include "sc_module.h"
    114114#include "sc_port.h"
     115#ifdef HAVE_CONFIG_H
     116#include "config.h"
     117#endif
    115118
    116119using namespace std;
     
    154157{
    155158Arc *a;
    156 #ifdef DEBUG
     159#ifdef CONFIG_DEBUG
    157160        if ((u == NULL) || (v == NULL))
    158161                exit(29042004);
  • branches/with_autoconf/src/graph_cass.cc

    r1 r8  
    129129#include "simplify_string.h" // simplify_string
    130130#include "sc_ver_ext.h"      // sc_version for dumping to DOT
     131#ifdef HAVE_CONFIG_H
     132#include "config.h"
     133#endif
    131134
    132135using namespace std;
  • branches/with_autoconf/src/graph_signals.cc

    r1 r8  
    139139#include "sc_module.h"
    140140#include "sc_port.h"
     141#ifdef HAVE_CONFIG_H
     142#include "config.h"
     143#endif
    141144
    142145using namespace std;
  • branches/with_autoconf/src/hex2string.cc

    r1 r8  
    4141#include <stdlib.h>
    4242#include <iostream>
     43#ifdef HAVE_CONFIG_H
     44#include "config.h"
     45#endif
    4346       
    4447using namespace std;
  • branches/with_autoconf/src/methodprocess_dependency.cc

    r1 r8  
    3434 */
    3535
    36 #include "assert.h"
     36#include <cassert>
    3737#include "methodprocess_dependency.h"
    3838#include "simplify_string.h"
     
    4040#include <iostream>
    4141#include <fstream>
     42#ifdef HAVE_CONFIG_H
     43#include "config.h"
     44#endif
    4245
    4346using namespace std;
     
    4750get_name (const method_process_t *method)
    4851{
    49   ASSERT(method != NULL);
     52  assert(method != NULL);
    5053  const sc_module *module = method->module;
    51   ASSERT(module != NULL);
     54  assert(module != NULL);
    5255  const char *module_name = module->name ();
    5356  const char *function_name = method->name;
     
    8588    const SignalDependency &sd = *it;
    8689    const equi_t           *source_equi     = sd.source;
    87     ASSERT(source_equi != NULL);
     90    assert(source_equi != NULL);
    8891          const method_process_t *source_method   = table[source_equi];
    8992    if (source_method == NULL)
  • branches/with_autoconf/src/module_hierarchy.cc

    r1 r8  
    3636#include "module_hierarchy.h"
    3737#include "sc_module.h"
    38 #include "assert.h"
     38#include <cassert>
    3939#include <map>
     40#ifdef HAVE_CONFIG_H
     41#include "config.h"
     42#endif
    4043
    4144using namespace std;
     
    7174      return; //obj_list = &top_level_objects;
    7275    else {
    73       ASSERT(parent != &obj);
     76      assert(parent != &obj);
    7477      const sc_object *pobj      = (const sc_module *) parent;
    7578      obj_list = &(object2childs[pobj]);
  • branches/with_autoconf/src/module_hierarchy2dot.cc

    r1 r8  
    4343#include "sc_signal.h"
    4444#include "entity.h"
    45 #include "assert.h"
     45#include <cassert>
    4646#include "internal.h"
     47#ifdef HAVE_CONFIG_H
     48#include "config.h"
     49#endif
    4750
    4851using namespace std;
     
    8891      const entity &in_entity  = *it;
    8992      sc_object    *in_obj     = in_entity.object;
    90       ASSERT(in_obj != NULL);
     93      assert(in_obj != NULL);
    9194      const sc_module *in_parent = NULL;
    9295      switch (in_entity.type) {
  • branches/with_autoconf/src/mouchard_scheduling.cc

    r1 r8  
    4545#include "sc_module.h"
    4646#include "sc_ver.h"
     47#ifdef HAVE_CONFIG_H
     48#include "config.h"
     49#endif
    4750
    4851using namespace std;
  • branches/with_autoconf/src/port_dependency.cc

    r1 r8  
    4444#include "sc_port.h"
    4545#include "sc_ver_ext.h"
     46#ifdef HAVE_CONFIG_H
     47#include "config.h"
     48#endif
    4649
    4750using namespace std;
     
    107110        p.destination = &b;
    108111        aPortDependencyGraph.push_back (p);
    109 #if DUMP_PORT_DEPENDENCY
     112#ifdef DUMP_PORT_DEPENDENCY
    110113        if (a) {
    111114                cerr << "'" << ((sc_object&)b).name()
  • branches/with_autoconf/src/process_dependency.cc

    r1 r8  
    4444#include "sc_module.h"
    4545#include "sc_ver.h"
     46#ifdef HAVE_CONFIG_H
     47#include "config.h"
     48#endif
    4649
    4750using namespace std;
  • branches/with_autoconf/src/sc_bigint.h

    r1 r8  
    2222// ----------------------------------------------------------------------------
    2323
    24 #include"sc_nbdefs.h"
     24#include "sc_nbdefs.h"
    2525
    2626namespace sc_dt {
  • branches/with_autoconf/src/sc_biguint.h

    r1 r8  
    1818// ----------------------------------------------------------------------------
    1919
    20 #include"sc_nbdefs.h"
     20#include "sc_nbdefs.h"
    2121
    2222namespace sc_dt {
  • branches/with_autoconf/src/sc_bit.h

    r1 r8  
    1313#define __SC_BIT_H__
    1414
    15 #include"sc_nbdefs.h"
    16 #include"sc_fwd.h"
    17 #include"sc_logic.h"
    18 #include"sc_string.h"
    19 #include"sc_numrep.h"
     15#include "sc_nbdefs.h"
     16#include "sc_fwd.h"
     17#include "sc_logic.h"
     18#include "sc_string.h"
     19#include "sc_numrep.h"
    2020
    2121// ----------------------------------------------------------------------------
  • branches/with_autoconf/src/sc_bv.h

    r1 r8  
    1818// ----------------------------------------------------------------------------
    1919
    20 #include"sc_nbdefs.h"
    21 #include"sc_logic.h"
    22 #include"sc_unsigned.h"
    23 #include"sc_signed.h"
    24 #include"sc_uint.h"
    25 #include"sc_int.h"
     20#include "sc_nbdefs.h"
     21#include "sc_logic.h"
     22#include "sc_unsigned.h"
     23#include "sc_signed.h"
     24#include "sc_uint.h"
     25#include "sc_int.h"
    2626
    2727namespace sc_dt {
  • branches/with_autoconf/src/sc_clock.cc

    r1 r8  
    3535 */
    3636
    37 #include"sc_clock.h"
    38 #include"assert.h"
     37#include "sc_clock.h"
     38#include <cassert>
     39#ifdef HAVE_CONFIG_H
     40#include "config.h"
     41#endif
    3942
    4043using namespace std;
     
    6972{
    7073        init ();
    71   ASSERT(period_     == 1);
    72   ASSERT(duty_cycle_ == 0.5);
    73   ASSERT(start_time_ == SC_ZERO_TIME);
     74  assert(period_     == 1);
     75  assert(duty_cycle_ == 0.5);
     76  assert(start_time_ == SC_ZERO_TIME);
    7477  posedge_first = posedge_first_;
    7578}
     
    8285{
    8386        init ();
    84   ASSERT(period_     == 1);
    85   ASSERT(duty_cycle_ == 0.5);
    86   ASSERT(start_time_ == SC_ZERO_TIME);
     87  assert(period_     == 1);
     88  assert(duty_cycle_ == 0.5);
     89  assert(start_time_ == SC_ZERO_TIME);
    8790  posedge_first = posedge_first_;
    8891}
  • branches/with_autoconf/src/sc_clock.h

    r1 r8  
    1414#define __SC_CLOCK_H__
    1515
    16 #include"sc_clock_ext.h"
     16#include "sc_clock_ext.h"
    1717
    1818
  • branches/with_autoconf/src/sc_event.cc

    r1 r8  
    3535
    3636
    37 #include<iostream>
    38 #include"sc_event.h"
    39 #include"sc_interface.h"
    40 #include"sc_port_ext.h"
     37#include <iostream>
     38#include "sc_event.h"
     39#include "sc_interface.h"
     40#include "sc_port_ext.h"
     41#ifdef HAVE_CONFIG_H
     42#include "config.h"
     43#endif
    4144
    4245using namespace std;
  • branches/with_autoconf/src/sc_event.h

    r1 r8  
    1313#define __SC_EVENT_H__
    1414
    15 #include"sc_fwd.h"
     15#include "sc_fwd.h"
    1616
    1717namespace sc_core {
  • branches/with_autoconf/src/sc_event_finder.cc

    r4 r8  
    3535
    3636
    37 #include"sc_event_finder.h"
     37#include "sc_event_finder.h"
     38#ifdef HAVE_CONFIG_H
     39#include "config.h"
     40#endif
    3841
    3942namespace sc_core {
  • branches/with_autoconf/src/sc_event_finder.h

    r4 r8  
    1313#define __SC_EVENT_FINDER_H__
    1414
    15 #include"sc_fwd.h"
     15#include "sc_fwd.h"
    1616
    1717namespace sc_core {
  • branches/with_autoconf/src/sc_int.h

    r1 r8  
    2828// ----------------------------------------------------------------------------
    2929
    30 #include"sc_nbdefs.h"
     30#include "sc_nbdefs.h"
    3131
    3232namespace sc_dt {
  • branches/with_autoconf/src/sc_interface.cc

    r1 r8  
    3434 */
    3535
    36 #include"sc_interface.h"
    37 #include"sc_event.h"
    38 #include"assert.h"
    39 #include<iostream>
    40 #include<map>
     36#include "sc_interface.h"
     37#include "sc_event.h"
     38#include "assert.h"
     39#include <iostream>
     40#include <map>
     41#ifdef HAVE_CONFIG_H
     42#include "config.h"
     43#endif
    4144
    4245using namespace std;
     
    105108{
    106109        interface2infos_t::iterator i = interface2infos.find (this);
    107 #ifdef DEBUG
     110#ifdef CONFIG_DEBUG
    108111        if (i == interface2infos.end ()) {
    109112                cerr << "Internal error : can't find data size of " << this << "\n";
     
    118121{
    119122        interface2infos_t::iterator i = interface2infos.find (this);
    120 #ifdef DEBUG
     123#ifdef CONFIG_DEBUG
    121124        if (i == interface2infos.end ()) {
    122125                cerr << "Internal error : can't find default event of " << this << "\n";
  • branches/with_autoconf/src/sc_interface.h

    r1 r8  
    1313#define __SC_INTERFACE_H__
    1414
    15 #include"sc_fwd.h"
    16 #include"internal_ext.h"
     15#include "sc_fwd.h"
     16#include "internal_ext.h"
    1717
    1818namespace sc_core {
  • branches/with_autoconf/src/sc_logic.cc

    r1 r8  
    3939// ----------------------------------------------------------------------------
    4040
    41 #include"sc_logic.h"
     41#include "sc_logic.h"
     42#ifdef HAVE_CONFIG_H
     43#include "config.h"
     44#endif
    4245
    4346namespace sc_dt {
  • branches/with_autoconf/src/sc_logic.h

    r1 r8  
    1818// ----------------------------------------------------------------------------
    1919
    20 #include"sc_nbdefs.h"
    21 #include"sc_fwd.h"
     20#include "sc_nbdefs.h"
     21#include "sc_fwd.h"
    2222
    2323namespace sc_dt {
  • branches/with_autoconf/src/sc_lv.h

    r1 r8  
    1818// ----------------------------------------------------------------------------
    1919
    20 #include"sc_nbdefs.h"
    21 #include"sc_logic.h"
    22 #include"sc_unsigned.h"
    23 #include"sc_signed.h"
    24 #include"sc_uint.h"
    25 #include"sc_int.h"
     20#include "sc_nbdefs.h"
     21#include "sc_logic.h"
     22#include "sc_unsigned.h"
     23#include "sc_signed.h"
     24#include "sc_uint.h"
     25#include "sc_int.h"
    2626
    2727
  • branches/with_autoconf/src/sc_main.cc

    r4 r8  
    3535 */
    3636
    37 #include<sstream>
    38 #include<string>
    39 #include<list>
    40 #include<set>
    41 #include"internal.h"
    42 #include"global_functions.h"
    43 #include"sc_ver.h"
    44 #include"sc_module.h"
    45 #include"sc_signal.h" // pending_write_vector
    46 #include"dump_dot.h"
    47 #include"dump_used_options.h"
    48 #include"dump_used_env.h"
    49 #include"assert.h"
     37#include <sstream>
     38#include <string>
     39#include <list>
     40#include <set>
     41#include "internal.h"
     42#include "global_functions.h"
     43#include "sc_ver.h"
     44#include "sc_module.h"
     45#include "sc_signal.h" // pending_write_vector
     46#include "dump_dot.h"
     47#include "dump_used_options.h"
     48#include "dump_used_env.h"
     49#include <cassert>
     50#ifdef HAVE_CONFIG_H
     51#include "config.h"
     52#endif
    5053
    5154//
     
    5962
    6063bool        check_port_dependencies = false;
     64#ifdef CONFIG_DEFAULT_RUNTIME_COMPILATION
     65bool        dynamic_link_of_scheduling_code = true;
     66#else
    6167bool        dynamic_link_of_scheduling_code = false;
     68#endif
    6269bool        dump_netlist_info       = false;
    6370bool        dump_funclist_info      = false;
     
    107114  switch (scheduling_method) {
    108115  case CASS_SCHEDULING :
    109     ASSERT(use_port_dependency == false);
     116    assert(use_port_dependency == false);
    110117    break;
    111118  case BUCHMANN_SCHEDULING :
     
    124131    exit (33);
    125132  }
    126   ASSERT(use_port_dependency || use_sensitivity_list);
     133  assert(use_port_dependency || use_sensitivity_list);
    127134}
    128135
  • branches/with_autoconf/src/sc_module.cc

    r1 r8  
    4949#include "sc_clock.h" // is_clock
    5050#include "entity.h"
    51 #include "assert.h"
     51#include <cassert>
     52#ifdef HAVE_CONFIG_H
     53#include "config.h"
     54#endif
    5255
    5356//
     
    161164  sensitivity_list_t::iterator i;
    162165  for (i = sensitivity_list.begin (); i != sensitivity_list.end (); ++i) {
    163 #if defined(_DEBUG)
     166#if defined(CONFIG_DEBUG) && 0
    164167    if (i->get_interface() == NULL)
    165168    {
     
    239242          sensitive (this)
    240243{
    241   ASSERT(nm != NULL);
     244  assert(nm != NULL);
    242245#if 0
    243246  cerr << "sc_module constructor with const char * parameter\n";
     
    499502  if (m_pushed == false)
    500503    return;
    501   ASSERT(sc_core::module_name_stack.empty () == false);
     504  assert(sc_core::module_name_stack.empty () == false);
    502505  sc_core::module_name_stack.pop_back ();
    503506        modules_stack.pop ();
     
    505508  cout << "~sc_module_name <- " << m_name << endl;
    506509#endif
    507   ASSERT(temp_list.empty () == false);
     510  assert(temp_list.empty () == false);
    508511  sc_module *last1 = temp_list.back();
    509512  temp_list.pop_back();
     
    527530  if (m.dont_initialize == false)
    528531  {
    529     ASSERT(m.module != NULL);
    530 #if DEBUG
     532    assert(m.module != NULL);
     533#ifdef CONFIG_DEBUG
    531534    std::cerr << "Warning : SystemCASS doesn't perform SC_METHOD(S) initializations.\n"
    532535              << "Please turn off automatic initialization for '" << m.name
  • branches/with_autoconf/src/sc_module.h

    r1 r8  
    1616#include "sc_module_ext.h"
    1717
    18 #include<list>
    19 #include<set>
    20 #include<stack>
    21 #include"sc_fwd.h"
    22 #include"internal.h"
    23 #include"sc_object.h"
    24 #include"sc_sensitive.h"
     18#include <list>
     19#include <set>
     20#include <stack>
     21#include "sc_fwd.h"
     22#include "internal.h"
     23#include "sc_object.h"
     24#include "sc_sensitive.h"
    2525
    2626namespace sc_core {
  • branches/with_autoconf/src/sc_module_ext.h

    r1 r8  
    3838#define __SC_MODULE_EXT_H__
    3939
    40 #include"sc_fwd.h"
    41 #include"internal_ext.h"
    42 #include"sc_object.h"
    43 #include"sc_sensitive.h"
    44 #include"serialization_ext.h"
     40#include "sc_fwd.h"
     41#include "internal_ext.h"
     42#include "sc_object.h"
     43#include "sc_sensitive.h"
     44#include "serialization_ext.h"
    4545
    4646namespace sc_core {
  • branches/with_autoconf/src/sc_module_name.h

    r1 r8  
    1414#define __SC_MODULE_NAME_H__
    1515
    16 #include"sc_fwd.h"
     16#include "sc_fwd.h"
    1717
    1818namespace sc_core {
  • branches/with_autoconf/src/sc_numrep.cc

    r1 r8  
    3636#include <string>
    3737#include "sc_numrep.h"
     38#ifdef HAVE_CONFIG_H
     39#include "config.h"
     40#endif
    3841
    3942namespace sc_dt {
  • branches/with_autoconf/src/sc_object.cc

    r1 r8  
    3939#include <map>
    4040
    41 #include "assert.h"
     41#include <cassert>
    4242#include "sc_object.h"
    4343//#include "sc_port.h"
     
    4545#include "sc_signal.h"
    4646#include "module_hierarchy.h"
     47#ifdef HAVE_CONFIG_H
     48#include "config.h"
     49#endif
    4750
    4851using namespace std;
     
    7073//    out += ".";
    7174  }
    72 //  ASSERT(name != NULL);
     75//  assert(name != NULL);
    7376  if (name)
    7477    out += name;
     
    202205{
    203206        object2name_t::iterator i = object2fullname.find (this);
    204 #ifdef DEBUG
     207#ifdef CONFIG_DEBUG
    205208        if (i == object2fullname.end ()) {
    206209                cerr << "Internal error : can't find name of " << this << "\n";
     
    216219/*
    217220        object2name_t::iterator i = object2fullname.find (this);
    218 #ifdef DEBUG
     221#ifdef CONFIG_DEBUG
    219222        if (i == object2fullname.end ()) {
    220223                cerr << "Internal error : can't find name of " << this << "\n";
     
    234237    string     out;
    235238    sc_object* obj = *it;
    236     ASSERT(obj != NULL);
     239    assert(obj != NULL);
    237240    build_full_name (out, *obj);
    238241  }
     
    242245{
    243246        object2infos_t::iterator i = object2infos.find (this);
    244 #ifdef DEBUG
     247#ifdef CONFIG_DEBUG
    245248        if (i == object2infos.end ()) {
    246249                cerr << "Internal error : can't find kind of " << this << "\n";
  • branches/with_autoconf/src/sc_pat_trace.cc

    r1 r8  
    3636
    3737
    38 #include"sc_trace.h"
    39 #include"sc_pat_trace.h"
    40 #include"sc_ver.h"
    41 #include"internal.h" // notrace
     38#include "sc_trace.h"
     39#include "sc_pat_trace.h"
     40#include "sc_ver.h"
     41#include "internal.h" // notrace
    4242
    43 #include<time.h>
    44 #include<string>
     43#include <time.h>
     44#include <string>
     45#ifdef HAVE_CONFIG_H
     46#include "config.h"
     47#endif
    4548
    46 #ifdef PAT_TRACE_FORMAT
     49#ifdef CONFIG_PAT_TRACE_FORMAT
    4750
    4851//-----------------------------------------
  • branches/with_autoconf/src/sc_port.cc

    r4 r8  
    3636
    3737
    38 #include<iomanip>
    39 #include<list>
    40 #include<map>
    41 #include<vector>
    42 
    43 #include"sc_port.h"
    44 #include"sc_signal.h"
    45 #include"sc_module.h"
    46 #include"entity.h"
    47 #include"global_functions.h"
    48 #include"assert.h"
     38#include <iomanip>
     39#include <list>
     40#include <map>
     41#include <vector>
     42
     43#include "sc_port.h"
     44#include "sc_signal.h"
     45#include "sc_module.h"
     46#include "entity.h"
     47#include "global_functions.h"
     48#include <cassert>
     49#ifdef HAVE_CONFIG_H
     50#include "config.h"
     51#endif
    4952
    5053extern "C" {
     
    5659using namespace std;
    5760
    58 #ifdef CHECK_FSM_RULES
    59 #include"fsm_rules.h"
     61#ifdef CONFIG_CHECK_FSM_RULES
     62#include "fsm_rules.h"
    6063namespace sc_core {
    6164casc_fsm_step_t casc_fsm_step = ELABORATION;
     
    110113sc_port_base::init ()
    111114{
    112 #ifdef DEBUG
     115#ifdef CONFIG_DEBUG
    113116        if (modules_stack.empty ()) {
    114117                cerr << "Internal error : modules stack empty\n";
     
    235238#endif
    236239#define iter (sc_core::pending_write_vector[i])
    237 #ifdef DEBUG
     240#ifdef CONFIG_DEBUG
    238241                if (iter.pointer == NULL) {
    239242                        cerr << "Internal error : trying to apply a posted write from an unassigned signal/port\n";
     
    257260  cerr << "done.\n";
    258261#endif
    259 #if defined(CHECK_MULTIWRITING2REGISTER)
     262#if defined(CONFIG_CHECK_MULTIWRITING2REGISTER)
    260263  sc_core::pending_writing2register_clear ();
    261264#endif
     
    312315{
    313316  const tab_t *pointer = port.get_pointer ();
    314   //ASSERT(pointer != NULL);
     317  //assert(pointer != NULL);
    315318  if (pointer == NULL)
    316319    return false; // case : sc_in not bound
     
    345348  {
    346349    /*const*/ sc_port_base *port = i->first;
    347     ASSERT(port != NULL);
     350    assert(port != NULL);
    348351    check_port (*port);
    349352  }
     
    352355}
    353356
    354 #if defined(CHECK_MULTIWRITING2REGISTER)
     357#if defined(CONFIG_CHECK_MULTIWRITING2REGISTER)
    355358typedef set<const tab_t*> pending_writing2register_set_t;
    356359pending_writing2register_set_t pending_writing2register_set;
  • branches/with_autoconf/src/sc_port.h

    r1 r8  
    1414#define __SC_PORT_H__
    1515
    16 #include"sc_port_ext.h"
    17 #include"sc_fwd.h"
    18 //#include"internal_ext.h"
     16#include "sc_port_ext.h"
     17#include "sc_fwd.h"
     18//#include "internal_ext.h"
    1919
    2020#include <list>
  • branches/with_autoconf/src/sc_port_ext.h

    r4 r8  
    1515
    1616// Define registers writing method
    17 #include<iostream>
    18 #include"sc_fwd.h"
    19 #include"sc_nbdefs.h"
    20 //#include"sc_event_finder.h"
    21 #include"sc_event.h"
    22 #include"sc_object.h"
    23 #include"sc_interface.h"
    24 #include"internal_ext.h"
    25 #include"port_dependency_ext.h"
    26 #include"fsm_rules.h"
     17#include <iostream>
     18#include "sc_fwd.h"
     19#include "sc_nbdefs.h"
     20//#include "sc_event_finder.h"
     21#include "sc_event.h"
     22#include "sc_object.h"
     23#include "sc_interface.h"
     24#include "internal_ext.h"
     25#include "port_dependency_ext.h"
     26#include "fsm_rules.h"
    2727
    2828
     
    5353        ///////////////////// DEPRECATED
    5454// C ANSI-only since it is needed to link with extern "C"
    55 // this declaration is not in casc.h since the CHECK_FSM_RULES macro
     55// this declaration is not in casc.h since the CONFIG_CHECK_FSM_RULES macro
    5656// is not defined.
    5757
     
    183183                << " on signal " << name () << "\n";
    184184#endif
    185 #ifdef CHECK_FSM_RULES
     185#ifdef CONFIG_CHECK_FSM_RULES
    186186        if (casc_fsm_step == GEN_MOORE) {
    187187                std::cerr << "FSM rules error : trying to read on input port '"
     
    293293                << " on signal " << name () << "\n";
    294294#endif
    295 #ifdef CHECK_FSM_RULES
     295#ifdef CONFIG_CHECK_FSM_RULES
    296296        if (casc_fsm_step == GEN_MOORE) {
    297297                std::cerr << "FSM rules error : trying to read on input/output port "
     
    315315            << " on in/out port (writing into a signal) '" << name () << "'\n";
    316316#endif
    317 #ifdef CHECK_FSM_RULES
     317#ifdef CONFIG_CHECK_FSM_RULES
    318318        if ((casc_fsm_step != GEN_MOORE) && ( casc_fsm_step != GEN_MEALY)) {
    319319                std::cerr << "FSM rules error : trying to write on output port "
     
    324324#endif
    325325//      T& ref = *(T*)(get_pointer());
    326 #if defined(CHECK_MULTIWRITING2PORT)
     326#if defined(CONFIG_CHECK_MULTIWRITING2PORT)
    327327  check_multiwriting2port ();
    328328#endif
  • branches/with_autoconf/src/sc_sensitive.cc

    r1 r8  
    3535
    3636
    37 #include"sc_sensitive.h"
    38 #include"sc_port.h"
    39 #include"sc_event.h"
    40 #include"sc_event_finder.h"
    41 #include"sc_module.h"
    42 #include"internal.h"
     37#include "sc_sensitive.h"
     38#include "sc_port.h"
     39#include "sc_event.h"
     40#include "sc_event_finder.h"
     41#include "sc_module.h"
     42#include "internal.h"
     43#ifdef HAVE_CONFIG_H
     44#include "config.h"
     45#endif
    4346
    4447using namespace std;
  • branches/with_autoconf/src/sc_sensitive.h

    r1 r8  
    1313#define __SC_SENSITIVE_H__
    1414
    15 #include<list>
    16 #include"sc_fwd.h"
    17 //#include"sc_event.h"
    18 //#include"sc_interface.h"
    19 //#include"internal_ext.h"
     15#include <list>
     16#include "sc_fwd.h"
     17//#include "sc_event.h"
     18//#include "sc_interface.h"
     19//#include "internal_ext.h"
    2020
    2121namespace sc_core {
  • branches/with_autoconf/src/sc_signal.h

    r1 r8  
    1515
    1616// Define registers writing method
    17 #include<iostream>
    18 #include"sc_fwd.h"
    19 #include"sc_nbdefs.h"
    20 //#include"sc_event_finder.h"
    21 //#include"sc_event.h"
    22 #include"sc_time.h" // SC_ZERO_TIME
    23 #include"sc_object.h"
    24 #include"sc_interface.h"
    25 #include"internal_ext.h"
     17#include <iostream>
     18#include "sc_fwd.h"
     19#include "sc_nbdefs.h"
     20//#include "sc_event_finder.h"
     21//#include "sc_event.h"
     22#include "sc_time.h" // SC_ZERO_TIME
     23#include "sc_object.h"
     24#include "sc_interface.h"
     25#include "internal_ext.h"
     26
     27#ifdef CONFIG_CHECK_FSM_RULES
    2628#include "fsm_rules.h"
     29#endif
    2730
    2831namespace sc_core {
     
    4144        ///////////////////// DEPRECATED
    4245// C ANSI-only since it is needed to link with extern "C"
    43 // this declaration is not in casc.h since the CHECK_FSM_RULES macro
     46// this declaration is not in casc.h since the CONFIG_CHECK_FSM_RULES macro
    4447// is not defined.
    4548
     
    97100                post_multiwrite (pointer_,value_);
    98101        } else {
    99 #if defined(DEBUG)
     102#if defined(CONFIG_DEBUG)
    100103        if (pending_write_vector_nb >= pending_write_vector_capacity) {
    101104        //if (pending_write_vector_nb >= pending_write_vector_capacity * sizeof(pending_write)) {
     
    105108                exit (-1);
    106109        }
    107 #endif // DEBUG
     110#endif // CONFIG_DEBUG
    108111  pending_write_vector[pending_write_vector_nb].pointer = pointer_;
    109112//      pending_write_vector[pending_write_vector_nb++].value = *(reinterpret_cast<const base_type*const>(&value_)); => bug !
     
    244247                << " on signal " << name () << "\n";
    245248#endif
    246 #ifdef CHECK_FSM_RULES
     249#ifdef CONFIG_CHECK_FSM_RULES
    247250        // we can read value from sc_signal type (used like a register) at any time
    248251#endif 
     
    256259sc_signal<T>::write( const data_type& value_ )
    257260{
    258 #ifdef CHECK_FSM_RULES
     261#ifdef CONFIG_CHECK_FSM_RULES
    259262        if ((casc_fsm_step != TRANSITION)
    260263                        && ( casc_fsm_step != STIMULI)) {
     
    265268        }               
    266269#endif
    267 #ifdef DEBUG
     270#ifdef CONFIG_DEBUG
    268271  if (get_pointer() == NULL)
    269272  {
     
    272275  }
    273276#endif
    274 #ifdef CHECK_MULTIWRITING2REGISTER
     277#ifdef CONFIG_CHECK_MULTIWRITING2REGISTER
    275278  pending_writing2register_record_and_check (get_pointer ());
    276279#endif
  • branches/with_autoconf/src/sc_time.cc

    r4 r8  
    3535
    3636
    37 #include"sc_time.h"
     37#include "sc_time.h"
    3838#include <time.h>
    3939#include <sys/time.h>
    4040#include <string>
    4141#include <sstream>
     42#ifdef HAVE_CONFIG_H
     43#include "config.h"
     44#endif
    4245
    4346namespace sc_core {
  • branches/with_autoconf/src/sc_trace.cc

    r1 r8  
    4141#include "bit2string.h"
    4242#include "hex2string.h"
    43 #include "assert.h"
     43#include <cassert>
    4444
    4545#include <list>
    4646#include <stdio.h>
    4747#include <iostream>
     48#ifdef HAVE_CONFIG_H
     49#include "config.h"
     50#endif
    4851
    4952//-----------------------------------------
     
    5255
    5356//-----------------------------------------
    54 #ifdef PAT_TRACE_FORMAT
     57#ifdef CONFIG_PAT_TRACE_FORMAT
    5558
    5659extern "C" {
     
    6265#include <stdio.h>
    6366
    64 #endif // PAT_TRACE_FORMAT
     67#endif // CONFIG_PAT_TRACE_FORMAT
    6568//-----------------------------------------
    6669
     
    164167    {
    165168      sc_trace_file *tf = *ptf;
    166       ASSERT(tf != NULL);
     169      assert(tf != NULL);
    167170                trace (*tf, part);
    168171    }
     
    172175}
    173176
    174 #if PAT_TRACE_FORMAT
     177#ifdef CONFIG_PAT_TRACE_FORMAT
    175178static void
    176179pat_set_value (char *buf, const signal2trace &s)
     
    282285{
    283286}
    284 #endif // PAT_TRACE_FORMAT
     287#endif // CONFIG_PAT_TRACE_FORMAT
    285288
    286289static
     
    413416  else
    414417    vcd_signal_table = (tab_t*) malloc (sizeof (tab_t) * size);
    415 #if DEBUG
     418#ifdef CONFIG_DEBUG
    416419  if (vcd_signal_table == NULL)
    417420  {
     
    485488      vcd_trace_init (tf);
    486489  } else {
    487 #if defined(DEBUG)
     490#if defined(CONFIG_DEBUG)
    488491      if (vcd_signal_table == NULL)
    489492      {
     
    579582&name)
    580583{
    581 #ifdef PAT_TRACE_FORMAT
     584#ifdef CONFIG_PAT_TRACE_FORMAT
    582585        //exemple:
    583586        //DECLAR ("a", ":2", "X", IN, "3  downto 0", "" );
     
    629632#endif
    630633        DECLAR ((char*)(name.c_str ()), ":1", format, dir,(char *) downto.c_str(), "" );
    631 #endif // PAT_TRACE_FORMAT
     634#endif // CONFIG_PAT_TRACE_FORMAT
    632635}
    633636
  • branches/with_autoconf/src/sc_uint.h

    r1 r8  
    2424// ----------------------------------------------------------------------------
    2525
    26 #include"sc_nbdefs.h"
     26#include "sc_nbdefs.h"
    2727
    2828namespace sc_dt {
  • branches/with_autoconf/src/sc_uint_subref_r.cc

    r1 r8  
    3636#include <iostream>
    3737#include "sc_uint.h"
     38#ifdef HAVE_CONFIG_H
     39#include "config.h"
     40#endif
    3841
    3942using namespace std;
  • branches/with_autoconf/src/sc_unsigned.h

    r1 r8  
    1818// ----------------------------------------------------------------------------
    1919
    20 #include"sc_nbdefs.h"
    21 #include"sc_logic.h"
     20#include "sc_nbdefs.h"
     21#include "sc_logic.h"
    2222
    2323
  • branches/with_autoconf/src/sc_vcd_trace.cc

    r1 r8  
    3636
    3737
    38 #include"sc_trace.h"
    39 #include"sc_vcd_trace.h"
    40 #include"sc_ver.h"
    41 #include"internal.h"
    42 #include"assert.h"
     38#include "sc_trace.h"
     39#include "sc_vcd_trace.h"
     40#include "sc_ver.h"
     41#include "internal.h"
     42#include <cassert>
    4343
    44 #include<time.h>
    45 #include<string>
     44#include <time.h>
     45#include <string>
     46#ifdef HAVE_CONFIG_H
     47#include "config.h"
     48#endif
    4649
    4750//-----------------------------------------*/
     
    5861  if (notrace)
    5962    return NULL;
    60   ASSERT(name != NULL);
     63  assert(name != NULL);
    6164        string filename;
    6265        filename = name;
  • branches/with_autoconf/src/sc_ver.cc

    r1 r8  
    3838#include <string>
    3939#include <iostream>
     40#ifdef HAVE_CONFIG_H
     41#include "config.h"
     42#endif
    4043
    4144namespace sc_core {
     
    6063        "\n"
    6164        "         Cycle Accurate System Simulator\n"
    62 #ifdef DEBUG
     65#ifdef CONFIG_DEBUG
    6366  "            DEBUG version\n"
    6467#endif
  • branches/with_autoconf/src/schedulers.cc

    r1 r8  
    3535 */
    3636
    37 #include<iostream>
    38 #include"sc_module.h" // method_process_t
    39 #include"gen_code.h"  // gen_scheduling_code_for_dynamic_link & gen_scheduling_code_for_static_func
    40 #include"internal.h"  // dump_all_graph
    41 #include"graph_cass.h" // makegraph
    42 #include"process_dependency.h" // MakeProcessDependencyList
    43 #include"signal_dependency.h" // MakeSignalDependencyGraph
    44 #include"mouchard_scheduling.h" // MakeMouchardScheduling
    45 #include"graph_signals.h" // makegraph
    46 //#include"module_hierarchy2dot.h"
    47 #include"assert.h"
     37#include <iostream>
     38#include "sc_module.h" // method_process_t
     39#include "gen_code.h"  // gen_scheduling_code_for_dynamic_link & gen_scheduling_code_for_static_func
     40#include "internal.h"  // dump_all_graph
     41#include "graph_cass.h" // makegraph
     42#include "process_dependency.h" // MakeProcessDependencyList
     43#include "signal_dependency.h" // MakeSignalDependencyGraph
     44#include "mouchard_scheduling.h" // MakeMouchardScheduling
     45#include "graph_signals.h" // makegraph
     46//#include "module_hierarchy2dot.h"
     47#include <cassert>
     48#ifdef HAVE_CONFIG_H
     49#include "config.h"
     50#endif
    4851
    4952using namespace std;
     
    9497                         const method_process_t *a2)
    9598{
    96   ASSERT(a1 != NULL);
    97   ASSERT(a2 != NULL);
     99  assert(a1 != NULL);
     100  assert(a2 != NULL);
    98101  sc_module *m1 = a1->module;
    99102  sc_module *m2 = a2->module;
     
    113116    addr1.func = a1->func;
    114117    addr2.func = a2->func;
    115     ASSERT(addr1.addr_ll != addr2.addr_ll);
     118    assert(addr1.addr_ll != addr2.addr_ll);
    116119    if ( sizeof(SC_ENTRY_FUNC) == 4 ) {
    117120        return (addr1.addr_l < addr2.addr_l);
     
    129132                    const method_process_t *a2)
    130133{
    131   ASSERT(a1 != NULL);
    132   ASSERT(a2 != NULL);
     134  assert(a1 != NULL);
     135  assert(a2 != NULL);
    133136  return (a1->module < a2->module);
    134137}
     
    139142                 const method_process_t *a2)
    140143{
    141     ASSERT(a1 != NULL);
    142     ASSERT(a2 != NULL);
     144    assert(a1 != NULL);
     145    assert(a2 != NULL);
    143146    union {
    144147        SC_ENTRY_FUNC func;
     
    236239{
    237240  SignalDependencyGraph *sig_graph = MakeAcyclicSignalDependencyGraph ();
    238   ASSERT(sig_graph != NULL);
     241  assert(sig_graph != NULL);
    239242  // Create the process evaluation list
    240243  ProcessDependencyList* process_list = MakeMouchardScheduling (*sig_graph);
    241   ASSERT(process_list != NULL);
     244  assert(process_list != NULL);
    242245
    243246  if (dump_all_graph)
     
    283286    // Uses port dependancies like Dr. Mouchard.
    284287    ProcessDependencyList* process_list = BuchmannScheduling ();
    285     base_name = gen_scheduling_code_for_dynamic_link (transition_func_list, moore_func_list,*process_list);
    286     gen_scheduling_code_for_static_func (transition_func_list, moore_func_list, *process_list);
     288        if (dynamic_link_of_scheduling_code)
     289                base_name = gen_scheduling_code_for_dynamic_link (transition_func_list, moore_func_list,*process_list);
     290        else
     291                gen_scheduling_code_for_static_func (transition_func_list, moore_func_list, *process_list);
    287292    break;
    288293  }
     
    294299    // and does not use an event-driven scheduler.
    295300    ProcessDependencyList* process_list = MouchardScheduling ();
    296     base_name = gen_scheduling_code_for_dynamic_link(transition_func_list, moore_func_list,*process_list);
    297     gen_scheduling_code_for_static_func (transition_func_list, moore_func_list, *process_list);
     301        if (dynamic_link_of_scheduling_code)
     302                base_name = gen_scheduling_code_for_dynamic_link(transition_func_list, moore_func_list,*process_list);
     303        else
     304                gen_scheduling_code_for_static_func (transition_func_list, moore_func_list, *process_list);
    298305    break;
    299306  }
     
    306313      graph2dot("module_graph", *g);
    307314    strong_component_list_t *strong_list = strong_component (g);
    308     base_name = gen_scheduling_code_for_dynamic_link(transition_func_list, moore_func_list,*strong_list);
    309     gen_scheduling_code_for_quasistatic_func (transition_func_list, moore_func_list, *strong_list);
     315        if (dynamic_link_of_scheduling_code)
     316                base_name = gen_scheduling_code_for_dynamic_link(transition_func_list, moore_func_list,*strong_list);
     317        else
     318                gen_scheduling_code_for_quasistatic_func (transition_func_list, moore_func_list, *strong_list);
    310319    break;
    311320  }
  • branches/with_autoconf/src/schedulers.h

    r1 r8  
    1313#define __SCHEDULERS_H__
    1414
    15 #include"sc_fwd.h"
    16 #include"sc_time.h"
     15#include "sc_fwd.h"
     16#include "sc_time.h"
    1717
    1818namespace sc_core {
  • branches/with_autoconf/src/serialization.cc

    r1 r8  
    3535
    3636
    37 #include<vector>
    38 #include<map>
    39 #include<fstream> // save_module_hierarchy
    40 #include"internal_ext.h" // tab_t
    41 #include"serialization.h"
    42 #include"entity.h"
    43 #include"sc_module.h"
    44 #include"sc_object.h"
    45 #include"hex2string.h"
    46 #include"assert.h"
     37#include <vector>
     38#include <map>
     39#include <fstream> // save_module_hierarchy
     40#include "internal_ext.h" // tab_t
     41#include "serialization.h"
     42#include "entity.h"
     43#include "sc_module.h"
     44#include "sc_object.h"
     45#include "hex2string.h"
     46#include <cassert>
     47#ifdef HAVE_CONFIG_H
     48#include "config.h"
     49#endif
    4750
    4851using namespace std;
     
    8386            int          bit_number)
    8487{
    85   ASSERT(bit_number <= 64);
     88  assert(bit_number <= 64);
    8689  if (bit_number == 1) {
    8790    bool v = *((const bool*) val);
     
    139142                    save_fct_t1      fct)
    140143{
    141   //ASSERT(fct != NULL);
     144  //assert(fct != NULL);
    142145  //sc_module2save_fct_t1::value_type pair(&mod,fct);
    143146  //save_handler_table.insert (pair);
     
    157160    const sc_module *mod = it->first;
    158161    save_fct_t1      fct = it->second;
    159     ASSERT(mod != NULL);
    160 //    ASSERT(fct != NULL);
     162    assert(mod != NULL);
     163//    assert(fct != NULL);
    161164    //o << mod->name () << endl;
    162165    fprintf (o,"module\n%s\n",mod->name ());
     
    184187  file.close ();
    185188  FILE *f = fopen (filename, "a+");
    186   ASSERT(f != NULL);
     189  assert(f != NULL);
    187190  save_modules (f);
    188191  fclose (f);
  • branches/with_autoconf/src/serialization.h

    r1 r8  
    1313#define __SERIALIZATION_H__
    1414
    15 #include"serialization_ext.h"
    16 #include"sc_fwd.h"
     15#include "serialization_ext.h"
     16#include "sc_fwd.h"
    1717
    1818namespace sc_core {
  • branches/with_autoconf/src/serialization_ext.h

    r1 r8  
    3737#define __SERIALIZATION_EXT_H__
    3838
    39 #include<iostream>
    40 #include"sc_fwd.h"
     39#include <iostream>
     40#include "sc_fwd.h"
    4141
    4242namespace sc_core {
  • branches/with_autoconf/src/signal_dependency.cc

    r1 r8  
    4343#include "sc_module.h"
    4444#include "sc_ver_ext.h"
     45#ifdef HAVE_CONFIG_H
     46#include "config.h"
     47#endif
    4548
    4649using namespace std;
  • branches/with_autoconf/src/simplify_string.cc

    r1 r8  
    3535
    3636#include "simplify_string.h"
     37#ifdef HAVE_CONFIG_H
     38#include "config.h"
     39#endif
    3740
    3841using namespace std;
  • branches/with_autoconf/src/systemc

    r4 r8  
    2929#include"sc_vcd_trace.h"
    3030#include"sc_pat_trace.h"
    31 #include"endianness.h"
    3231
    3332#endif
Note: See TracChangeset for help on using the changeset viewer.