2008-06-10 01:25:10 +00:00
|
|
|
|
// -*- C++ -*-
|
2006-08-26 11:35:28 +00:00
|
|
|
|
//*************************************************************************
|
|
|
|
|
// DESCRIPTION: Verilator: Preprocessing wrapper program
|
|
|
|
|
//
|
2008-04-25 12:14:27 +00:00
|
|
|
|
// Code available from: http://www.veripool.org/verilator
|
2006-08-26 11:35:28 +00:00
|
|
|
|
//
|
|
|
|
|
// AUTHORS: Wilson Snyder with Paul Wasson, Duane Gabli
|
|
|
|
|
//
|
|
|
|
|
//*************************************************************************
|
|
|
|
|
//
|
2011-01-01 23:21:19 +00:00
|
|
|
|
// Copyright 2004-2011 by Wilson Snyder. This program is free software; you can
|
2006-08-26 11:35:28 +00:00
|
|
|
|
// redistribute it and/or modify it under the terms of either the GNU
|
2009-05-04 21:07:57 +00:00
|
|
|
|
// Lesser General Public License Version 3 or the Perl Artistic License
|
|
|
|
|
// Version 2.0.
|
2006-08-26 11:35:28 +00:00
|
|
|
|
//
|
|
|
|
|
// Verilator is distributed in the hope that it will be useful,
|
|
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
|
// GNU General Public License for more details.
|
|
|
|
|
//
|
|
|
|
|
//*************************************************************************
|
|
|
|
|
|
|
|
|
|
#ifndef _V3PRESHELL_H_
|
|
|
|
|
#define _V3PRESHELL_H_ 1
|
|
|
|
|
|
2006-12-18 19:20:45 +00:00
|
|
|
|
#include "config_build.h"
|
|
|
|
|
#include "verilatedos.h"
|
2006-08-26 11:35:28 +00:00
|
|
|
|
#include "V3Error.h"
|
|
|
|
|
|
2009-10-31 14:08:38 +00:00
|
|
|
|
class V3ParseImp;
|
2010-01-20 12:15:51 +00:00
|
|
|
|
class V3InFilter;
|
2008-01-31 14:49:27 +00:00
|
|
|
|
|
2006-08-26 11:35:28 +00:00
|
|
|
|
//============================================================================
|
|
|
|
|
|
|
|
|
|
class V3PreShell {
|
|
|
|
|
// Static class for calling preprocessor
|
|
|
|
|
public:
|
|
|
|
|
static void boot(char** env);
|
2011-10-28 00:56:38 +00:00
|
|
|
|
static bool preproc(FileLine* fileline, const string& module, V3InFilter* filterp,
|
|
|
|
|
V3ParseImp* parsep, const string& errmsg);
|
2006-08-26 11:35:28 +00:00
|
|
|
|
static void preprocInclude(FileLine* fileline, const string& module);
|
|
|
|
|
static string dependFiles() { return ""; } // Perl only
|
2009-12-21 03:26:48 +00:00
|
|
|
|
static void defineCmdLine(const string& name, const string& value);
|
2006-08-26 11:35:28 +00:00
|
|
|
|
static void undef(const string& name);
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
#endif // Guard
|