File: example_dist.rst

package info (click to toggle)
verilator 5.046-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 69,920 kB
  • sloc: cpp: 157,707; python: 23,195; ansic: 10,999; yacc: 6,184; lex: 2,013; makefile: 1,434; sh: 620; perl: 302
file content (52 lines) | stat: -rw-r--r-- 1,365 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
.. SPDX-FileCopyrightText: 2003-2026 Wilson Snyder
.. SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0

.. _examples in the distribution:

Examples in the Distribution
============================

See the ``examples/`` directory that is part of the distribution, and is
installed (in an OS-specific place, often in e.g.
``/usr/local/share/verilator/examples``). These examples include:

examples/make_hello_binary
   Example GNU-make simple Verilog->binary conversion

examples/make_hello_c
   Example GNU-make simple Verilog->C++ conversion

examples/make_hello_sc
   Example GNU-make simple Verilog->SystemC conversion

examples/make_tracing_c
   Example GNU-make Verilog->C++ with tracing

examples/make_tracing_sc
   Example GNU-make Verilog->SystemC with tracing

examples/make_protect_lib
   Example using --protect-lib

examples/cmake_hello_c
   Example building make_hello_c with CMake

examples/cmake_hello_sc
   Example building make_hello_sc with CMake

examples/cmake_tracing_c
   Example building make_tracing_c with CMake

examples/cmake_tracing_sc
   Example building make_tracing_sc with CMake

examples/cmake_protect_lib
   Example building make_protect_lib with CMake

To run an example copy the example to a new directory and run it.

.. code-block:: bash

   cp -rp {path_to}/examples/make_hello_c make_hello_c
   cd make_hello_c
   make