Browse Source

New upstream version 0.35+git20180503+dfsg

tags/upstream/0.35+git20180503+dfsg^0
Andreas Bombe 1 year ago
parent
commit
3be9bced3c
176 changed files with 5908 additions and 4365 deletions
  1. 1
    3
      .gitignore
  2. 68
    48
      .travis.yml
  3. 3
    0
      CONTRIBUTING
  4. 0
    340
      COPYING
  5. 3
    433
      COPYING.md
  6. 28
    13
      Makefile.in
  7. 4
    1
      NEWS.md
  8. 10
    7
      README.md
  9. 29
    8
      configure
  10. 144
    0
      dist/linux/build.sh
  11. 0
    193
      dist/linux/buildtest.sh
  12. 24
    0
      dist/linux/create.sh
  13. 32
    0
      dist/linux/deploy2dockerhub.sh
  14. 0
    5
      dist/linux/docker/build-fedora26+mcode
  15. 0
    7
      dist/linux/docker/build-stretch+mcode
  16. 0
    7
      dist/linux/docker/build-stretch+mcode+gpl
  17. 0
    7
      dist/linux/docker/build-ubuntu14+llvm-3.8
  18. 0
    7
      dist/linux/docker/build-ubuntu14+mcode
  19. 11
    0
      dist/linux/docker/build/buster
  20. 12
    0
      dist/linux/docker/build/fedora26
  21. 11
    0
      dist/linux/docker/build/stretch
  22. 16
    0
      dist/linux/docker/build/ubuntu14
  23. 16
    0
      dist/linux/docker/build/ubuntu16
  24. 16
    0
      dist/linux/docker/build/ubuntu18
  25. 10
    0
      dist/linux/docker/run/buster
  26. 12
    0
      dist/linux/docker/run/fedora26
  27. 10
    0
      dist/linux/docker/run/stretch
  28. 16
    0
      dist/linux/docker/run/ubuntu14
  29. 16
    0
      dist/linux/docker/run/ubuntu16
  30. 16
    0
      dist/linux/docker/run/ubuntu18
  31. 114
    0
      dist/linux/test.sh
  32. 73
    41
      dist/linux/travis-ci.sh
  33. 13
    0
      dist/linux/travis-enc-dockerhub.sh
  34. 2
    1
      dist/linux/travis-utils.sh
  35. 5
    2
      dist/windows/appveyor/build.ps1
  36. 2
    5
      dist/windows/compile-ghdl.ps1
  37. 12
    18
      dist/windows/compile-libraries.ps1
  38. 37
    34
      dist/windows/targets.psm1
  39. 427
    0
      doc/COPYING_DOC.md
  40. 3
    0
      doc/about.rst
  41. 2
    2
      doc/appendix/Meta.rst
  42. 11
    1
      doc/building/Building.rst
  43. 1
    1
      doc/building/Directories.rst
  44. 35
    49
      doc/building/PrecompileVendorPrimitives.rst
  45. 34
    16
      doc/building/gcc/GNULinux-GNAT.rst
  46. 14
    14
      doc/building/gcc/Windows-MinGW-GNAT.rst
  47. 35
    4
      doc/building/gcc/index.rst
  48. 14
    17
      doc/building/llvm/GNULinux-GNAT.rst
  49. 9
    9
      doc/building/llvm/Windows-MinGW-GNAT.rst
  50. 3
    11
      doc/building/llvm/index.rst
  51. 9
    9
      doc/building/mcode/GNULinux-GNAT.rst
  52. 2
    2
      doc/building/mcode/Windows-GNATGPL.rst
  53. 9
    9
      doc/building/mcode/Windows-MinGW-GNAT.rst
  54. 3
    3
      doc/building/mcode/index.rst
  55. 12
    12
      doc/conf.py
  56. 6
    6
      doc/contribute.rst
  57. 73
    53
      doc/getting/Releases.rst
  58. 453
    456
      doc/ghdl.texi
  59. 14
    2
      doc/index.rst
  60. 22
    25
      doc/shields.inc
  61. 13
    15
      doc/shieldswho.inc
  62. 6
    10
      doc/using/Simulation.rst
  63. 37
    40
      libraries/Makefile.inc
  64. 28
    19
      libraries/vendors/README.md
  65. 2
    2
      libraries/vendors/compile-altera.ps1
  66. 2
    2
      libraries/vendors/compile-intel.ps1
  67. 2
    2
      libraries/vendors/compile-lattice.ps1
  68. 0
    250
      libraries/vendors/compile-vunit.sh
  69. 2
    2
      libraries/vendors/compile-xilinx-ise.ps1
  70. 2
    2
      libraries/vendors/compile-xilinx-vivado.ps1
  71. 1
    1
      libraries/vendors/compile-xilinx-vivado.sh
  72. 3
    8
      libraries/vendors/config.psm1
  73. 3
    6
      libraries/vendors/config.sh
  74. 49
    0
      setup.py.in
  75. 1
    1
      src/bug.adb
  76. 1
    1
      src/dyn_tables.ads
  77. 32
    30
      src/files_map.adb
  78. 1
    3
      src/files_map.ads
  79. 1
    2
      src/ghdldrv/default_paths.ads.in
  80. 5
    0
      src/ghdldrv/ghdlcomp.adb
  81. 6
    9
      src/ghdldrv/ghdldrv.adb
  82. 32
    34
      src/ghdldrv/ghdllocal.adb
  83. 1
    1
      src/ghdldrv/ghdlmain.adb
  84. 7
    18
      src/ghdldrv/ghdlprint.adb
  85. 7
    6
      src/ghdldrv/ghdlrun.adb
  86. 2
    0
      src/ghdldrv/ghdlxml.adb
  87. 20
    9
      src/grt/grt-disp_signals.adb
  88. 3
    0
      src/grt/grt-disp_signals.ads
  89. 3
    1
      src/grt/grt-errors.ads
  90. 16
    3
      src/grt/grt-lib.adb
  91. 9
    4
      src/grt/grt-lib.ads
  92. 32
    10
      src/grt/grt-main.adb
  93. 11
    0
      src/grt/grt-main.ads
  94. 56
    46
      src/grt/grt-options.adb
  95. 5
    0
      src/grt/grt-options.ads
  96. 54
    47
      src/grt/grt-processes.adb
  97. 14
    1
      src/grt/grt-processes.ads
  98. 236
    212
      src/grt/grt-signals.adb
  99. 15
    10
      src/grt/grt-signals.ads
  100. 4
    2
      src/grt/grt-stats.adb
  101. 6
    8
      src/grt/grt-vpi.adb
  102. 46
    51
      src/libraries.adb
  103. 0
    21
      src/name_table.adb
  104. 0
    18
      src/name_table.ads
  105. 6
    6
      src/options.adb
  106. 4
    1
      src/ortho/mcode/ortho_ident.adb
  107. 11
    2
      src/std_names.adb
  108. 42
    31
      src/std_names.ads
  109. 1
    7
      src/types.ads
  110. 1
    1
      src/version.in
  111. 9
    7
      src/vhdl/canon.adb
  112. 8
    3
      src/vhdl/disp_tree.adb
  113. 5
    1
      src/vhdl/disp_vhdl.adb
  114. 111
    29
      src/vhdl/elocations.adb
  115. 32
    1
      src/vhdl/elocations.adb.in
  116. 65
    35
      src/vhdl/elocations.ads
  117. 67
    2
      src/vhdl/elocations_meta.adb
  118. 7
    1
      src/vhdl/elocations_meta.ads
  119. 6
    14
      src/vhdl/errorout.adb
  120. 2
    1
      src/vhdl/errorout.ads
  121. 55
    57
      src/vhdl/evaluation.adb
  122. 3
    4
      src/vhdl/evaluation.ads
  123. 0
    7
      src/vhdl/ieee-vital_timing.adb
  124. 25
    2
      src/vhdl/iirs.adb
  125. 5
    0
      src/vhdl/iirs.adb.in
  126. 61
    24
      src/vhdl/iirs.ads
  127. 6
    1
      src/vhdl/iirs_utils.adb
  128. 266
    206
      src/vhdl/nodes_meta.adb
  129. 8
    0
      src/vhdl/nodes_meta.ads
  130. 135
    61
      src/vhdl/parse.adb
  131. 3
    10
      src/vhdl/python/libghdl/__init__.py
  132. 1
    0
      src/vhdl/python/libghdl/thin.py
  133. 129
    1
      src/vhdl/python/libghdl/thinutils.py
  134. 64
    40
      src/vhdl/scanner.adb
  135. 11
    1
      src/vhdl/scanner.ads
  136. 11
    9
      src/vhdl/sem.adb
  137. 2
    2
      src/vhdl/sem_assocs.adb
  138. 37
    23
      src/vhdl/sem_decls.adb
  139. 13
    5
      src/vhdl/sem_expr.adb
  140. 37
    11
      src/vhdl/sem_inst.adb
  141. 46
    12
      src/vhdl/sem_names.adb
  142. 3
    2
      src/vhdl/sem_psl.adb
  143. 2
    4
      src/vhdl/sem_scopes.adb
  144. 10
    0
      src/vhdl/sem_scopes.ads
  145. 33
    3
      src/vhdl/sem_specs.adb
  146. 4
    0
      src/vhdl/sem_stmts.adb
  147. 41
    8
      src/vhdl/sem_types.adb
  148. 35
    3
      src/vhdl/simulate/simul-annotations.adb
  149. 185
    49
      src/vhdl/simulate/simul-debugger.adb
  150. 7
    0
      src/vhdl/simulate/simul-debugger.ads
  151. 38
    22
      src/vhdl/simulate/simul-elaboration.adb
  152. 22
    14
      src/vhdl/simulate/simul-environments.adb
  153. 12
    6
      src/vhdl/simulate/simul-environments.ads
  154. 206
    146
      src/vhdl/simulate/simul-execution.adb
  155. 15
    4
      src/vhdl/simulate/simul-execution.ads
  156. 89
    34
      src/vhdl/simulate/simul-simulation-main.adb
  157. 0
    1
      src/vhdl/std_package.adb
  158. 1
    1
      src/vhdl/translate/ortho_front.adb
  159. 0
    4
      src/vhdl/translate/trans-chap12.adb
  160. 18
    6
      src/vhdl/translate/trans-chap2.adb
  161. 470
    168
      src/vhdl/translate/trans-chap3.adb
  162. 40
    7
      src/vhdl/translate/trans-chap3.ads
  163. 87
    61
      src/vhdl/translate/trans-chap4.adb
  164. 4
    3
      src/vhdl/translate/trans-chap5.adb
  165. 43
    23
      src/vhdl/translate/trans-chap6.adb
  166. 48
    58
      src/vhdl/translate/trans-chap7.adb
  167. 12
    12
      src/vhdl/translate/trans-chap8.adb
  168. 39
    23
      src/vhdl/translate/trans-chap9.adb
  169. 11
    8
      src/vhdl/translate/trans-foreach_non_composite.adb
  170. 5
    10
      src/vhdl/translate/trans-helpers2.adb
  171. 26
    28
      src/vhdl/translate/trans-rtis.adb
  172. 199
    173
      src/vhdl/translate/trans.adb
  173. 91
    23
      src/vhdl/translate/trans.ads
  174. 2
    1
      src/vhdl/translate/trans_decls.ads
  175. 78
    49
      src/vhdl/translate/translation.adb
  176. 4
    5
      src/vhdl/translate/translation.ads

+ 1
- 3
.gitignore View File

@@ -12,9 +12,7 @@ b~*.ad?
testsuite/get_entities

# Generated files on windows.
build/
dist/mcode/build/
dist/mcode/lib/
/build/

# Generated directories on Linux
lib/

+ 68
- 48
.travis.yml View File

@@ -1,62 +1,82 @@
branches:
except:
- appveyor
- appveyor

language: c
os: linux
dist: trusty
sudo: required
services: docker
language: minimal
install: skip
script: "./dist/linux/travis-ci.sh"

matrix:
include:
- os: linux
dist: trusty
sudo: required
services: docker
env: IMAGE=stretch+mcode
- os: linux
dist: trusty
sudo: required
services: docker
env: IMAGE=stretch+mcode+gpl
- os: linux
dist: trusty
sudo: required
services: docker
env: IMAGE=ubuntu14+mcode
- os: linux
dist: trusty
sudo: required
services: docker
env: IMAGE=ubuntu14+llvm-3.8
- os: linux
dist: trusty
sudo: required
services: docker
env: IMAGE=fedora26+mcode
- os: osx
osx_image: xcode7.3
env: IMAGE=macosx+mcode
cache:
directories:
- gnat

install: true

script:
- ./dist/linux/travis-ci.sh

before_deploy:
- "echo ready to deploy"
addons:
apt:
packages:
- docker-ce

deploy:
- provider: releases
- &deploy-docker
provider: script
skip_cleanup: true
script: ./dist/linux/deploy2dockerhub.sh "$IMAGE" "$TRAVIS_COMMIT_MESSAGE"
on:
repo: 1138-4EB/ghdl
branch: master
- &deploy-releases
provider: releases
skip_cleanup: true
api_key:
secure: ji6LXOmD5V2N+ELHZr4oJsmxPhedk+8W6jfCqQdEbewQ42N+fKOq3lgqJni7ZdfpZaulB9OHPTApv3bwOjXjtN9rfBGmq//U9CwvzHmUeomdQv6WQOVevaWSXl3DNL9fk3yKynyFrsv4pvr45L8GIjaHLggKcYhNFPJ2rrnJlDoFT9MqQNpmP7Bg/LnwVQiv+ZDPkLlMWQzrXzLamdQILARPQka+kCdXl/sHH6OKvLgRvu9yvyXYSSfbyAHP+THISS5gDciizSBeWGlU75kgj/N+mkV+8NvtTTfEIgG8y49WJz6aBooTmRzk/jZW1dKMbDR6c5bpTmRvMZSzeSBuAR6WLhr6HevgCPi/1fX1y3pkVSrgBUF5KcxPgWCZp0I05QjaJOdvQDl1hH4TlVwpT18lM2+cWrui9fS7spnk/AuNKX882C5QWWRy28lIPasCVnwfeKX8a9KAwY9OqVOenoLC1yx7NJOGfH1bjuSYYxyR4XgLiGTHKALAuknCyD9QL0o378IwqxHMcsN0Gsd+GndMu0/b8GvSqfzDpV1XknqabQFwkZLs+Yydw0snfBUzXw9TfOk78IiPYEgXAxsQKBAkK7qvO36HIxLlSQXglXU1D4IDtQYDUel6vKll4pgu0WMxStQCbj51yDVJKvRhzwiBNC6Pwgzt2JTrpwM/T/U=
file: "ghdl-*.tgz"
file_glob: true
on:
repo: tgingold/ghdl
tags: true
repo: ghdl/ghdl
all_branches: true
tags: true

# For each linux build, a different job/instance (with the constraints
# above) is executed in parallel in stage 'test'.
env:
matrix:
- IMAGE=stretch+mcode
- IMAGE=stretch+mcode+gpl
# - IMAGE=buster+mcode
# - IMAGE=buster+mcode+gpl
- IMAGE=ubuntu14+mcode
- IMAGE=ubuntu14+llvm-3.8
# - IMAGE=ubuntu16+mcode
# - IMAGE=ubuntu16+llvm-3.9
# - IMAGE=ubuntu18+mcode
# - IMAGE=ubuntu18+llvm-5.0
- IMAGE=fedora26+mcode
# - IMAGE=fedora26+llvm
global:
- secure: "MZHtYkWdYK+SeYzJvWD8I0tbkdHGjmWyNDn70a2RrNYFu363Zt51ZvksEtkjrS7kdje6l6VPfLjilX5UtywIM1Mg6nt/rsw4p62+bGhMyhfXiqS3eqEfH2sThjosy773X8iotm2sW0ax0oHX07ZLcuTbZ+TK2cMGarZ+LzNT8IiMaeaWu4W7aE5LRxSmVRwcACUOa3NiC7GY/qC7vU2C8QNdXSlU3fSp17K5eccrkkBuiEhRTsdr3ZIhjOjrYzqHKWC3a0uHn/fJsbepsVM6FGt+zAwo0VqdXXCE2ts8EOATvFgEaCGxUgfGd/yvNsAG7sjF3nweR9Z11dpMbBE+TjxlLCXQ31v1Oj7pH6vcgjCYV69cZiLbsDhxTJFQ08qbm3xK8dmTUXFy1scrMSd8D/Q3Uf0LjHkH5Q5dL8TOyqejs57fUTIBtBUpCTvvGOErdZQAOWJc93sC9RQB7BuCDR2yR7rPTJr4KUwspe1uScA/H9cQS2p42SeJ4+Yyjtwod3IQWjr6+/pdNPoImleOP0dXSDCXpAIsbv6TR9curS3geLJuTmu5UnLzbURDr7Whtop3lCPbiN0H9jThSuyIxWUI+6JDGDG89RXbCyZvGz97sIShYstWg0U0xLWmw9IDez2HtK5VKuTT/hE7gDicZ0erN6r1dlix3SpuCtH1MlA=" #U
- secure: "kIA09oCHzoHMK4LsfwcaVaMuoAFpd1M+M8tW3b9Rvki/hEB3y46edlb88lWVM7RgkNoCaIPwAZD7Wf3Xiq9Y7wWmqRsWQNRaorC0xke5SuyMwCSQSNo9S5jAu9SM5uxENCH9yucJl/vm2juYitJCHyYYMb4x17fy3sHKULNJ+JBqnrgOuTBYM1JOIkJVO1P5LqEXmqTtr6KgQgiTMtlvnM7hxjapgoyM3J1376f+Kfky0hUoDD7LFLXu8yQCn5Fnar8wR3czK6Qknafmckt5yWJxGOZobMDfKwOdA0fpU+XiArNQ/1NM80fGXq4YOGK5ycVQkO2ACxDqHYfQRYLlIfrUGp75BoXWwN6O1GoOrFcF7ZIoSaLoK3hZdvzRFT7dpUQFlosn00Y7VzqbosQM5QS5TBBqO+DExnkb399OpXI7o0lrlr232kjAeYqEb6N1n3M9BpiNW9Je4plJa/RDKwYsnC8Qak4G08PVTe6V711W1UtqMPd6efWFYTNvRW9tjO3v1lFGaGJ99ABP0AYLIDYWV3zfgvp0UzQOKFdWJj7dMQxdLMQ/bIETKn8P7NFjOWic4pgtp3zekZCL27blhc0fyHm62HUiVLT+VGFOI/nyclzBIZStSVuxPj2LvmAIiMnUNmWwds1ZqIZ21eiNykkn+k52ddTRHXIh2fhvWfg=" #P

after_deploy:
- "echo deployed"
stages:
- create ghdl/build and ghdl/run images
- test

jobs:
include:
# A single job is described in its own stage, to create and push ghdl/build and ghdl/run images.
- stage: create ghdl/build and ghdl/run images
env: IMAGE=""
script: if echo "$TRAVIS_COMMIT_MESSAGE" | grep -F -q "[ci images]"; then ./dist/linux/create.sh; fi;
deploy:
- <<: *deploy-docker
# A single additional job is described in stage 'test' for the macos build.
# The constraints above are used, except explicitly overriden.
- stage: test
os: osx
language: c
osx_image: xcode7.3
install: true
cache:
directories:
- gnat
env: IMAGE=macosx+mcode
deploy:
- <<: *deploy-releases

+ 3
- 0
CONTRIBUTING View File

@@ -0,0 +1,3 @@
First off, thanks for taking the time to contribute!

Either to [report a bug](http://ghdl.readthedocs.io/en/doc-gcc/contribute.html#reporting-bugs), [request enhancements](http://ghdl.readthedocs.io/en/doc-gcc/contribute.html#requesting-enhancements) or to [contribute modifications](http://ghdl.readthedocs.io/en/doc-gcc/contribute.html#fork-modify-and-pull-request), please read [Contributing](http://ghdl.readthedocs.io/en/doc-gcc/contribute.html) in the [Docs](http://ghdl.readthedocs.io/en/doc-gcc/index.html).

+ 0
- 340
COPYING View File

@@ -1,340 +0,0 @@
GNU GENERAL PUBLIC LICENSE
Version 2, June 1991

Copyright (C) 1989, 1991 Free Software Foundation, Inc.
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.

Preamble

The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users. This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it. (Some other Free Software Foundation software is covered by
the GNU Library General Public License instead.) You can apply it to
your programs, too.

When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.

To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.

For example, if you distribute copies of such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have. You must make sure that they, too, receive or can get the
source code. And you must show them these terms so they know their
rights.

We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.

Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software. If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.

Finally, any free program is threatened constantly by software
patents. We wish to avoid the danger that redistributors of a free
program will individually obtain patent licenses, in effect making the
program proprietary. To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.

The precise terms and conditions for copying, distribution and
modification follow.
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION

0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License. The "Program", below,
refers to any such program or work, and a "work based on the Program"
means either the Program or any derivative work under copyright law:
that is to say, a work containing the Program or a portion of it,
either verbatim or with modifications and/or translated into another
language. (Hereinafter, translation is included without limitation in
the term "modification".) Each licensee is addressed as "you".

Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running the Program is not restricted, and the output from the Program
is covered only if its contents constitute a work based on the
Program (independent of having been made by running the Program).
Whether that is true depends on what the Program does.

1. You may copy and distribute verbatim copies of the Program's
source code as you receive it, in any medium, provided that you
conspicuously and appropriately publish on each copy an appropriate
copyright notice and disclaimer of warranty; keep intact all the
notices that refer to this License and to the absence of any warranty;
and give any other recipients of the Program a copy of this License
along with the Program.

You may charge a fee for the physical act of transferring a copy, and
you may at your option offer warranty protection in exchange for a fee.

2. You may modify your copy or copies of the Program or any portion
of it, thus forming a work based on the Program, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:

a) You must cause the modified files to carry prominent notices
stating that you changed the files and the date of any change.

b) You must cause any work that you distribute or publish, that in
whole or in part contains or is derived from the Program or any
part thereof, to be licensed as a whole at no charge to all third
parties under the terms of this License.

c) If the modified program normally reads commands interactively
when run, you must cause it, when started running for such
interactive use in the most ordinary way, to print or display an
announcement including an appropriate copyright notice and a
notice that there is no warranty (or else, saying that you provide
a warranty) and that users may redistribute the program under
these conditions, and telling the user how to view a copy of this
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not required to print an announcement.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.

Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Program.

In addition, mere aggregation of another work not based on the Program
with the Program (or with a work based on the Program) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.

3. You may copy and distribute the Program (or a work based on it,
under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you also do one of the following:

a) Accompany it with the complete corresponding machine-readable
source code, which must be distributed under the terms of Sections
1 and 2 above on a medium customarily used for software interchange; or,

b) Accompany it with a written offer, valid for at least three
years, to give any third party, for a charge no more than your
cost of physically performing source distribution, a complete
machine-readable copy of the corresponding source code, to be
distributed under the terms of Sections 1 and 2 above on a medium
customarily used for software interchange; or,

c) Accompany it with the information you received as to the offer
to distribute corresponding source code. (This alternative is
allowed only for noncommercial distribution and only if you
received the program in object code or executable form with such
an offer, in accord with Subsection b above.)

The source code for a work means the preferred form of the work for
making modifications to it. For an executable work, complete source
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable. However, as a
special exception, the source code distributed need not include
anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the
operating system on which the executable runs, unless that component
itself accompanies the executable.

If distribution of executable or object code is made by offering
access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.
4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License. Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
void, and will automatically terminate your rights under this License.
However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.

5. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Program or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Program (or any work based on the
Program), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Program or works based on it.

6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the
original licensor to copy, distribute or modify the Program subject to
these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.

7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Program at all. For example, if a patent
license would not permit royalty-free redistribution of the Program by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.

If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply and the section as a whole is intended to apply in other
circumstances.

It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system, which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.

This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
may add an explicit geographical distribution limitation excluding
those countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.

9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.

Each version is given a distinguishing version number. If the Program
specifies a version number of this License which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation. If the Program does not specify a version number of
this License, you may choose any version ever published by the Free Software
Foundation.

10. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission. For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this. Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.

NO WARRANTY

11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.

12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.

END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs

If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.

To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.

<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.

This program 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.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA


Also add information on how to contact you by electronic and paper mail.

If the program is interactive, make it output a short notice like this
when it starts in an interactive mode:

Gnomovision version 69, Copyright (C) year name of author
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.

The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, the commands you use may
be called something other than `show w' and `show c'; they could even be
mouse-clicks or menu items--whatever suits your program.

You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if
necessary. Here is a sample; alter the names:

Yoyodyne, Inc., hereby disclaims all copyright interest in the program
`Gnomovision' (which makes passes at compilers) written by James Hacker.

<signature of Ty Coon>, 1 April 1989
Ty Coon, President of Vice

This General Public License does not permit incorporating your program into
proprietary programs. If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library. If this is what you want to do, use the GNU Library General
Public License instead of this License.

+ 3
- 433
COPYING.md View File

@@ -1,4 +1,4 @@
## GNU GENERAL PUBLIC LICENSE
### GNU GENERAL PUBLIC LICENSE

Version 2, June 1991

@@ -357,435 +357,5 @@ into proprietary programs. If your program is a subroutine library,
you may consider it more useful to permit linking proprietary
applications with the library. If this is what you want to do, use the
[GNU Lesser General Public
License](http://www.gnu.org/licenses/lgpl.html) instead of this

---

License.Attribution-ShareAlike 4.0 International

=======================================================================

Creative Commons Corporation ("Creative Commons") is not a law firm and
does not provide legal services or legal advice. Distribution of
Creative Commons public licenses does not create a lawyer-client or
other relationship. Creative Commons makes its licenses and related
information available on an "as-is" basis. Creative Commons gives no
warranties regarding its licenses, any material licensed under their
terms and conditions, or any related information. Creative Commons
disclaims all liability for damages resulting from their use to the
fullest extent possible.

Using Creative Commons Public Licenses

Creative Commons public licenses provide a standard set of terms and
conditions that creators and other rights holders may use to share
original works of authorship and other material subject to copyright
and certain other rights specified in the public license below. The
following considerations are for informational purposes only, are not
exhaustive, and do not form part of our licenses.

Considerations for licensors: Our public licenses are
intended for use by those authorized to give the public
permission to use material in ways otherwise restricted by
copyright and certain other rights. Our licenses are
irrevocable. Licensors should read and understand the terms
and conditions of the license they choose before applying it.
Licensors should also secure all rights necessary before
applying our licenses so that the public can reuse the
material as expected. Licensors should clearly mark any
material not subject to the license. This includes other CC-
licensed material, or material used under an exception or
limitation to copyright. More considerations for licensors:
wiki.creativecommons.org/Considerations_for_licensors

Considerations for the public: By using one of our public
licenses, a licensor grants the public permission to use the
licensed material under specified terms and conditions. If
the licensor's permission is not necessary for any reason--for
example, because of any applicable exception or limitation to
copyright--then that use is not regulated by the license. Our
licenses grant only permissions under copyright and certain
other rights that a licensor has authority to grant. Use of
the licensed material may still be restricted for other
reasons, including because others have copyright or other
rights in the material. A licensor may make special requests,
such as asking that all changes be marked or described.
Although not required by our licenses, you are encouraged to
respect those requests where reasonable. More_considerations
for the public:
wiki.creativecommons.org/Considerations_for_licensees

=======================================================================

Creative Commons Attribution-ShareAlike 4.0 International Public
License

By exercising the Licensed Rights (defined below), You accept and agree
to be bound by the terms and conditions of this Creative Commons
Attribution-ShareAlike 4.0 International Public License ("Public
License"). To the extent this Public License may be interpreted as a
contract, You are granted the Licensed Rights in consideration of Your
acceptance of these terms and conditions, and the Licensor grants You
such rights in consideration of benefits the Licensor receives from
making the Licensed Material available under these terms and
conditions.


Section 1 -- Definitions.

a. Adapted Material means material subject to Copyright and Similar
Rights that is derived from or based upon the Licensed Material
and in which the Licensed Material is translated, altered,
arranged, transformed, or otherwise modified in a manner requiring
permission under the Copyright and Similar Rights held by the
Licensor. For purposes of this Public License, where the Licensed
Material is a musical work, performance, or sound recording,
Adapted Material is always produced where the Licensed Material is
synched in timed relation with a moving image.

b. Adapter's License means the license You apply to Your Copyright
and Similar Rights in Your contributions to Adapted Material in
accordance with the terms and conditions of this Public License.

c. BY-SA Compatible License means a license listed at
creativecommons.org/compatiblelicenses, approved by Creative
Commons as essentially the equivalent of this Public License.

d. Copyright and Similar Rights means copyright and/or similar rights
closely related to copyright including, without limitation,
performance, broadcast, sound recording, and Sui Generis Database
Rights, without regard to how the rights are labeled or
categorized. For purposes of this Public License, the rights
specified in Section 2(b)(1)-(2) are not Copyright and Similar
Rights.

e. Effective Technological Measures means those measures that, in the
absence of proper authority, may not be circumvented under laws
fulfilling obligations under Article 11 of the WIPO Copyright
Treaty adopted on December 20, 1996, and/or similar international
agreements.

f. Exceptions and Limitations means fair use, fair dealing, and/or
any other exception or limitation to Copyright and Similar Rights
that applies to Your use of the Licensed Material.

g. License Elements means the license attributes listed in the name
of a Creative Commons Public License. The License Elements of this
Public License are Attribution and ShareAlike.

h. Licensed Material means the artistic or literary work, database,
or other material to which the Licensor applied this Public
License.

i. Licensed Rights means the rights granted to You subject to the
terms and conditions of this Public License, which are limited to
all Copyright and Similar Rights that apply to Your use of the
Licensed Material and that the Licensor has authority to license.

j. Licensor means the individual(s) or entity(ies) granting rights
under this Public License.

k. Share means to provide material to the public by any means or
process that requires permission under the Licensed Rights, such
as reproduction, public display, public performance, distribution,
dissemination, communication, or importation, and to make material
available to the public including in ways that members of the
public may access the material from a place and at a time
individually chosen by them.

l. Sui Generis Database Rights means rights other than copyright
resulting from Directive 96/9/EC of the European Parliament and of
the Council of 11 March 1996 on the legal protection of databases,
as amended and/or succeeded, as well as other essentially
equivalent rights anywhere in the world.

m. You means the individual or entity exercising the Licensed Rights
under this Public License. Your has a corresponding meaning.


Section 2 -- Scope.

a. License grant.

1. Subject to the terms and conditions of this Public License,
the Licensor hereby grants You a worldwide, royalty-free,
non-sublicensable, non-exclusive, irrevocable license to
exercise the Licensed Rights in the Licensed Material to:

a. reproduce and Share the Licensed Material, in whole or
in part; and

b. produce, reproduce, and Share Adapted Material.

2. Exceptions and Limitations. For the avoidance of doubt, where
Exceptions and Limitations apply to Your use, this Public
License does not apply, and You do not need to comply with
its terms and conditions.

3. Term. The term of this Public License is specified in Section
6(a).

4. Media and formats; technical modifications allowed. The
Licensor authorizes You to exercise the Licensed Rights in
all media and formats whether now known or hereafter created,
and to make technical modifications necessary to do so. The
Licensor waives and/or agrees not to assert any right or
authority to forbid You from making technical modifications
necessary to exercise the Licensed Rights, including
technical modifications necessary to circumvent Effective
Technological Measures. For purposes of this Public License,
simply making modifications authorized by this Section 2(a)
(4) never produces Adapted Material.

5. Downstream recipients.

a. Offer from the Licensor -- Licensed Material. Every
recipient of the Licensed Material automatically
receives an offer from the Licensor to exercise the
Licensed Rights under the terms and conditions of this
Public License.

b. Additional offer from the Licensor -- Adapted Material.
Every recipient of Adapted Material from You
automatically receives an offer from the Licensor to
exercise the Licensed Rights in the Adapted Material
under the conditions of the Adapter's License You apply.

c. No downstream restrictions. You may not offer or impose
any additional or different terms or conditions on, or
apply any Effective Technological Measures to, the
Licensed Material if doing so restricts exercise of the
Licensed Rights by any recipient of the Licensed
Material.

6. No endorsement. Nothing in this Public License constitutes or
may be construed as permission to assert or imply that You
are, or that Your use of the Licensed Material is, connected
with, or sponsored, endorsed, or granted official status by,
the Licensor or others designated to receive attribution as
provided in Section 3(a)(1)(A)(i).

b. Other rights.

1. Moral rights, such as the right of integrity, are not
licensed under this Public License, nor are publicity,
privacy, and/or other similar personality rights; however, to
the extent possible, the Licensor waives and/or agrees not to
assert any such rights held by the Licensor to the limited
extent necessary to allow You to exercise the Licensed
Rights, but not otherwise.

2. Patent and trademark rights are not licensed under this
Public License.

3. To the extent possible, the Licensor waives any right to
collect royalties from You for the exercise of the Licensed
Rights, whether directly or through a collecting society
under any voluntary or waivable statutory or compulsory
licensing scheme. In all other cases the Licensor expressly
reserves any right to collect such royalties.


Section 3 -- License Conditions.

Your exercise of the Licensed Rights is expressly made subject to the
following conditions.

a. Attribution.

1. If You Share the Licensed Material (including in modified
form), You must:

a. retain the following if it is supplied by the Licensor
with the Licensed Material:

i. identification of the creator(s) of the Licensed
Material and any others designated to receive
attribution, in any reasonable manner requested by
the Licensor (including by pseudonym if
designated);

ii. a copyright notice;

iii. a notice that refers to this Public License;

iv. a notice that refers to the disclaimer of
warranties;

v. a URI or hyperlink to the Licensed Material to the
extent reasonably practicable;

b. indicate if You modified the Licensed Material and
retain an indication of any previous modifications; and

c. indicate the Licensed Material is licensed under this
Public License, and include the text of, or the URI or
hyperlink to, this Public License.

2. You may satisfy the conditions in Section 3(a)(1) in any
reasonable manner based on the medium, means, and context in
which You Share the Licensed Material. For example, it may be
reasonable to satisfy the conditions by providing a URI or
hyperlink to a resource that includes the required
information.

3. If requested by the Licensor, You must remove any of the
information required by Section 3(a)(1)(A) to the extent
reasonably practicable.

b. ShareAlike.

In addition to the conditions in Section 3(a), if You Share
Adapted Material You produce, the following conditions also apply.

1. The Adapter's License You apply must be a Creative Commons
license with the same License Elements, this version or
later, or a BY-SA Compatible License.

2. You must include the text of, or the URI or hyperlink to, the
Adapter's License You apply. You may satisfy this condition
in any reasonable manner based on the medium, means, and
context in which You Share Adapted Material.

3. You may not offer or impose any additional or different terms
or conditions on, or apply any Effective Technological
Measures to, Adapted Material that restrict exercise of the
rights granted under the Adapter's License You apply.


Section 4 -- Sui Generis Database Rights.

Where the Licensed Rights include Sui Generis Database Rights that
apply to Your use of the Licensed Material:

a. for the avoidance of doubt, Section 2(a)(1) grants You the right
to extract, reuse, reproduce, and Share all or a substantial
portion of the contents of the database;

b. if You include all or a substantial portion of the database
contents in a database in which You have Sui Generis Database
Rights, then the database in which You have Sui Generis Database
Rights (but not its individual contents) is Adapted Material,

including for purposes of Section 3(b); and
c. You must comply with the conditions in Section 3(a) if You Share
all or a substantial portion of the contents of the database.

For the avoidance of doubt, this Section 4 supplements and does not
replace Your obligations under this Public License where the Licensed
Rights include other Copyright and Similar Rights.


Section 5 -- Disclaimer of Warranties and Limitation of Liability.

a. UNLESS OTHERWISE SEPARATELY UNDERTAKEN BY THE LICENSOR, TO THE
EXTENT POSSIBLE, THE LICENSOR OFFERS THE LICENSED MATERIAL AS-IS
AND AS-AVAILABLE, AND MAKES NO REPRESENTATIONS OR WARRANTIES OF
ANY KIND CONCERNING THE LICENSED MATERIAL, WHETHER EXPRESS,
IMPLIED, STATUTORY, OR OTHER. THIS INCLUDES, WITHOUT LIMITATION,
WARRANTIES OF TITLE, MERCHANTABILITY, FITNESS FOR A PARTICULAR
PURPOSE, NON-INFRINGEMENT, ABSENCE OF LATENT OR OTHER DEFECTS,
ACCURACY, OR THE PRESENCE OR ABSENCE OF ERRORS, WHETHER OR NOT
KNOWN OR DISCOVERABLE. WHERE DISCLAIMERS OF WARRANTIES ARE NOT
ALLOWED IN FULL OR IN PART, THIS DISCLAIMER MAY NOT APPLY TO YOU.

b. TO THE EXTENT POSSIBLE, IN NO EVENT WILL THE LICENSOR BE LIABLE
TO YOU ON ANY LEGAL THEORY (INCLUDING, WITHOUT LIMITATION,
NEGLIGENCE) OR OTHERWISE FOR ANY DIRECT, SPECIAL, INDIRECT,
INCIDENTAL, CONSEQUENTIAL, PUNITIVE, EXEMPLARY, OR OTHER LOSSES,
COSTS, EXPENSES, OR DAMAGES ARISING OUT OF THIS PUBLIC LICENSE OR
USE OF THE LICENSED MATERIAL, EVEN IF THE LICENSOR HAS BEEN
ADVISED OF THE POSSIBILITY OF SUCH LOSSES, COSTS, EXPENSES, OR
DAMAGES. WHERE A LIMITATION OF LIABILITY IS NOT ALLOWED IN FULL OR
IN PART, THIS LIMITATION MAY NOT APPLY TO YOU.

c. The disclaimer of warranties and limitation of liability provided
above shall be interpreted in a manner that, to the extent
possible, most closely approximates an absolute disclaimer and
waiver of all liability.


Section 6 -- Term and Termination.

a. This Public License applies for the term of the Copyright and
Similar Rights licensed here. However, if You fail to comply with
this Public License, then Your rights under this Public License
terminate automatically.

b. Where Your right to use the Licensed Material has terminated under
Section 6(a), it reinstates:

1. automatically as of the date the violation is cured, provided
it is cured within 30 days of Your discovery of the
violation; or

2. upon express reinstatement by the Licensor.

For the avoidance of doubt, this Section 6(b) does not affect any
right the Licensor may have to seek remedies for Your violations
of this Public License.

c. For the avoidance of doubt, the Licensor may also offer the
Licensed Material under separate terms or conditions or stop
distributing the Licensed Material at any time; however, doing so
will not terminate this Public License.

d. Sections 1, 5, 6, 7, and 8 survive termination of this Public
License.


Section 7 -- Other Terms and Conditions.

a. The Licensor shall not be bound by any additional or different
terms or conditions communicated by You unless expressly agreed.

b. Any arrangements, understandings, or agreements regarding the
Licensed Material not stated herein are separate from and
independent of the terms and conditions of this Public License.


Section 8 -- Interpretation.

a. For the avoidance of doubt, this Public License does not, and
shall not be interpreted to, reduce, limit, restrict, or impose
conditions on any use of the Licensed Material that could lawfully
be made without permission under this Public License.

b. To the extent possible, if any provision of this Public License is
deemed unenforceable, it shall be automatically reformed to the
minimum extent necessary to make it enforceable. If the provision
cannot be reformed, it shall be severed from this Public License
without affecting the enforceability of the remaining terms and
conditions.

c. No term or condition of this Public License will be waived and no
failure to comply consented to unless expressly agreed to by the
Licensor.

d. Nothing in this Public License constitutes or may be interpreted
as a limitation upon, or waiver of, any privileges and immunities
that apply to the Licensor or You, including from the legal
processes of any jurisdiction or authority.


=======================================================================

Creative Commons is not a party to its public
licenses. Notwithstanding, Creative Commons may elect to apply one of
its public licenses to material it publishes and in those instances
will be considered the “Licensor.” The text of the Creative Commons
public licenses is dedicated to the public domain under the CC0 Public
Domain Dedication. Except for the limited purpose of indicating that
material is shared under a Creative Commons public license or as
otherwise permitted by the Creative Commons policies published at
creativecommons.org/policies, Creative Commons does not authorize the
use of the trademark "Creative Commons" or any other trademark or logo
of Creative Commons without its prior written consent including,
without limitation, in connection with any unauthorized modifications
to any of its public licenses or any other arrangements,
understandings, or agreements concerning use of licensed material. For
the avoidance of doubt, this paragraph does not form part of the
public licenses.

Creative Commons may be contacted at creativecommons.org.

License](https://www.gnu.org/licenses/lgpl.html) instead of this
License.

+ 28
- 13
Makefile.in View File

@@ -21,6 +21,7 @@ build=@build@
srcdir=@srcdir@
abs_srcdir=@abs_srcdir@
GNATMAKE=@GNATMAKE@
MAKE=@MAKE@
prefix=@prefix@
backend=@backend@
libdirsuffix=@libdirsuffix@
@@ -34,9 +35,12 @@ LDFLAGS=@LDFLAGS@
LIBBACKTRACE=@backtrace_lib@
llvm_be=@llvm_be@
build_mode=@build_mode@
ghdl_version=@ghdl_version@
libghdl_version=@libghdl_version@
enable_werror=@enable_werror@
enable_checks=@enable_checks@
enable_openieee=@enable_openieee@
enable_python=@enable_python@

INSTALL_PROGRAM=install -m 755
INSTALL_DATA=install -m 644
@@ -113,7 +117,7 @@ LIBVHDL_FLAGS_TO_PASS=\
enable_openieee="$(enable_openieee)" \
LN="$(LN)" CP="$(CP)" MKDIR="$(MKDIR)"

all: Makefile all.$(backend)
all: Makefile all.$(backend) all.libghdl.$(enable_python)

install: install.$(backend)

@@ -144,10 +148,11 @@ version.tmp: $(srcdir)/src/version.in force
# Create version.tmp from version.in, using git date/hash
if test -d $(srcdir)/.git \
&& desc=`cd $(srcdir); git describe --dirty`; then \
$(SED) -e "s/[(].*[)]/($$desc)/" < $< > $@; \
sub="s/[(].*[)]/($$desc)/"; \
else \
$(CP) $< $@; \
fi
sub="s/tarball/tarball/"; \
fi; \
$(SED) -e "$$sub" -e "s/@VER@/$(ghdl_version)/" < $< > $@; \

version.ads: version.tmp
# Change version.ads only if version.tmp has been modified to avoid
@@ -187,10 +192,10 @@ gcc_vhdl_dir=$(gcc_src_dir)/gcc/vhdl

all.gcc:
@echo "For installing sources in gcc, do:"
@echo "1) make copy-sources"
@echo "1) $(MAKE) copy-sources"
@echo "2) configure, build and install gcc"
@echo "3) make ghdllib"
@echo "4) make install"
@echo "3) $(MAKE) ghdllib"
@echo "4) $(MAKE) install"

copy-sources.gcc: version.ads
$(RM) -rf $(gcc_vhdl_dir)
@@ -325,7 +330,7 @@ ghdl_simul$(EXEEXT): $(GRT_ADD_OBJS) $(GRT_SRC_DEPS) version.ads force
libs.vhdl.simul: ghdl_simul$(EXEEXT)
$(MAKE) -f $(srcdir)/libraries/Makefile.inc $(LIBVHDL_FLAGS_TO_PASS) GHDL=$(PWD)/ghdl_simul$(EXEEXT) GHDL_FLAGS="" VHDLLIBS_COPY_OBJS=no vhdl.libs.all

install.simul.program: install.dirs ghdl_simul(EXEEXT)
install.simul.program: install.dirs ghdl_simul$(EXEEXT)
$(INSTALL_PROGRAM) ghdl_simul$(EXEEXT) $(DESTDIR)$(bindir)/ghdl$(EXEEXT)

install.simul: install.simul.program install.vhdllib
@@ -335,9 +340,14 @@ install.simul: install.simul.program install.vhdllib

LIBGHDL_INCFLAGS=$(GHDL_COMMON_INCFLAGS) -aI$(srcdir)/src/vhdl/python -aI$(srcdir)/src/ghdldrv

libghdl$(SOEXT): $(GRT_SRC_DEPS) version.ads force
libghdl_name=libghdl-$(libghdl_version)$(SOEXT)

$(libghdl_name): $(GRT_SRC_DEPS) version.ads force
$(GNATMAKE) -I- -aI. -D pic -z libghdl -o $@ $(GNATFLAGS) $(PIC_FLAGS) -gnat05 $(LIBGHDL_INCFLAGS) -bargs -shared -Llibghdl_ -largs -shared $(SHLIB_FLAGS)

all.libghdl.true: $(libghdl_name)
all.libghdl.false:

################ ghdlsynth library ######################################

GHDL_SYNTHLIB_INCFLAGS=$(GHDL_COMMON_INCFLAGS) -aI$(srcdir)/src/synth -aI$(srcdir)/src/ghdldrv -aI$(srcdir)/src/vhdl/simulate
@@ -404,19 +414,24 @@ install.vpi: all.vpi install.dirs
$(INSTALL_DATA) -p libghdlvpi$(SOEXT) $(DESTDIR)$(libdir)/
$(INSTALL_DATA) -p $(GRTSRCDIR)/vpi_user.h $(DESTDIR)$(incdir)/

install.vpi.local: all.vpi
$(MKDIR) -p include lib
$(INSTALL_DATA) -p $(GRTSRCDIR)/vpi_user.h include/
$(INSTALL_DATA) -p libghdlvpi$(SOEXT) lib/

################ Libraries ###############################################

LIBSRC_DIR:=$(srcdir)/libraries
LIBDST_DIR:=$(libdirsuffix)

VHDLLIB_SUBDIRS_COMMON= src/std src/synopsys src/openieee \
v87/std v87/ieee v87/synopsys \
v93/std v93/ieee v93/synopsys \
v08/std
std/v87 ieee/v87 synopsys/v87 \
std/v93 ieee/v93 synopsys/v93 \
std/v08

VHDLLIB_SUBDIRS_FULL= src/ieee src/vital95 src/vital2000 src/mentor \
src/ieee2008 \
v93/mentor v08/ieee v08/synopsys
mentor/v93 ieee/v08 synopsys/v08

ifeq ($(enable_openieee),false)
VHDLLIB_SUBDIRS=$(VHDLLIB_SUBDIRS_COMMON) $(VHDLLIB_SUBDIRS_FULL)

+ 4
- 1
NEWS.md View File

@@ -1,4 +1,7 @@
**0.35** (2017-12-XX)
**0.36-dev** (XXXX-XX-XX)
- A new GitHub organization is created and the main repo is moved from [github.com/tgingold/ghdl](https://github.com/tgingold/ghdl) to [github.com/ghdl/ghdl](https://github.com/ghdl/ghdl). Old refs will continue working, because permanent redirects are set up. However, we suggest every contributor to update the remote URLs in their local clones.

**0.35** (2017-12-14)
- Assert and report messages are sent to stdout (#394)
- Improve support for unbounded records
- Bugs fixed

+ 10
- 7
README.md View File

@@ -1,9 +1,12 @@
[![Documentation Status](https://readthedocs.org/projects/ghdl/badge/?version=latest)](http://ghdl.readthedocs.io) [![Join the chat at https://gitter.im/ghdl1/Lobby](https://img.shields.io/gitter/room/ghdl1/Lobby.svg?colorB=4cb696)](https://gitter.im/ghdl1/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![GNU General Public License 2](https://img.shields.io/badge/code%20license-GPLv2-bd0000.svg?style=flat)](https://github.com/tgingold/ghdl/blob/master/COPYING.md) [![Creative Commons Attribution-ShareAlike](https://img.shields.io/badge/doc%20license-CC--BY--SA--4.0-aab2ab.svg?style=flat)](https://github.com/tgingold/ghdl/blob/master/COPYING.md)
[![Linux containers at Travis-CI](https://img.shields.io/travis/tgingold/ghdl/master.svg?style=flat&logo=data%3Aimage%2Fpng%3Bbase64%2CiVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAIP0lEQVR42qVXaUyUWRaFycyP%2BTVLemaSSfrPJN3JZJKOPyY6uBLTQgGlUMVeFHuxFaioKGpcAFFQUaOigAsmo7ghikZtxZVFCCKgqOi4ICoqqLjghqjcOeem%2B5sQFZnuL3l5VV%2B9d%2B9595577iuX%2F%2FcZNWrUX7y8vMyJiYmbpk6d2pKamto5bdq0LnxuT05OPhgUFOQcOXLkP35a7%2Bvr6%2FKLnmXLlun87t27X02YMKFkzpw5va2trXL37l158OCBPHz4UEdXV5fcu3dPbt26Jdu3b%2B%2Fz8%2FNrM5vNf%2BNeAPxlIHAi06xZs7rOnj0rL168kPb2dnn8%2BLE8evToo0EgHPfv35e1a9cKQOT9LKc2m03nyMhIv%2FXr18uzZ8%2F0pDU1NXLz5k0xTzSLycs0cHibBClhBOTJkycKqKmpSZCyGkTv10N27unpqfPw4cNDSkpK5OrVqzSmAHbu3CnXr1%2BXhIQECQkNkeCQYHEkxAPQRHEmJ0taWposWbJEOjs7dX1bW5s0NjYyEtW0OXny5KGBMJlMf1ixYsUHOqYRGmPYi4qK5PLly5KUlCSLFi0S5FqCAaSutk6io6MlMzNTtmzZIkwX9zASdXV10tLSQhALaRtEHdy5iLhYrdbbP53gxo0baqy7u1tWrlxJAErA7sfdYrFYNBINZxv0XUdHh5SXl8uhQ4eMPbW1tfqZqQwODv7rF0%2F%2FPZ6GhoZ%2B5v3AgQNKqqdPnyoBly9fztMxJeSFAeDcuXN8p9Wxf%2F9%2BBfH8%2BXMFcP78eSMlWN%2F8SafDhg0zPqOmG2%2Ffvi137tzRkF%2B6dEny8vLE399fUA1y%2BvRpGtMT%2B1n8JMQWKhUVFQTKiKlzkE7XHjlyRJqbm7lWI3n06NG%2B0aNHfzvAOVDq7Obm9mcIzIbS0lK5cuWKVFVVyerVq2Xv3r2aw5kzZ0pubq6cOnWKNa8njYyKlKRkpyBlPL2yPiUlhfzQVJ04cUI2bdrE1CmI%2Bvp6Wbp06bkRI0ZYBoAA4u9JIIAxGL9jxw5GgeRjCjT8GzdulM2bN2s5btu2TcJsNgmz2yU8IkIBHz58WIm4atUq6enpoS21iagyJbTL1BEYQe8zALi7u%2BdiAxcYg8iZd4a2srJST%2B9wOMTb25tk0gqYiPLjmDRpkkYhJCRE4uPjBeUmBw8e1JJ9%2Ffo108GDGLYJJjw8XAwAY8eOzedLIuZCkoY1Tzbv2rVLEV%2B4cIE5NpSOPCHrORh%2BpoX7GDVqx5kzZ2Tfvn2yZ88eVUVKOG1zMAoRiJoBADnJpEHmiMTh5prqaimHgeLiYs2p0%2BkkETUCXt5eUD8dVDod0A7OjIhGYcGCBVJQUCBlZWVMD21yZjQ1Aj4%2BPv8DMGbMmDCemDJKR%2BPGjRNfhNgeES7hkREML0tIAfiYzWK3h6kA2TBjPUNMkPjdKgmJiRIHdXTEIV0%2B3poWdEqBrGvYs7Oz5dixY0zhfwwAULGvwsLCVMvt4XaJdcRKQlIinahTdEE60FxDyQDOl1Whsrt48WI1Ghpqkxjso3OSkpGaN2%2Be5OfnGwNiRBUlSQnMNqAScEpvi9UiMbGxgj4uqFcl2ty5c2XGjBn6vbCwkGlibbM0WWpaEdAurX0eonhLMbmjJM7JyWFZ0h4JrLYCAwM%2FIJpRsOPqAlTqHPX%2FDXKHU4T2BAYFfsAirQA%2B1HNupNo1NTeR1RzqnJrBCGVkZGiX5MO%2BsBm86evrE9wjpL%2B%2Fn6%2B1R0yfPp0cqfxICRGuDoweEKkxJiaGZaSsfvnypTK8EyLCfK4tLEClPKQ9rqFCsu45U%2FO19gODgmXm7NkQsDICpQ0dGzZsoLBRP%2FrHjx%2F%2Fb5gwnFeDkeunTJnye7J0zZo1zB1DrBtfvXql9ezp4SFubv8Ci09rmeGmQxAsNQWB2xMdajpGurmRI4Zz2KBdKiJ1gNVyLC4uztUFOR6NcJsJBMz%2FHUrwPRWQqnfy5EluplHKL0nIk%2FIdDWl%2Bjx8%2FLu%2Ffv9eajgV33rx5w9Qoy69du8Zy43qt%2B6ysLA7VDcj%2BVj09yuMbzgDBLvhb3AHuV1ZWybp168h8CpPm8O3bt4IOSSlWIwsXLmQFkB%2FMNVlNpSQXWBX8TcO9detW2b17t8yfP5%2BVwshSrlnmjoEXTwWT4moyeda0tl6mkGhIESYC4elY6zCcg%2Fe5MDhPAJZEZYSUgLORd4Cjc%2B4FoBxGjaCQogyWMEVIbYP0f%2FzMXWD8KKvV8i4gIOA8ygcLEzhQQrEwvBgdsBzt%2BSLCeJcRYYulLCvDS3eXwvFSSO4lKF4l0lCB0%2B9CNPORqgpwIq3Fw8PDirT%2F8xOuSUbTgO%2FZ2Yva6uvr0GIb0UrvoSM%2B0ZGenk6RgSL6yAQQc5y7u5ghq%2F4BARJqs1ELlAe9vb1IUTd7B%2FZ3Qaq9nHDugVI3D3YdcwWzv0Y5uqI%2FpOMKTgYbTKYexMXHSaIz6bOD94OJCDfTwT7CywrbMWz24MLbi1R8DdJ%2B5NsQJSxIxeIqCExAVFRU%2B8WLF6WosEiNhIbZ6GRIIzo2WiIiI9gvMEeqPCMFJS6DPUQGyfwNkHZAlhnmtww3DTlTkj%2FliNrPvvHFqFihmC5DfXDyP1nQAZO%2BfFIoXxDb82cdE3gwOiLELuPHxje4c%2Bi1ziZPUzxuPjTyScMcDvCBf1IKCwpBQn90UYfEo2qiYqKVjAGBAc%2B9fXxqQdL0H1V3aBFAGeqMlpnKjmgQD62UTtiy%2FSwWtmYqm5IUXKFeMM%2FsomV2u%2F3vtAEuufysByfgRJX8DshTPU2mPPy7yQBBYzGWgC%2FVkOSXWVmZZHwnSPoD%2FlOmodXSsWFjsOe%2FCAcrQqMD2awAAAAASUVORK5CYII%3D)](https://travis-ci.org/tgingold/ghdl) [![Windows VMs at AppVeyor](https://ci.appveyor.com/api/projects/status/rsq60m5wcly3og8j?svg=true)](https://ci.appveyor.com/project/tgingold/ghdl) [![Commits since latest release](https://img.shields.io/github/commits-since/tgingold/ghdl/latest.svg?style=flat)](https://github.com/tgingold/ghdl/releases)
[![Documentation Status](https://readthedocs.org/projects/ghdl/badge/?version=latest)](http://ghdl.readthedocs.io) [![Join the chat at https://gitter.im/ghdl1/Lobby](https://img.shields.io/gitter/room/ghdl1/Lobby.svg?colorB=4cb696)](https://gitter.im/ghdl1/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![GNU General Public License 2](https://img.shields.io/badge/code%20license-GPLv2-bd0000.svg?style=flat)](https://github.com/ghdl/ghdl/blob/master/COPYING.md) [![Creative Commons Attribution-ShareAlike](https://img.shields.io/badge/doc%20license-CC--BY--SA--4.0-aab2ab.svg?style=flat)](https://github.com/ghdl/ghdl/blob/master/doc/COPYING_DOC.md)
[![Linux containers at Travis-CI](https://img.shields.io/travis/ghdl/ghdl/master.svg?style=flat&logo=data%3Aimage%2Fpng%3Bbase64%2CiVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAIP0lEQVR42qVXaUyUWRaFycyP%2BTVLemaSSfrPJN3JZJKOPyY6uBLTQgGlUMVeFHuxFaioKGpcAFFQUaOigAsmo7ghikZtxZVFCCKgqOi4ICoqqLjghqjcOeem%2B5sQFZnuL3l5VV%2B9d%2B9595577iuX%2F%2FcZNWrUX7y8vMyJiYmbpk6d2pKamto5bdq0LnxuT05OPhgUFOQcOXLkP35a7%2Bvr6%2FKLnmXLlun87t27X02YMKFkzpw5va2trXL37l158OCBPHz4UEdXV5fcu3dPbt26Jdu3b%2B%2Fz8%2FNrM5vNf%2BNeAPxlIHAi06xZs7rOnj0rL168kPb2dnn8%2BLE8evToo0EgHPfv35e1a9cKQOT9LKc2m03nyMhIv%2FXr18uzZ8%2F0pDU1NXLz5k0xTzSLycs0cHibBClhBOTJkycKqKmpSZCyGkTv10N27unpqfPw4cNDSkpK5OrVqzSmAHbu3CnXr1%2BXhIQECQkNkeCQYHEkxAPQRHEmJ0taWposWbJEOjs7dX1bW5s0NjYyEtW0OXny5KGBMJlMf1ixYsUHOqYRGmPYi4qK5PLly5KUlCSLFi0S5FqCAaSutk6io6MlMzNTtmzZIkwX9zASdXV10tLSQhALaRtEHdy5iLhYrdbbP53gxo0baqy7u1tWrlxJAErA7sfdYrFYNBINZxv0XUdHh5SXl8uhQ4eMPbW1tfqZqQwODv7rF0%2F%2FPZ6GhoZ%2B5v3AgQNKqqdPnyoBly9fztMxJeSFAeDcuXN8p9Wxf%2F9%2BBfH8%2BXMFcP78eSMlWN%2F8SafDhg0zPqOmG2%2Ffvi137tzRkF%2B6dEny8vLE399fUA1y%2BvRpGtMT%2B1n8JMQWKhUVFQTKiKlzkE7XHjlyRJqbm7lWI3n06NG%2B0aNHfzvAOVDq7Obm9mcIzIbS0lK5cuWKVFVVyerVq2Xv3r2aw5kzZ0pubq6cOnWKNa8njYyKlKRkpyBlPL2yPiUlhfzQVJ04cUI2bdrE1CmI%2Bvp6Wbp06bkRI0ZYBoAA4u9JIIAxGL9jxw5GgeRjCjT8GzdulM2bN2s5btu2TcJsNgmz2yU8IkIBHz58WIm4atUq6enpoS21iagyJbTL1BEYQe8zALi7u%2BdiAxcYg8iZd4a2srJST%2B9wOMTb25tk0gqYiPLjmDRpkkYhJCRE4uPjBeUmBw8e1JJ9%2Ffo108GDGLYJJjw8XAwAY8eOzedLIuZCkoY1Tzbv2rVLEV%2B4cIE5NpSOPCHrORh%2BpoX7GDVqx5kzZ2Tfvn2yZ88eVUVKOG1zMAoRiJoBADnJpEHmiMTh5prqaimHgeLiYs2p0%2BkkETUCXt5eUD8dVDod0A7OjIhGYcGCBVJQUCBlZWVMD21yZjQ1Aj4%2BPv8DMGbMmDCemDJKR%2BPGjRNfhNgeES7hkREML0tIAfiYzWK3h6kA2TBjPUNMkPjdKgmJiRIHdXTEIV0%2B3poWdEqBrGvYs7Oz5dixY0zhfwwAULGvwsLCVMvt4XaJdcRKQlIinahTdEE60FxDyQDOl1Whsrt48WI1Ghpqkxjso3OSkpGaN2%2Be5OfnGwNiRBUlSQnMNqAScEpvi9UiMbGxgj4uqFcl2ty5c2XGjBn6vbCwkGlibbM0WWpaEdAurX0eonhLMbmjJM7JyWFZ0h4JrLYCAwM%2FIJpRsOPqAlTqHPX%2FDXKHU4T2BAYFfsAirQA%2B1HNupNo1NTeR1RzqnJrBCGVkZGiX5MO%2BsBm86evrE9wjpL%2B%2Fn6%2B1R0yfPp0cqfxICRGuDoweEKkxJiaGZaSsfvnypTK8EyLCfK4tLEClPKQ9rqFCsu45U%2FO19gODgmXm7NkQsDICpQ0dGzZsoLBRP%2FrHjx%2F%2Fb5gwnFeDkeunTJnye7J0zZo1zB1DrBtfvXql9ezp4SFubv8Ci09rmeGmQxAsNQWB2xMdajpGurmRI4Zz2KBdKiJ1gNVyLC4uztUFOR6NcJsJBMz%2FHUrwPRWQqnfy5EluplHKL0nIk%2FIdDWl%2Bjx8%2FLu%2Ffv9eajgV33rx5w9Qoy69du8Zy43qt%2B6ysLA7VDcj%2BVj09yuMbzgDBLvhb3AHuV1ZWybp168h8CpPm8O3bt4IOSSlWIwsXLmQFkB%2FMNVlNpSQXWBX8TcO9detW2b17t8yfP5%2BVwshSrlnmjoEXTwWT4moyeda0tl6mkGhIESYC4elY6zCcg%2Fe5MDhPAJZEZYSUgLORd4Cjc%2B4FoBxGjaCQogyWMEVIbYP0f%2FzMXWD8KKvV8i4gIOA8ygcLEzhQQrEwvBgdsBzt%2BSLCeJcRYYulLCvDS3eXwvFSSO4lKF4l0lCB0%2B9CNPORqgpwIq3Fw8PDirT%2F8xOuSUbTgO%2FZ2Yva6uvr0GIb0UrvoSM%2B0ZGenk6RgSL6yAQQc5y7u5ghq%2F4BARJqs1ELlAe9vb1IUTd7B%2FZ3Qaq9nHDugVI3D3YdcwWzv0Y5uqI%2FpOMKTgYbTKYexMXHSaIz6bOD94OJCDfTwT7CywrbMWz24MLbi1R8DdJ%2B5NsQJSxIxeIqCExAVFRU%2B8WLF6WosEiNhIbZ6GRIIzo2WiIiI9gvMEeqPCMFJS6DPUQGyfwNkHZAlhnmtww3DTlTkj%2FliNrPvvHFqFihmC5DfXDyP1nQAZO%2BfFIoXxDb82cdE3gwOiLELuPHxje4c%2Bi1ziZPUzxuPjTyScMcDvCBf1IKCwpBQn90UYfEo2qiYqKVjAGBAc%2B9fXxqQdL0H1V3aBFAGeqMlpnKjmgQD62UTtiy%2FSwWtmYqm5IUXKFeMM%2FsomV2u%2F3vtAEuufysByfgRJX8DshTPU2mPPy7yQBBYzGWgC%2FVkOSXWVmZZHwnSPoD%2FlOmodXSsWFjsOe%2FCAcrQqMD2awAAAAASUVORK5CYII%3D)](https://travis-ci.org/ghdl/ghdl) [![Windows VMs at AppVeyor](https://ci.appveyor.com/api/projects/status/7hx4kfbhidv06sin?svg=true)](https://ci.appveyor.com/project/tgingold/ghdl-psgys) [![Commits since latest release](https://img.shields.io/github/commits-since/ghdl/ghdl/latest.svg?style=flat)](https://github.com/ghdl/ghdl/releases)

**A new GitHub organization was created (2017-12-20) and the main repo was moved from [github.com/tgingold/ghdl](https://github.com/tgingold/ghdl) to [github.com/ghdl/ghdl](https://github.com/ghdl/ghdl). Old refs will continue working, because permanent redirects are set up. However, we suggest every contributor to update the remote URLs in their local clones. See
[Changing a remote's URL](https://help.github.com/articles/changing-a-remote-s-url/).**

# GHDL

This directory contains the sources of GHDL, the open-source compilator and simulator for [VHDL](https://en.wikipedia.org/wiki/VHDL), a Hardware Description Language ([HDL](https://en.wikipedia.org/wiki/Hardware_description_language)). GHDL is not an interpreter: it allows you to analyse and elaborate sources to generate machine code from your design. Native program execution is the only way for high speed simulation.
This directory contains the sources of GHDL, the open-source compiler and simulator for [VHDL](https://en.wikipedia.org/wiki/VHDL), a Hardware Description Language ([HDL](https://en.wikipedia.org/wiki/Hardware_description_language)). GHDL is not an interpreter: it allows you to analyse and elaborate sources to generate machine code from your design. Native program execution is the only way for high speed simulation.

## Main features

@@ -21,21 +24,21 @@ Supported third party projects: [VUnit](https://vunit.github.io), [OSVVM](http:/

GHDL is free software:

- [![GNU General Public License 2](https://img.shields.io/badge/code%20license-GPLv2-bd0000.svg?style=flat)](https://github.com/tgingold/ghdl/blob/master/COPYING.md)
- [![Creative Commons Attribution-ShareAlike 4.0](https://img.shields.io/badge/doc%20license-Creative%20Commons%20Attribution--ShareAlike--4.0-aab2ab.svg?style=flat)](https://github.com/tgingold/ghdl/blob/master/COPYING.md) available at [![ghdl.readthedocs.io](https://img.shields.io/badge/ghdl-.readthedocs.io-2980b9.svg?style=flat)](https://ghdl.readthedocs.io)
- [![GNU General Public License 2](https://img.shields.io/badge/code%20license-GPLv2-bd0000.svg?style=flat)](https://github.com/ghdl/ghdl/blob/master/COPYING.md)
- [![Creative Commons Attribution-ShareAlike 4.0](https://img.shields.io/badge/doc%20license-Creative%20Commons%20Attribution--ShareAlike--4.0-aab2ab.svg?style=flat)](https://github.com/ghdl/ghdl/blob/master/doc/COPYING_DOC.md) available at [![ghdl.readthedocs.io](https://img.shields.io/badge/ghdl-.readthedocs.io-2980b9.svg?style=flat)](https://ghdl.readthedocs.io)
- Some of the runtime libraries, are under different terms; see the individual source files for details.

## Getting GHDL

### Pre-built releases

Periodically (not regularly), several binary distributions are made available through the [releases](https://github.com/tgingold/ghdl/releases) tab. If you can't find the one matching the platform and versions you need, you can build it yourself!
Periodically (not regularly), several binary distributions are made available through the [releases](https://github.com/ghdl/ghdl/releases) tab. If you can't find the one matching the platform and versions you need, you can build it yourself!

### Building GHDL

In order to follow the traditional way to `configure` and `make`, you need the GNU Ada compiler, GNAT GPL, 2014 (or later) for x86 (32 or 64 bits). GNAT GPL can be downloaded anonymously from [libre.adacore.com](http://libre.adacore.com/tools/gnat-gpl-edition/). Then, untar and run the *doinstall* script.

*Depending on the OS and distribution you are using, you will also need to install some toolchain dependencies, such as `zlib`. See '[Building](http://ghdl.readthedocs.io/en/latest/building/index.html)' for specific package names.*
*Depending on the OS and distribution you are using, you will also need to install some toolchain dependencies, such as `zlib`. See '[Building](http://ghdl.readthedocs.io/en/latest/building/Building.html)' for specific package names.*

In the GHDL base directory, configure and build:
```sh

+ 29
- 8
configure View File

@@ -3,11 +3,19 @@
# configure script for ghdl (c) 2014 Tristan Gingold
#

# Current version. This is the only place where the version is written.
# Any code that needs version should read it directly or indirectly from this
# place.
# Note the absence of spaces and the quotes.
# Suffix "-dev" is used during development.
ghdl_version="0.36-dev"

backend=mcode
CC=${CC:-gcc}
CXX=${CXX:-clang++}
CFLAGS=${CFLAGS:--g}
GNATMAKE=${GNATMAKE:-gnatmake}
MAKE=${MAKE:-make}
LDFLAGS=
prefix=/usr/local
libdirsuffix=lib/ghdl
@@ -21,6 +29,7 @@ build_mode=
enable_werror=true
enable_checks=true
enable_openieee=unknown
enable_python=false
EXEEXT=
SOEXT=.so
PIC_FLAGS=-fPIC
@@ -28,7 +37,7 @@ PIC_FLAGS=-fPIC
show_help=no
progname=$0

subst_vars="CC CXX GNATMAKE CFLAGS LDFLAGS build srcdir abs_srcdir prefix backend libdirsuffix libdirreverse gcc_src_dir llvm_config llvm_be backtrace_lib build_mode EXEEXT SOEXT PIC_FLAGS default_pie enable_werror enable_checks enable_openieee"
subst_vars="CC CXX GNATMAKE MAKE CFLAGS LDFLAGS build srcdir abs_srcdir prefix backend libdirsuffix libdirreverse gcc_src_dir llvm_config llvm_be backtrace_lib build_mode EXEEXT SOEXT PIC_FLAGS default_pie enable_werror enable_checks enable_openieee enable_python libghdl_version ghdl_version"

# Find srcdir
srcdir=`dirname $progname`
@@ -79,6 +88,8 @@ for opt do
--disable-checks) enable_checks=false;;
--enable-openieee) enable_openieee=true;;
--disable-openieee) enable_openieee=false;;
--enable-python) enable_python=true;;
--disable-python) enable_python=false;;
--enable-coverage) build_mode="coverage";;
-h|-help|--help) show_help=yes;;
*) echo "$0: unknown option $opt; try $0 --help"
@@ -102,6 +113,7 @@ Options [defaults in brackets]:
--disable-werror warnings don't stop build
--disable-checks disable internal checks
--enable-openieee use gpl-compatible sources for ieee library
--enable-python build python libghdl
EOF
exit 0
fi
@@ -216,8 +228,10 @@ if test $backend = llvm; then
llvm_be=llvm-nodebug
# Tested with llvm 3.5, so assume 3.6, 3.7 and 3.8
elif check_version 3.9 $llvm_version ||
check_version 4.0 $llvm_version ||
check_version 5.0 $llvm_version; then
check_version 4.0 $llvm_version ||
check_version 5.0 $llvm_version ||
check_version 6.0 $llvm_version ||
false; then
echo "Debugging is not enabled with llvm $llvm_version"
llvm_be=llvm4-nodebug
else
@@ -240,6 +254,9 @@ case "$build" in
*) SOEXT=".so"; EXEEXT=""; PIC_FLAGS="-fPIC";;
esac

# Define libghdl_version
libghdl_version=`echo $ghdl_version | sed -e 's/[-.]/_/g'`

# Check if gcc was configured with --enable-default-pie. In that case -fPIC
# should be added.
if gcc -v 2>&1 | grep -q enable-default-pie; then
@@ -280,10 +297,14 @@ for v in $subst_vars; do
echo $v=\"$vval\"
done
sed_opts=`echo $subst_vars | sed -e "s/\\([a-zA-Z_]*\\)/ -e \"s%@\1@%\$\1%g\"/g"`
echo 'echo "Creating ghdl.gpr"'
echo sed $sed_opts '< $srcdir/ghdl.gpr.in > ghdl.gpr'
echo 'echo "Creating Makefile"'
echo sed $sed_opts '< $srcdir/Makefile.in > Makefile'
subst_files="ghdl.gpr Makefile"
if [ "$enable_python" = true ]; then
subst_files="$subst_files setup.py"
fi
echo "for f in $subst_files; do"
echo ' echo "Creating $f"'
echo " sed $sed_opts" '< $srcdir/${f}.in > $f'
echo "done"
} > config.status || \
{
echo "$progname: cannot create config.status"
@@ -299,7 +320,7 @@ if ! sh ./config.status; then
fi

# Create dirs
make create-dirs
$MAKE create-dirs

# Generate ortho_code-x86-flags
if test $backend = mcode; then

+ 144
- 0
dist/linux/build.sh View File

@@ -0,0 +1,144 @@
#! /bin/bash

. dist/linux/travis-utils.sh
. dist/ansi_color.sh
disable_color

echo "$0" "$@"

# Stop in case of error
set -e

# Transform long options to short ones
for arg in "$@"; do
shift
case "$arg" in
"--color"|"-color") set -- "$@" "-c";;
"--build"|"-build") set -- "$@" "-b";;
"--pkg"|"-pkg") set -- "$@" "-p";;
"--gpl"|"-gpl") set -- "$@" "-g";;
*) set -- "$@" "$arg"
esac
done
# Parse args
while getopts ":b:p:cg" opt; do
case $opt in
c) enable_color;;
b) BLD=$OPTARG ;;
p) PKG_NAME=$OPTARG;;
g) ISGPL=true;;
\?) printf "$ANSI_RED[GHDL - build] Invalid option: -$OPTARG $ANSI_NOCOLOR\n" >&2
exit 1 ;;
:) printf "$ANSI_RED[GHDL - build] Option -$OPTARG requires an argument. $ANSI_NOCOLOR\n" >&2
exit 1 ;;
esac
done

rm -f build_ok

#--- Env

echo "travis_fold:start:env.docker"
printf "$ANSI_YELLOW[Info] Environment $ANSI_NOCOLOR\n"
env
echo "travis_fold:end:env.docker"

#--- GPL: gpl-ize sources

if [ "$ISGPL" = "true" ]; then
echo "travis_fold:start:gpl.src"
printf "$ANSI_YELLOW[Source] create GPL sources $ANSI_NOCOLOR\n"
files=`echo *`
make -f Makefile.in srcdir=. clean-pure-gpl
mkdir ${PKG_NAME}
cp -pdrl $files ${PKG_NAME}
tar -zcf "${PKG_NAME}.tar.gz" ${PKG_NAME}
PKG_NAME="${PKG_NAME}-${BLD}"
echo "travis_fold:end:gpl.src"
fi

#--- Configure

echo "travis_fold:start:configure"
printf "$ANSI_YELLOW[GHDL - build] Configure $ANSI_NOCOLOR\n"

CDIR=$(pwd)
export prefix="$CDIR/install-$BLD"
mkdir "$prefix"
mkdir "build-$BLD"
cd "build-$BLD"

case "$BLD" in
mcode)
config_opts=""
CXX=""
;;
llvm)
CXX="clang"
config_opts="--with-llvm-config CXX=$CXX"
;;
llvm-3.5)
CXX="clang++"
config_opts="--with-llvm-config=llvm-config-3.5 CXX=$CXX"
;;
llvm-3.8)
CXX="clang++-3.8"
config_opts="--with-llvm-config=llvm-config-3.8 CXX=$CXX"
;;
llvm-3.9)
CXX="clang++-3.9"
config_opts="--with-llvm-config=llvm-config-3.9 CXX=$CXX"
;;
llvm-4.0)
CXX="clang++-4.0"
config_opts="--with-llvm-config=llvm-config-4.0 CXX=$CXX"
;;
llvm-5.0)
CXX="clang++-5.0"
config_opts="--with-llvm-config=llvm-config-5.0 CXX=$CXX"
;;
*)
echo "$ANSI_RED[GHDL - build] Unknown build $BLD $ANSI_NOCOLOR"
exit 1;;
esac
echo "../configure --prefix=$prefix $config_opts"
../configure "--prefix=$prefix" $config_opts
echo "travis_fold:end:configure"

#--- make

echo "travis_fold:start:make"
travis_time_start
printf "$ANSI_YELLOW[GHDL - build] Make $ANSI_NOCOLOR\n"
make
travis_time_finish
echo "travis_fold:end:make"

echo "travis_fold:start:install"
printf "$ANSI_YELLOW[GHDL - build] Install $ANSI_NOCOLOR\n"
make install
cd ..
echo "travis_fold:end:install"

#--- package

echo "travis_fold:start:tar.bin"
printf "$ANSI_YELLOW[GHDL - build] Create package ${ANSI_DARKCYAN}${PKG_NAME}.tgz $ANSI_NOCOLOR\n"
tar -zcvf "${PKG_NAME}.tgz" -C "$prefix" .
echo "travis_fold:end:tar.bin"

#--- build tools versions

{
make --version | grep 'Make'
gnatls --version | grep 'GNATLS'
gcc --version | grep 'gcc'
if [ "$CXX" != "" ]; then
$CXX --version | grep 'clang'
fi
} > BUILD_TOOLS

#---

echo "[SUCCESSFUL]"
touch build_ok

+ 0
- 193
dist/linux/buildtest.sh View File

@@ -1,193 +0,0 @@
#! /bin/bash

. dist/ansi_color.sh
disable_color

echo "$0" "$@"

# Stop in case of error
set -e

. dist/linux/travis-utils.sh

rm -f build_ok

# Transform long options to short ones
for arg in "$@"; do
shift
case "$arg" in
"--color"|"-color") set -- "$@" "-c";;
"--build"|"-build") set -- "$@" "-b";;
"--pkg"|"-pkg") set -- "$@" "-p";;
"--gpl"|"-gpl") set -- "$@" "-g";;
*) set -- "$@" "$arg"
esac
done
# Parse args
while getopts ":b:p:cg" opt; do
case $opt in
c) enable_color;;
b) BLD=$OPTARG ;;
p) PKG_NAME=$OPTARG;;
g) ISGPL=true;;
\?) printf "$ANSI_RED[GHDL] Invalid option: -$OPTARG $ANSI_NOCOLOR\n" >&2
exit 1 ;;
:) printf "$ANSI_RED[GHDL] Option -$OPTARG requires an argument. $ANSI_NOCOLOR\n" >&2
exit 1 ;;
esac
done

#--- Env

echo "travis_fold:start:env.docker"
printf "$ANSI_YELLOW[Info] Environment $ANSI_NOCOLOR\n"
env
echo "travis_fold:end:env.docker"

#--- GPL: gpl-ize sources

if [ "$ISGPL" = "true" ]; then
echo "travis_fold:start:gpl.src"
printf "$ANSI_YELLOW[Source] create GPL sources $ANSI_NOCOLOR\n"
files=`echo *`
make -f Makefile.in srcdir=. clean-pure-gpl
mkdir ${PKG_NAME}
cp -pdrl $files ${PKG_NAME}
tar -zcf "${PKG_NAME}.tar.gz" ${PKG_NAME}
PKG_NAME="${PKG_NAME}-${BLD}"
echo "travis_fold:end:gpl.src"
fi

#--- Configure

echo "travis_fold:start:configure"
printf "$ANSI_YELLOW[GHDL] Configure $ANSI_NOCOLOR\n"

CDIR=$(pwd)
prefix="$CDIR/install-$BLD"
mkdir "$prefix"
mkdir "build-$BLD"
cd "build-$BLD"

case "$BLD" in
mcode)
config_opts="" ;;
llvm)
config_opts="--with-llvm-config" ;;
llvm-3.5)
config_opts="--with-llvm-config=llvm-config-3.5 CXX=clang++" ;;
llvm-3.8)
config_opts="--with-llvm-config=llvm-config-3.8 CXX=clang++-3.8" ;;
docker)
echo "Check docker container!"
exit 0;;
*)
echo "$ANSI_RED[GHDL - build] Unknown build $BLD $ANSI_NOCOLOR"
exit 1;;
esac
echo "../configure --prefix=$prefix $config_opts"
../configure "--prefix=$prefix" $config_opts
echo "travis_fold:end:configure"

#--- make

echo "travis_fold:start:make"
travis_time_start
printf "$ANSI_YELLOW[GHDL] Make $ANSI_NOCOLOR\n"
make
travis_time_finish
echo "travis_fold:end:make"

echo "travis_fold:start:install"
printf "$ANSI_YELLOW[GHDL] Install $ANSI_NOCOLOR\n"
make install
cd ..
echo "travis_fold:end:install"

#--- package

echo "travis_fold:start:tar.bin"
printf "$ANSI_YELLOW[GHDL] Create package ${ANSI_DARKCYAN}${PKG_NAME}.tgz $ANSI_NOCOLOR\n"
tar -zcvf "${PKG_NAME}.tgz" -C "$prefix" .
echo "travis_fold:end:tar.bin"

#--- test

export ENABLECOLOR TASK
export GHDL="$prefix/bin/ghdl"
cd testsuite
failures=""

echo "travis_fold:start:tests.sanity"
travis_time_start
printf "$ANSI_YELLOW[Test] sanity $ANSI_NOCOLOR\n"
cd sanity
for d in [0-9]*; do
cd $d
if ./testsuite.sh > test.log 2>&1 ; then
echo "sanity $d: ok"
# Don't disp log
else
echo "${ANSI_RED}sanity $d: failed${ANSI_NOCOLOR}"
cat test.log
failures="$failures $d"
fi
cd ..
# Stop at the first failure
[ "$failures" = "" ] || break
done
cd ..
travis_time_finish
echo "travis_fold:end:tests.sanity"
[ "$failures" = "" ] || exit 1

if [ "$ISGPL" != "true" ]; then
echo "travis_fold:start:tests.gna"
travis_time_start
printf "$ANSI_YELLOW[Test] gna $ANSI_NOCOLOR\n"
cd gna
dirs=`./testsuite.sh --list-tests`
for d in $dirs; do
cd $d
if ./testsuite.sh > test.log 2>&1 ; then
echo "gna $d: ok"
# Don't disp log
else
echo "${ANSI_RED}gna $d: failed${ANSI_NOCOLOR}"
cat test.log
failures="$failures $d"
fi
cd ..
# Stop at the first failure
[ "$failures" = "" ] || break
done
cd ..
travis_time_finish
echo "travis_fold:end:tests.gna"
[ "$failures" = "" ] || exit 1
fi

echo "travis_fold:start:tests.vests"
travis_time_start
printf "$ANSI_YELLOW[Test] vests $ANSI_NOCOLOR\n"
cd vests
if ./testsuite.sh > vests.log 2>&1 ; then
echo "${ANSI_GREEN}Vests is OK$ANSI_NOCOLOR"
wc -l vests.log
else
cat vests.log
echo "${ANSI_RED}Vests failure$ANSI_NOCOLOR"
failures=vests
fi
cd ..
travis_time_finish
echo "travis_fold:end:tests.vests"
[ "$failures" = "" ] || exit 1

$GHDL --version
cd ..

#---

echo "[SUCCESSFUL]"
touch build_ok

+ 24
- 0
dist/linux/create.sh View File

@@ -0,0 +1,24 @@
#! /bin/sh
# This script is executed in the travis-ci environment.

set -e

. dist/linux/travis-utils.sh
. dist/ansi_color.sh
#disable_color

scriptdir=$(dirname $0)

for d in build run; do
currentdir="${scriptdir}/docker/$d"
for f in `ls $currentdir`; do
for tag in `grep -oP "FROM.*AS \K.*" ${currentdir}/$f`; do
echo "travis_fold:start:${f}-$tag"
travis_time_start
printf "$ANSI_BLUE[DOCKER build] ${d} : ${f} - ${tag}$ANSI_NOCOLOR\n"
docker build -t ghdl/${d}:${f}-${tag} --target $tag - < ${currentdir}/$f
travis_time_finish
echo "travis_fold:end:${f}-$tag"
done
done
done

+ 32
- 0
dist/linux/deploy2dockerhub.sh View File

@@ -0,0 +1,32 @@
#! /bin/sh

set -e

. dist/linux/travis-utils.sh
. dist/ansi_color.sh
#disable_color

# Skip deploy if we are in stage 0 (i.e. IMAGE="") and there is no '[ci images]' in the commit message
if [ "$1" = "skip" ] || [ "${1}$(echo $2 | grep -o '\[ci images\]')" = "" ]; then
printf "${ANSI_GREEN}SKIP DEPLOY2DOCKERHUB$ANSI_NOCOLOR\n";
exit 0;
fi

case $1 in
"") FILTER="/";;
*) FILTER="/ghdl /pkg";;
esac

docker login -u="$DOCKER_USER" -p="$DOCKER_PASS"
for key in $FILTER; do
for tag in `echo $(docker images ghdl$key* | awk -F ' ' '{print $1 ":" $2}') | cut -d ' ' -f2-`; do
if [ "$tag" = "REPOSITORY:TAG" ]; then break; fi
echo "travis_fold:start:`echo $tag | grep -oP 'ghdl/\K.*'`"
travis_time_start
printf "$ANSI_YELLOW[DOCKER push] ${tag}$ANSI_NOCOLOR\n"
docker push $tag
travis_time_finish
echo "travis_fold:end:`echo $tag | grep -oP 'ghdl/\K.*'`"
done
done
docker logout

+ 0
- 5
dist/linux/docker/build-fedora26+mcode View File

@@ -1,5 +0,0 @@
# Fedora 26
FROM fedora:26

RUN dnf --nodocs -y install gcc-gnat zlib-devel make \
&& dnf clean all

+ 0
- 7
dist/linux/docker/build-stretch+mcode View File

@@ -1,7 +0,0 @@
# Debian 9
FROM debian:stretch-slim

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
gnat gcc make zlib1g-dev \
&& apt-get clean

+ 0
- 7
dist/linux/docker/build-stretch+mcode+gpl View File

@@ -1,7 +0,0 @@
# Debian 9
FROM debian:stretch-slim

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
gnat gcc make zlib1g-dev \
&& apt-get clean

+ 0
- 7
dist/linux/docker/build-ubuntu14+llvm-3.8 View File

@@ -1,7 +0,0 @@
# Ubuntu 14
FROM ubuntu:trusty

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
gnat gcc make zlib1g-dev llvm-3.8-dev clang-3.8 \
&& apt-get clean

+ 0
- 7
dist/linux/docker/build-ubuntu14+mcode View File

@@ -1,7 +0,0 @@
# Ubuntu 14
FROM ubuntu:trusty

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
gnat gcc make zlib1g-dev \
&& apt-get clean

+ 11
- 0
dist/linux/docker/build/buster View File

@@ -0,0 +1,11 @@
# [build] Debian 10

FROM debian:buster-slim AS mcode

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
gnat gcc make zlib1g-dev \
&& apt-get autoclean && apt-get clean && apt-get autoremove


FROM mcode AS mcode-gpl

+ 12
- 0
dist/linux/docker/build/fedora26 View File

@@ -0,0 +1,12 @@
# [build] Fedora 26

FROM fedora:26 AS mcode

RUN dnf --nodocs -y install gcc-gnat zlib-devel make \
&& dnf clean all --enablerepo=\*


FROM mcode AS llvm

RUN dnf --nodocs -y install llvm-devel gcc-c++ clang \
&& dnf clean all --enablerepo=\*

+ 11
- 0
dist/linux/docker/build/stretch View File

@@ -0,0 +1,11 @@
# [build] Debian 9

FROM debian:stretch-slim AS mcode

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
gnat gcc make zlib1g-dev \
&& apt-get autoclean && apt-get clean && apt-get autoremove


FROM mcode AS mcode-gpl

+ 16
- 0
dist/linux/docker/build/ubuntu14 View File

@@ -0,0 +1,16 @@
# [build] Ubuntu 14

FROM ubuntu:trusty AS mcode

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
gnat gcc make zlib1g-dev \
&& apt-get autoclean && apt-get clean && apt-get autoremove


FROM mcode AS llvm-3.8

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
llvm-3.8-dev clang-3.8 \
&& apt-get autoclean && apt-get clean && apt-get autoremove

+ 16
- 0
dist/linux/docker/build/ubuntu16 View File

@@ -0,0 +1,16 @@
# [build] Ubuntu 16

FROM ubuntu:xenial AS mcode

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
gnat gcc make zlib1g-dev \
&& apt-get autoclean && apt-get clean && apt-get autoremove


FROM mcode AS llvm-3.9

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
llvm-3.9-dev clang-3.9 \
&& apt-get autoclean && apt-get clean && apt-get autoremove

+ 16
- 0
dist/linux/docker/build/ubuntu18 View File

@@ -0,0 +1,16 @@
# [build] Ubuntu 18

FROM ubuntu:bionic AS mcode

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
gnat gcc make zlib1g-dev \
&& apt-get autoclean && apt-get clean && apt-get autoremove


FROM mcode AS llvm-5.0

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
llvm-5.0-dev clang-5.0 \
&& apt-get autoclean && apt-get clean && apt-get autoremove

+ 10
- 0
dist/linux/docker/run/buster View File

@@ -0,0 +1,10 @@
# [run] Debian 10

FROM debian:buster-slim AS mcode

RUN apt-get update -qq \
&& apt-get -y install libgnat-7 gcc libc6-dev \
&& apt-get autoclean && apt-get clean && apt-get autoremove


FROM mcode AS mcode-gpl

+ 12
- 0
dist/linux/docker/run/fedora26 View File

@@ -0,0 +1,12 @@
# [run] Fedora 26

FROM fedora:26 AS mcode

RUN dnf --nodocs -y install libgnat gcc \
&& dnf clean all --enablerepo=\*


FROM mcode AS llvm

RUN dnf --nodocs -y install llvm-libs zlib-devel \
&& dnf clean all --enablerepo=\*

+ 10
- 0
dist/linux/docker/run/stretch View File

@@ -0,0 +1,10 @@
# [run] Debian 9

FROM debian:stretch-slim AS mcode

RUN apt-get update -qq \
&& apt-get -y install libgnat-6 gcc libc6-dev \
&& apt-get autoclean && apt-get clean && apt-get autoremove


FROM mcode AS mcode-gpl

+ 16
- 0
dist/linux/docker/run/ubuntu14 View File

@@ -0,0 +1,16 @@
# [run] Ubuntu 14

FROM ubuntu:trusty AS mcode

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
libgnat-4.6 gcc libc6-dev \
&& apt-get autoclean && apt-get clean && apt-get autoremove


FROM mcode AS llvm-3.8

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
libllvm-3.8 zlib1g-dev \
&& apt-get autoclean && apt-get clean && apt-get autoremove

+ 16
- 0
dist/linux/docker/run/ubuntu16 View File

@@ -0,0 +1,16 @@
# [run] Ubuntu 16

FROM ubuntu:xenial AS mcode

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
libgnat-4.9 gcc libc6-dev \
&& apt-get autoclean && apt-get clean && apt-get autoremove


FROM mcode AS llvm-3.9

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
libllvm-3.9 zlib1g-dev \
&& apt-get autoclean && apt-get clean && apt-get autoremove

+ 16
- 0
dist/linux/docker/run/ubuntu18 View File

@@ -0,0 +1,16 @@
# [run] Ubuntu 18

FROM ubuntu:bionic AS mcode

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
libgnat-7 gcc libc6-dev \
&& apt-get autoclean && apt-get clean && apt-get autoremove


FROM mcode AS llvm-5.0

RUN apt-get update -qq \
&& apt-get -y install --no-install-recommends \
libllvm5.0 zlib1g-dev \
&& apt-get autoclean && apt-get clean && apt-get autoremove

+ 114
- 0
dist/linux/test.sh View File

@@ -0,0 +1,114 @@
#! /bin/bash

. dist/linux/travis-utils.sh
. dist/ansi_color.sh
disable_color

echo "$0" "$@"

# Stop in case of error
set -e

# Transform long options to short ones
for arg in "$@"; do
shift
case "$arg" in
"--color"|"-color") set -- "$@" "-c";;
"--gpl"|"-gpl") set -- "$@" "-g";;
*) set -- "$@" "$arg"
esac
done
# Parse args
while getopts ":b:p:cg" opt; do
case $opt in
c) enable_color;;
g) ISGPL=true;;
\?) printf "$ANSI_RED[GHDL - test] Invalid option: -$OPTARG $ANSI_NOCOLOR\n" >&2
exit 1 ;;
:) printf "$ANSI_RED[GHDL - test] Option -$OPTARG requires an argument. $ANSI_NOCOLOR\n" >&2
exit 1 ;;
esac
done

rm -f test_ok

export ENABLECOLOR
if [ "$GHDL" = "" ]; then
export GHDL="$prefix/bin/ghdl"
fi
cd testsuite
failures=""

echo "travis_fold:start:tests.sanity"
travis_time_start
printf "$ANSI_YELLOW[GHDL - test] sanity $ANSI_NOCOLOR\n"
cd sanity
for d in [0-9]*; do
cd $d
if ./testsuite.sh > test.log 2>&1 ; then
echo "sanity $d: ok"
# Don't disp log
else