...
 
Commits (6)

Too many changes to show.

To preserve performance only 1000 of 1000+ files are displayed.

# Contributing to GHDL
GHDL is a free and open source software brought to you with :heart: by [@tgingold](https://github.com/tgingold) and [contributors](https://github.com/ghdl/ghdl/graphs/contributors). So, first off, thanks for taking the time to contribute. We need all the help we can get :thumbsup:
- Found a bug? See how to [report a bug](http://ghdl.readthedocs.io/en/latest/contribute.html#reporting-bugs) and open a [Bug report](https://github.com/ghdl/ghdl/issues/new?template=bug_report.md).
- Got a feature idea? See how to [request enhancements](http://ghdl.readthedocs.io/en/latest/contribute.html#requesting-enhancements) and open a [Feature request](https://github.com/ghdl/ghdl/issues/new?template=feature_request.md).
- Want to contribute modifications to the codebase? See how to [contribute modifications](http://ghdl.readthedocs.io/en/latest/contribute.html#fork-modify-and-pull-request) and open a [Pull Request (PR)](https://github.com/ghdl/ghdl/compare/).
- Spread the word. Talk to your friends and colleagues about how awesome GHDL is!
- If you want to have any specific talk, e.g. add VHDL design examples, come to [gitter.im/ghdl1/Lobby](https://gitter.im/ghdl1/Lobby).
---
name: Bug report
about: Create a report to help us improve
---
**Description**
A clear and concise description of what the issue is about.
**Expected behaviour**
What you expected to happen, and what is happening instead.
**Context**
Please paste the `GHDL Bug occurred` log block here. Also, provide the following information:
- OS:
- Origin:
- [ ] Package manager. Repo:
- [ ] Released binaries. Tarball:
- [ ] Built from sources. Commit SHA:
**Additional context**
Add any other context about the problem here. If applicable, add screenshots to help explain your problem.
**How to reproduce?**
Tell us how to reproduce this issue. Please provide a Minimal Working Example (MWE), that is compatible with [issue-runner](https://github.com/1138-4EB/issue-runner). With sample code it's easier to reproduce the bug and it's much faster to fix it. For example:
```
#>> ent.vhd
entity ent is
end entity;
architecture a of ent is
begin
process begin
report "Hello world" severity note;
wait;
end process;
end;
#>> sim.sh
ghdl -a ent.vhd
ghdl --elab-run ent
#>> run.sh
docker run --rm -tv /$(pwd):/src:z -w //src ghdl/ghdl:buster-mcode sh -c ./sim.sh
#>> end
```
Note that `run.sh` is used to execute `sim.sh` inside a docker container. Please, put your commands in `sim.sh` and just copy `run.sh` from the example. Using `ghdl/ghdl:*` docker images to run the MWEs ensures that the latest available GHDL is used.
**Files**
A list of relevant files for this issue. Large files can be uploaded one-by-one or in a tarball/zipfile. See [1138-4EB/issue-runner#parser](https://github.com/1138-4EB/issue-runner#parser).
**Checklist**
Before submitting your issue, please review the following checklist:
- [ ] Add `GHDL Bug occurred` log block
- [ ] Add a MWE
- [ ] Try the latest version
---
name: Feature request
about: Suggest an idea for this project
---
**Is your feature request related to a problem? Please describe.**
Add a clear and concise description of what the problem is. E.g. *I'm always frustrated when [...]*
**Describe the solution you'd like**
Add a clear and concise description of what you want to happen.
**Describe alternatives you've considered**
Add a clear and concise description of any alternative solutions or features you've considered.
**Additional context**
Add any other context or screenshots about the feature request here.
**Description** Please explain the changes you made here.
If the feature changes current behaviour, explain why your solution is better.
:rotating_light: Before submitting your PR, please read [contribute](http://ghdl.readthedocs.io/en/latest/contribute.html#fork-modify-and-pull-request) in the [Docs](http://ghdl.readthedocs.io/en/latest/index.html), and review the following checklist:
- [ ] DO indicate which issues are either fixed or closed by this PR. See [GitHub Help: Closing issues using keywords](https://help.github.com/articles/closing-issues-via-commit-messages/).
**When contributing to the GHDL codebase...**
- [ ] DO make sure you are requesting to **pull a topic/feature/bugfix branch** (right side). Don't request your master!
- [ ] DO make sure you are making a pull request against the **master branch** (left side). Also you should start *your branch* off *our master*.
- [ ] DO make sure that GHDL can be successfully built. See [Building GHDL](https://github.com/ghdl/ghdl#building-ghdl).
- [ ] CONSIDER adding a unit test if your PR resolves an issue.
- [ ] CONSIDER modifying the docs, at least in the TODO, if your contribution is relevant to any of the content.
- [ ] AVOID breaking the continuous integration build.
- [ ] AVOID breaking the testsuite.
**When contributing to the docs...**
- [ ] DO make sure that the build is successful. See [ghdl/ghdl#572 (issuecomment-390466024)](https://github.com/ghdl/ghdl/issues/572#issuecomment-390466024).
**Further comments**
If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did, what alternatives you considered, etc.
:heart: Thank you!
......@@ -8,33 +8,13 @@ sudo: required
services: docker
language: minimal
install: skip
script: "./dist/linux/travis-ci.sh"
script: "./dist/travis/travis-ci.sh"
addons:
apt:
packages:
- docker-ce
deploy:
- &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: 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:
......@@ -45,38 +25,35 @@ env:
# - 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
- IMAGE=fedora28+mcode
- IMAGE=fedora28+llvm
stages:
- create ghdl/build and ghdl/run images
- test
deploy:
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: ghdl/ghdl
all_branches: true
tags: true
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.
# Additional jobs are described in stage 'test' for the macos build.
# The constraints above are used, except explicitly overriden.
- stage: test
- &osx
os: osx
language: c
osx_image: xcode7.3
osx_image: xcode9.3
install: true
cache:
directories:
- gnat
env: IMAGE=macosx+mcode
deploy:
- <<: *deploy-releases
# - <<: *osx
# osx_image: xcode8.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).
......@@ -79,7 +79,7 @@ ifeq "$(build_mode)" "coverage"
OPT_FLAGS+=-fprofile-arcs -ftest-coverage
endif
GNATFLAGS=-gnaty3befhkmr -gnatwa -gnatf -gnat05 $(OPT_FLAGS) $(ADA_FLAGS)
GNATFLAGS=-gnaty3befhkmr -gnatwa -gnatf $(OPT_FLAGS) $(ADA_FLAGS)
GRT_FLAGS=$(OPT_FLAGS)
WARN_CFLAGS=-Wall
......@@ -184,7 +184,7 @@ install.mcode: install.mcode.program install.vhdllib install.vpi
oread-mcode$(EXEEXT): force
$(MAKE) -f $(srcdir)/src/ortho/mcode/Makefile \
ortho_srcdir=$(srcdir)/src/ortho ortho_exec=$@ \
GNAT_FLAGS="-aI$(srcdir)/src/ortho/oread $(GNATFLAGS)" all
GNATFLAGS="-aI$(srcdir)/src/ortho/oread $(GNATFLAGS)" all
#################### For gcc backend ##############################
......@@ -217,8 +217,9 @@ copy-sources.gcc: version.ads
5.*) gcc_ortho_lang=ortho-lang-5.c ;; \
6 | 6.*) gcc_ortho_lang=ortho-lang-6.c ;; \
7.*) gcc_ortho_lang=ortho-lang-7.c ;; \
8.*) gcc_ortho_lang=ortho-lang-8.c ;; \
*) echo "Mismatch gcc version from $(gcc_src_dir)"; \
echo "Need gcc version 4.9.x, 5.x, 6.x or 7.x"; \
echo "Need gcc version 4.9.x, 5.x, 6.x, 7.x or 8.x"; \
exit 1 ;; \
esac; \
$(CP) -p $(srcdir)/src/ortho/gcc/$$gcc_ortho_lang \
......@@ -250,7 +251,7 @@ GHDL_GCC_INCFLAGS=$(GHDL_COMMON_INCFLAGS)
ghdl1-gcc$(EXEEXT): version.ads force
$(MAKE) -f $(srcdir)/src/ortho/gcc/Makefile \
ortho_srcdir=$(srcdir)/src/ortho ortho_exec=$@ \
GNAT_FLAGS="$(GHDL_GCC_INCFLAGS) $(GNATFLAGS)" all
GNATFLAGS="$(GHDL_GCC_INCFLAGS) $(GNATFLAGS)" all
ghdl_gcc$(EXEEXT): version.ads force
$(GNATMAKE) $(GHDL_GCC_INCFLAGS) -aI$(srcdir)/src/ghdldrv \
......@@ -262,13 +263,13 @@ libs.vhdl.local_gcc: ghdl_gcc$(EXEEXT) ghdl1-gcc$(EXEEXT)
ghdl1-debug$(EXEEXT): version.ads force
$(MAKE) -f $(srcdir)/src/ortho/debug/Makefile \
ortho_srcdir=$(srcdir)/src/ortho ortho_exec=$@ \
GNAT_FLAGS="$(GHDL_GCC_INCFLAGS) $(GNATFLAGS)" \
GNATFLAGS="$(GHDL_GCC_INCFLAGS) $(GNATFLAGS)" \
GNATMAKE="$(GNATMAKE)" all
oread-gcc$(EXEEXT): force
$(MAKE) -f $(srcdir)/src/ortho/gcc/Makefile \
ortho_srcdir=$(srcdir)/src/ortho ortho_exec=$@ \
GNAT_FLAGS="-aI$(srcdir)/src/ortho/oread $(GNATFLAGS)" all
GNATFLAGS="-aI$(srcdir)/src/ortho/oread $(GNATFLAGS)" all
#################### For llvm backend ##############################
......@@ -296,6 +297,9 @@ libs.vhdl.llvmjit: ghdl_llvm_jit$(EXEEXT)
libs.vhdl.llvm: ghdl_llvm$(EXEEXT) ghdl1-llvm$(EXEEXT)
$(MAKE) -f $(srcdir)/libraries/Makefile.inc $(LIBVHDL_FLAGS_TO_PASS) GHDL=$(PWD)/ghdl_llvm$(EXEEXT) GHDL_FLAGS="--GHDL1=$(PWD)/ghdl1-llvm$(EXEEXT) $(LIB_CFLAGS)" vhdl.libs.all libs.vhdl.standard
libs.vhdl.debug-llvm: ghdl_llvm$(EXEEXT) ghdl1-debug$(EXEEXT)
$(MAKE) -f $(srcdir)/libraries/Makefile.inc $(LIBVHDL_FLAGS_TO_PASS) GHDL=$(PWD)/ghdl_llvm$(EXEEXT) GHDL_FLAGS="--GHDL1=$(PWD)/ghdl1-debug$(EXEEXT) $(LIB_CFLAGS)" vhdl.libs.all libs.vhdl.standard
ghdl_llvm$(EXEEXT): version.ads force
$(GNATMAKE) $(GHDL_LLVM_INCFLAGS) -aI$(srcdir)/src/ghdldrv $(GNATFLAGS)\
ghdl_llvm $(GNAT_BARGS) -largs $(LDFLAGS) $(GNAT_LARGS)
......@@ -303,7 +307,7 @@ ghdl_llvm$(EXEEXT): version.ads force
ghdl1-llvm$(EXEEXT): version.ads force
$(MAKE) -f $(srcdir)/src/ortho/$(llvm_be)/Makefile \
ortho_srcdir=$(srcdir)/src/ortho ortho_exec=$@ \
GNAT_FLAGS="$(GHDL_LLVM_INCFLAGS) $(GNATFLAGS)" LDFLAGS="$(LDFLAGS)" \
GNATFLAGS="$(GHDL_LLVM_INCFLAGS) $(GNATFLAGS)" LDFLAGS="$(LDFLAGS)" \
LLVM_CONFIG="$(LLVM_CONFIG)" CXX="$(CXX)" GNATMAKE="$(GNATMAKE)" \
all
......@@ -311,7 +315,7 @@ oread-llvm$(EXEEXT): force
$(MAKE) -f $(srcdir)/src/ortho/$(llvm_be)/Makefile \
ortho_srcdir=$(srcdir)/src/ortho ortho_exec=$@ \
GNATMAKE="$(GNATMAKE)" \
GNAT_FLAGS="-aI$(srcdir)/src/ortho/oread $(GNATFLAGS)" \
GNATFLAGS="-aI$(srcdir)/src/ortho/oread $(GNATFLAGS)" \
LLVM_CONFIG="$(LLVM_CONFIG)" CXX="$(CXX)"
install.llvm.program: install.dirs ghdl1-llvm$(EXEEXT) ghdl_llvm$(EXEEXT)
......@@ -343,7 +347,7 @@ LIBGHDL_INCFLAGS=$(GHDL_COMMON_INCFLAGS) -aI$(srcdir)/src/vhdl/python -aI$(srcdi
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)
$(GNATMAKE) -I- -aI. -D pic -z libghdl -o $@ $(GNATFLAGS) $(PIC_FLAGS) $(LIBGHDL_INCFLAGS) -bargs -shared -Llibghdl_ -largs -shared $(SHLIB_FLAGS)
all.libghdl.true: $(libghdl_name)
all.libghdl.false:
......@@ -375,7 +379,7 @@ install.libghdlsynth.static: libghdlsynth.a install.libghdlsynth.include
$(INSTALL_DATA) -p ghdlsynth.link $(DESTDIR)$(libdir)/
install.libghdlsynth.shared: libghdlsynth$(SOEXT) install.libghdlsynth.include
$(INSTALL_DATA) -p libghdlsynth$(SOEXT) $(DESTDIR)$(libdir)/
$(INSTALL_PROGRAM) -p libghdlsynth$(SOEXT) $(DESTDIR)$(libdir)/
################ ghwdump #################################################
......@@ -411,20 +415,20 @@ libghdlvpi$(SOEXT): vpi_thunk.o
all.vpi: libghdlvpi$(SOEXT)
install.vpi: all.vpi install.dirs
$(INSTALL_DATA) -p libghdlvpi$(SOEXT) $(DESTDIR)$(libdir)/
$(INSTALL_PROGRAM) -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/
$(INSTALL_PROGRAM) -p libghdlvpi$(SOEXT) lib/
################ Libraries ###############################################
LIBSRC_DIR:=$(srcdir)/libraries
LIBDST_DIR:=$(libdirsuffix)
VHDLLIB_SUBDIRS_COMMON= src/std src/synopsys src/openieee \
VHDLLIB_SUBDIRS_COMMON= src/std src/synopsys \
std/v87 ieee/v87 synopsys/v87 \
std/v93 ieee/v93 synopsys/v93 \
std/v08
......@@ -436,7 +440,7 @@ VHDLLIB_SUBDIRS_FULL= src/ieee src/vital95 src/vital2000 src/mentor \
ifeq ($(enable_openieee),false)
VHDLLIB_SUBDIRS=$(VHDLLIB_SUBDIRS_COMMON) $(VHDLLIB_SUBDIRS_FULL)
else
VHDLLIB_SUBDIRS=$(VHDLLIB_SUBDIRS_COMMON)
VHDLLIB_SUBDIRS=$(VHDLLIB_SUBDIRS_COMMON) src/openieee
endif
install.dirs:
......
......@@ -124,9 +124,10 @@ case $srcdir in
*)
# Use a Windows path on windows.
case "$OS" in
Windows_NT) abs_srcdir="`pwd -W`/$srcdir" ;;
*) abs_srcdir=`pwd`/$srcdir ;;
Windows_NT) curdir=`pwd -W 2>/dev/null || pwd` ;;
*) curdir=`pwd` ;;
esac
abs_srcdir=$curdir/$srcdir
;;
esac
......@@ -213,43 +214,45 @@ fi
# For llvm backend, check llvm-config
if test $backend = llvm; then
llvm_version=`"$llvm_config" --version 2>/dev/null`
if [ $? != 0 ]; then
echo "cannot run $llvm_config"
exit 1
fi
if check_version 3.5 $llvm_version; then
llvm_be=llvm
elif check_version 3.6 $llvm_version ||
check_version 3.7 $llvm_version ||
check_version 3.8 $llvm_version;
then
echo "Debugging is not enabled with llvm $llvm_version"
llvm_be=llvm-nodebug
llvm_version=`"$llvm_config" --version 2>/dev/null`
if [ $? != 0 ]; then
echo "cannot run $llvm_config"
exit 1
fi
if check_version 3.5 $llvm_version; then
llvm_be=llvm
elif check_version 3.6 $llvm_version ||
check_version 3.7 $llvm_version ||
check_version 3.8 $llvm_version ||
false; then
echo "Debugging is not enabled with llvm $llvm_version"
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 ||
check_version 6.0 $llvm_version ||
false; then
echo "Debugging is not enabled with llvm $llvm_version"
llvm_be=llvm4-nodebug
else
echo "Unhandled version llvm $llvm_version"
exit 1
fi
# For llvm, the c++ compiler is used for linking so that the standard c++
# library is included. However, the linker needs the no_compact_unwind
# flag because code generated by gcc is not compatible with compact unwind.
case "$build" in
*darwin*) LDFLAGS="$LDFLAGS -Wl,-no_compact_unwind" ;;
esac
elif check_version 3.9 $llvm_version ||
check_version 4.0 $llvm_version ||
check_version 5.0 $llvm_version ||
check_version 6.0 $llvm_version ||
check_version 7.0 $llvm_version ||
false; then
echo "Debugging is not enabled with llvm $llvm_version"
llvm_be=llvm4-nodebug
else
echo "Unhandled version llvm $llvm_version"
exit 1
fi
# For llvm, the c++ compiler is used for linking so that the standard c++
# library is included. However, the linker needs the no_compact_unwind
# flag because code generated by gcc is not compatible with compact unwind.
case "$build" in
*darwin*) LDFLAGS="$LDFLAGS -Wl,-no_compact_unwind" ;;
esac
fi
# Define default file extensions for Windows or Linux-like systems and
# use -fPIC or not.
case "$build" in
*mingw*) SOEXT=".dll"; EXEEXT=".exe"; PIC_FLAGS="";;
*mingw* | *cygwin*)
SOEXT=".dll"; EXEEXT=".exe"; PIC_FLAGS="";;
*darwin*) SOEXT=".dylib"; EXEEXT=""; PIC_FLAGS="";;
*) SOEXT=".so"; EXEEXT=""; PIC_FLAGS="-fPIC";;
esac
......@@ -346,11 +349,10 @@ fi
# Also update dist/windows/mcode/default_paths.ads if you change this
# template.
echo "Generate default_paths.ads"
curdir=`pwd`
sed -e "s%@COMPILER_GCC@%ghdl1-gcc$EXEEXT%" \
-e "s%@COMPILER_DEBUG@%ghdl1-debug$EXEEXT%" \
-e "s%@COMPILER_MCODE@%ghdl1-mcode$EXEEXT%" \
-e "s%@COMPILER_LLVM@%bin/ghdl1-llvm$EXEEXT%" \
-e "s%@COMPILER_LLVM@%ghdl1-llvm$EXEEXT%" \
-e "s%@POST_PROCESSOR@%oread-$backend%" \
-e "s%@INSTALL_PREFIX@%$prefix%" \
-e "s%@LIB_PREFIX@%$libdirsuffix%" \
......
ghdl (0.35+git20181129+dfsg-1) UNRELEASED; urgency=medium
* New upstream release
* Refresh modify-install-paths
* Allow builds with LLVM 7+ (Closes: #912564)
* Switch to GCC 8 (Closes: #915734)
* Add dependency on zlib1g-dev for gcc and LLVM backends (Closes: #913945)
-- Jonathan McDowell <noodles@earth.li> Tue, 11 Dec 2018 20:16:23 +0000
ghdl (0.35+git20180503+dfsg-2) unstable; urgency=medium
* Fix disabling mcode backend building on non-x86
......
......@@ -4,16 +4,14 @@ Priority: optional
Maintainer: Debian Electronics Team <pkg-electronics-devel@lists.alioth.debian.org>
Uploaders: Andreas Bombe <aeb@debian.org>
Build-Depends: debhelper (>= 11),
gnat-7,
gcc-7-source <!pkg.ghdl.nogcc>,
gnat-8,
gcc-8-source <!pkg.ghdl.nogcc>,
libisl-dev (>= 0.14) <!pkg.ghdl.nogcc>,
libmpc-dev (>= 1.0) <!pkg.ghdl.nogcc>,
libmpfr-dev (>= 3.0.0-9~) <!pkg.ghdl.nogcc>,
libgmp-dev (>= 2:5.0.1~) <!pkg.ghdl.nogcc>,
llvm-dev (>= 1:3.5) <!pkg.ghdl.nollvm>,
llvm-dev (<< 1:7.0~) <!pkg.ghdl.nollvm>,
clang (>= 1:3.5) <!pkg.ghdl.nollvm>,
clang (<< 1:7.0~) <!pkg.ghdl.nollvm>,
zlib1g-dev
Standards-Version: 4.2.0
Homepage: https://github.com/ghdl/ghdl
......@@ -66,7 +64,8 @@ Description: VHDL compiler/simulator (mcode backend)
Package: ghdl-gcc
Architecture: any
Build-Profiles: <!pkg.ghdl.nogcc>
Depends: ghdl (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends}
Depends: ghdl (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends},
zlib1g-dev
Description: VHDL compiler/simulator (GCC backend)
GHDL is a compiler and simulator for VHDL, a Hardware Description Language.
GHDL is not an interpreter: it allows you to analyse and elaborate sources to
......@@ -78,7 +77,8 @@ Description: VHDL compiler/simulator (GCC backend)
Package: ghdl-llvm
Architecture: any
Build-Profiles: <!pkg.ghdl.nollvm>
Depends: ghdl (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends}
Depends: ghdl (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends},
zlib1g-dev
Description: VHDL compiler/simulator (LLVM backend)
GHDL is a compiler and simulator for VHDL, a Hardware Description Language.
GHDL is not an interpreter: it allows you to analyse and elaborate sources to
......
Description: Patch installation paths for Debian packaging
Author: Andreas Bombe <aeb@debian.org>
Last-Update: 2018-01-12
Last-Update: 2018-12-11
---
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
--- a/Makefile.in
+++ b/Makefile.in
@@ -26,6 +26,7 @@
Index: ghdl/Makefile.in
===================================================================
--- ghdl.orig/Makefile.in
+++ ghdl/Makefile.in
@@ -26,6 +26,7 @@ prefix=@prefix@
backend=@backend@
libdirsuffix=@libdirsuffix@
libdirreverse=@libdirreverse@
......@@ -13,7 +15,7 @@ This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
EXEEXT=@EXEEXT@
SOEXT=@SOEXT@
PIC_FLAGS=@PIC_FLAGS@
@@ -47,8 +48,8 @@
@@ -47,8 +48,8 @@ INSTALL_DATA=install -m 644
PWD=$(CURDIR)
DESTDIR=
bindir=$(prefix)/bin
......@@ -24,7 +26,7 @@ This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
MKDIR=mkdir
LN=ln -s
CP=cp
@@ -56,7 +57,7 @@
@@ -56,7 +57,7 @@ MV=mv
SED=sed
GRT_RANLIB=ranlib
......@@ -33,7 +35,7 @@ This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
ifeq "$(enable_checks)" "true"
# Debug + checks
@@ -179,7 +180,7 @@
@@ -179,7 +180,7 @@ libs.vhdl.mcode: ghdl_mcode$(EXEEXT)
$(MAKE) -f $(srcdir)/libraries/Makefile.inc $(LIBVHDL_FLAGS_TO_PASS) GHDL=$(PWD)/ghdl_mcode$(EXEEXT) GHDL_FLAGS="" VHDL_COPY_OBJS=no vhdl.libs.all
install.mcode.program: install.dirs ghdl_mcode$(EXEEXT)
......@@ -42,7 +44,7 @@ This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
install.mcode: install.mcode.program install.vhdllib install.vpi
@@ -317,8 +318,8 @@
@@ -321,8 +322,8 @@ oread-llvm$(EXEEXT): force
LLVM_CONFIG="$(LLVM_CONFIG)" CXX="$(CXX)"
install.llvm.program: install.dirs ghdl1-llvm$(EXEEXT) ghdl_llvm$(EXEEXT)
......@@ -53,9 +55,11 @@ This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
install.llvm: install.llvm.program install.vhdllib install.grt install.vpi
--- a/configure
+++ b/configure
@@ -19,6 +19,7 @@
Index: ghdl/configure
===================================================================
--- ghdl.orig/configure
+++ ghdl/configure
@@ -19,6 +19,7 @@ MAKE=${MAKE:-make}
LDFLAGS=
prefix=/usr/local
libdirsuffix=lib/ghdl
......@@ -63,7 +67,7 @@ This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
libdirreverse=../..
gcc_src_dir=
llvm_config=
@@ -37,7 +38,7 @@
@@ -37,7 +38,7 @@ PIC_FLAGS=-fPIC