ghdl: update to 1.0.0

This commit is contained in:
q66 2021-05-16 23:47:21 +02:00
parent 17141b48ed
commit 9cf3620c43
5 changed files with 89 additions and 38 deletions

View File

@ -0,0 +1,49 @@
From 396eb764f49666616063d4239df83b5aed961fff Mon Sep 17 00:00:00 2001
From: Jeroen Van den Keybus <jeroen.vandenkeybus@gmail.com>
Date: Mon, 26 Apr 2021 20:17:40 +0200
Subject: [PATCH] Migrate deprecated DebugLoc::get to DILocation::get
---
src/ortho/llvm6/llvm-cbindings.cpp | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/ortho/llvm6/llvm-cbindings.cpp b/src/ortho/llvm6/llvm-cbindings.cpp
index f82845ffcd..98470d8fab 100644
--- a/src/ortho/llvm6/llvm-cbindings.cpp
+++ b/src/ortho/llvm6/llvm-cbindings.cpp
@@ -1254,7 +1254,7 @@ new_var_decl(ODnode *Res, OIdent Ident, OStorage Storage, OTnode Atype)
DebugCurrentLine, Atype->Dbg, true);
DBuilder->insertDeclare
(unwrap(Decl), D, DBuilder->createExpression(),
- DebugLoc::get(DebugCurrentLine, 0, DebugCurrentScope),
+ DILocation::get(DebugCurrentScope->getContext(), DebugCurrentLine, 0, DebugCurrentScope),
unwrap(LLVMGetInsertBlock(DeclBuilder)));
}
#endif
@@ -1597,7 +1597,7 @@ start_subprogram_body(ODnodeSubprg *Func)
DebugCurrentScope = DebugCurrentSubprg;
unwrap(Builder)->SetCurrentDebugLocation
- (DebugLoc::get(DebugCurrentLine, 0, DebugCurrentScope));
+ (DILocation::get(DebugCurrentScope->getContext(), DebugCurrentLine, 0, DebugCurrentScope));
}
if (FlagDebug) {
@@ -1612,7 +1612,7 @@ start_subprogram_body(ODnodeSubprg *Func)
DebugCurrentFile, DebugCurrentLine, Inter->Dtype->Dbg, true);
DBuilder->insertDeclare
(unwrap(Var), D, DBuilder->createExpression(),
- DebugLoc::get(DebugCurrentLine, 0, DebugCurrentSubprg),
+ DILocation::get(DebugCurrentSubprg->getContext(), DebugCurrentLine, 0, DebugCurrentSubprg),
unwrap(LLVMGetInsertBlock(DeclBuilder)));
LLVMBuildStore(DeclBuilder, Inter->Ref, Var);
Inter->Ref = Var;
@@ -2759,7 +2759,7 @@ new_debug_line_stmt (unsigned Line)
if (FlagDebugLines && Line != DebugCurrentLine) {
DebugCurrentLine = Line;
unwrap(Builder)->SetCurrentDebugLocation
- (DebugLoc::get(DebugCurrentLine, 0, DebugCurrentScope));
+ (DILocation::get(DebugCurrentScope->getContext(), DebugCurrentLine, 0, DebugCurrentScope));
}
#endif
}

View File

@ -7,10 +7,10 @@ Last-Update: 2020-03-28
--- ---
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
diff --git a/Makefile.in b/Makefile.in diff --git a/Makefile.in b/Makefile.in
index 9a6b1731..3aba6532 100644 index e4923c2..c94853f 100644
--- a/Makefile.in --- a/Makefile.in
+++ b/Makefile.in +++ b/Makefile.in
@@ -26,6 +26,7 @@ prefix=@prefix@ @@ -24,6 +24,7 @@ prefix=@prefix@
backend=@backend@ backend=@backend@
libdirsuffix=@libdirsuffix@ libdirsuffix=@libdirsuffix@
libdirreverse=@libdirreverse@ libdirreverse=@libdirreverse@
@ -18,7 +18,7 @@ index 9a6b1731..3aba6532 100644
EXEEXT=@EXEEXT@ EXEEXT=@EXEEXT@
SOEXT=@SOEXT@ SOEXT=@SOEXT@
PIC_FLAGS=@PIC_FLAGS@ PIC_FLAGS=@PIC_FLAGS@
@@ -48,8 +49,8 @@ INSTALL_DATA=install -m 644 @@ -46,8 +47,8 @@ INSTALL_DATA=install -m 644
PWD=$(CURDIR) PWD=$(CURDIR)
DESTDIR= DESTDIR=
bindir=$(prefix)/bin bindir=$(prefix)/bin
@ -29,7 +29,7 @@ index 9a6b1731..3aba6532 100644
MKDIR=mkdir MKDIR=mkdir
LN=ln -s LN=ln -s
CP=cp CP=cp
@@ -192,7 +193,7 @@ libs.vhdl.mcode: ghdl_mcode$(EXEEXT) @@ -200,7 +201,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 $(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) install.mcode.program: install.dirs ghdl_mcode$(EXEEXT)
@ -38,7 +38,7 @@ index 9a6b1731..3aba6532 100644
uninstall.mcode.program: uninstall.mcode.program:
$(RM) $(DESTDIR)$(bindir)/ghdl$(EXEEXT) $(RM) $(DESTDIR)$(bindir)/ghdl$(EXEEXT)
@@ -355,8 +356,8 @@ oread-llvm$(EXEEXT): force @@ -372,8 +373,8 @@ oread-llvm$(EXEEXT): force
LLVM_CONFIG="$(LLVM_CONFIG)" CXX="$(CXX)" LLVM_CONFIG="$(LLVM_CONFIG)" CXX="$(CXX)"
install.llvm.program: install.dirs ghdl1-llvm$(EXEEXT) ghdl_llvm$(EXEEXT) install.llvm.program: install.dirs ghdl1-llvm$(EXEEXT) ghdl_llvm$(EXEEXT)
@ -47,13 +47,13 @@ index 9a6b1731..3aba6532 100644
+ $(INSTALL_PROGRAM) ghdl_llvm$(EXEEXT) $(DESTDIR)$(bindir)/ghdl-llvm$(EXEEXT) + $(INSTALL_PROGRAM) ghdl_llvm$(EXEEXT) $(DESTDIR)$(bindir)/ghdl-llvm$(EXEEXT)
+ $(INSTALL_PROGRAM) ghdl1-llvm$(EXEEXT) $(DESTDIR)$(libdir)/ghdl1-llvm$(EXEEXT) + $(INSTALL_PROGRAM) ghdl1-llvm$(EXEEXT) $(DESTDIR)$(libdir)/ghdl1-llvm$(EXEEXT)
uninstall.llvm.program: test.llvm: ghdl_llvm$(EXEEXT)
$(RM) $(DESTDIR)$(bindir)/ghdl1-llvm$(EXEEXT) cd $(srcdir)/testsuite; GHDL=$(CURDIR)/ghdl_llvm$(EXEEXT) ./testsuite.sh
diff --git a/configure b/configure diff --git a/configure b/configure
index ce052534..22e1335a 100755 index 917215a..c1c1a6d 100755
--- a/configure --- a/configure
+++ b/configure +++ b/configure
@@ -34,6 +34,7 @@ MAKE=${MAKE:-make} @@ -32,6 +32,7 @@ MAKE=${MAKE:-make}
LDFLAGS= LDFLAGS=
prefix=/usr/local prefix=/usr/local
libdirsuffix=lib/ghdl libdirsuffix=lib/ghdl
@ -61,16 +61,16 @@ index ce052534..22e1335a 100755
libdirreverse=../.. libdirreverse=../..
gcc_src_dir= gcc_src_dir=
llvm_config= llvm_config=
@@ -54,7 +55,7 @@ PIC_FLAGS=-fPIC @@ -52,7 +53,7 @@ PIC_FLAGS=-fPIC
show_help=no show_help=no
progname=$0 progname=$0
-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_pic enable_werror enable_checks enable_openieee enable_libghdl libghdl_version ghdl_version" -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_pic enable_werror enable_checks enable_gplcompat enable_libghdl libghdl_version ghdl_version"
+subst_vars="CC CXX GNATMAKE MAKE CFLAGS LDFLAGS build srcdir abs_srcdir prefix backend libdirsuffix libdirreverse incdirsuffix gcc_src_dir llvm_config llvm_be backtrace_lib build_mode EXEEXT SOEXT PIC_FLAGS default_pic enable_werror enable_checks enable_openieee enable_libghdl libghdl_version ghdl_version" +subst_vars="CC CXX GNATMAKE MAKE CFLAGS LDFLAGS build srcdir abs_srcdir prefix backend libdirsuffix libdirreverse incdirsuffix gcc_src_dir llvm_config llvm_be backtrace_lib build_mode EXEEXT SOEXT PIC_FLAGS default_pic enable_werror enable_checks enable_gplcompat enable_libghdl libghdl_version ghdl_version"
# Find srcdir # Find srcdir
srcdir=`dirname $progname` srcdir=`dirname $progname`
@@ -93,6 +94,8 @@ for opt do @@ -91,6 +92,8 @@ for opt do
;; ;;
--prefix=*) prefix="$optarg";; --prefix=*) prefix="$optarg";;
--srcdir=*) srcdir="$optarg";; --srcdir=*) srcdir="$optarg";;
@ -79,7 +79,7 @@ index ce052534..22e1335a 100755
--with-gcc=*) gcc_src_dir="$optarg"; backend=gcc;; --with-gcc=*) gcc_src_dir="$optarg"; backend=gcc;;
--with-llvm=*) --with-llvm=*)
echo "--with-llvm is deprecated, use --with-llvm-config" echo "--with-llvm is deprecated, use --with-llvm-config"
@@ -128,6 +131,8 @@ Usage: configure [options] @@ -126,6 +129,8 @@ Usage: configure [options]
Options [defaults in brackets]: Options [defaults in brackets]:
--prefix=PREFIX install in PREFIX [$prefix] --prefix=PREFIX install in PREFIX [$prefix]
--srcdir=SRCDIR source code path [$srcdir] --srcdir=SRCDIR source code path [$srcdir]
@ -88,7 +88,7 @@ index ce052534..22e1335a 100755
--with-gcc=DIR use gcc backend from DIR --with-gcc=DIR use gcc backend from DIR
--with-llvm-config[=LLVM-CONFIG] use llvm backend [llvm-config] --with-llvm-config[=LLVM-CONFIG] use llvm backend [llvm-config]
--with-backtrace-lib=LIB.a link with libbacktrace LIB.a to display a --with-backtrace-lib=LIB.a link with libbacktrace LIB.a to display a
@@ -405,10 +410,11 @@ echo "Generate default_paths.ads" @@ -400,10 +405,11 @@ echo "Generate default_paths.ads"
sed -e "s%@COMPILER_GCC@%ghdl1-gcc$EXEEXT%" \ sed -e "s%@COMPILER_GCC@%ghdl1-gcc$EXEEXT%" \
-e "s%@COMPILER_DEBUG@%ghdl1-debug$EXEEXT%" \ -e "s%@COMPILER_DEBUG@%ghdl1-debug$EXEEXT%" \
-e "s%@COMPILER_MCODE@%ghdl1-mcode$EXEEXT%" \ -e "s%@COMPILER_MCODE@%ghdl1-mcode$EXEEXT%" \
@ -101,10 +101,10 @@ index ce052534..22e1335a 100755
-e "s%@SOEXT@%$SOEXT%" \ -e "s%@SOEXT@%$SOEXT%" \
-e "s%@default_pic@%$default_pic%" \ -e "s%@default_pic@%$default_pic%" \
< $srcdir/src/ghdldrv/default_paths.ads.in > default_paths.ads < $srcdir/src/ghdldrv/default_paths.ads.in > default_paths.ads
diff --git a/dist/gcc/Make-lang.in b/dist/gcc/Make-lang.in diff --git a/scripts/gcc/Make-lang.in b/scripts/gcc/Make-lang.in
index cca1e4df..37d95d20 100644 index 108b05b..f9f3b16 100644
--- a/dist/gcc/Make-lang.in --- a/scripts/gcc/Make-lang.in
+++ b/dist/gcc/Make-lang.in +++ b/scripts/gcc/Make-lang.in
@@ -104,7 +104,9 @@ vhdl/default_paths.ads: Makefile @@ -104,7 +104,9 @@ vhdl/default_paths.ads: Makefile
echo " Compiler_Llvm : constant String := \"\";" >> tmp-dpaths.ads echo " Compiler_Llvm : constant String := \"\";" >> tmp-dpaths.ads
echo " Post_Processor : constant String := \"\";" >> tmp-dpaths.ads echo " Post_Processor : constant String := \"\";" >> tmp-dpaths.ads
@ -128,10 +128,10 @@ index cca1e4df..37d95d20 100644
-mkdir $(DESTDIR)$(libdir)/ghdl -mkdir $(DESTDIR)$(libdir)/ghdl
$(INSTALL_DATA) ../libbacktrace/.libs/libbacktrace.a $(DESTDIR)$(libdir)/ghdl $(INSTALL_DATA) ../libbacktrace/.libs/libbacktrace.a $(DESTDIR)$(libdir)/ghdl
diff --git a/src/ghdldrv/default_paths.ads.in b/src/ghdldrv/default_paths.ads.in diff --git a/src/ghdldrv/default_paths.ads.in b/src/ghdldrv/default_paths.ads.in
index ae321011..228c0696 100644 index ec6b68d..0b773ce 100644
--- a/src/ghdldrv/default_paths.ads.in --- a/src/ghdldrv/default_paths.ads.in
+++ b/src/ghdldrv/default_paths.ads.in +++ b/src/ghdldrv/default_paths.ads.in
@@ -25,6 +25,8 @@ package Default_Paths is @@ -23,6 +23,8 @@ package Default_Paths is
"@INSTALL_PREFIX@"; "@INSTALL_PREFIX@";
Lib_Prefix : constant String := Lib_Prefix : constant String :=
"@LIB_PREFIX@"; "@LIB_PREFIX@";
@ -141,10 +141,10 @@ index ae321011..228c0696 100644
Compiler_Gcc : constant String := Compiler_Gcc : constant String :=
"@COMPILER_GCC@"; "@COMPILER_GCC@";
diff --git a/src/ghdldrv/ghdlvpi.adb b/src/ghdldrv/ghdlvpi.adb diff --git a/src/ghdldrv/ghdlvpi.adb b/src/ghdldrv/ghdlvpi.adb
index 295b7300..487eb0e6 100644 index 3ecd831..36fdc6f 100644
--- a/src/ghdldrv/ghdlvpi.adb --- a/src/ghdldrv/ghdlvpi.adb
+++ b/src/ghdldrv/ghdlvpi.adb +++ b/src/ghdldrv/ghdlvpi.adb
@@ -39,7 +39,7 @@ package body Ghdlvpi is @@ -37,7 +37,7 @@ package body Ghdlvpi is
-- Compute install path -- Compute install path
Ghdllocal.Set_Exec_Prefix_From_Program_Name; Ghdllocal.Set_Exec_Prefix_From_Program_Name;
@ -153,7 +153,7 @@ index 295b7300..487eb0e6 100644
end Get_Vpi_Include_Dir; end Get_Vpi_Include_Dir;
-- Return the lib directory. -- Return the lib directory.
@@ -50,7 +50,7 @@ package body Ghdlvpi is @@ -48,7 +48,7 @@ package body Ghdlvpi is
Ghdllocal.Set_Exec_Prefix_From_Program_Name; Ghdllocal.Set_Exec_Prefix_From_Program_Name;
end if; end if;

View File

@ -1,10 +0,0 @@
--- a/configure
+++ b/configure
@@ -279,6 +279,7 @@ if test $backend = llvm; then
check_version 7.0 $llvm_version ||
check_version 8.0 $llvm_version ||
check_version 9.0 $llvm_version ||
+ check_version 11.0 $llvm_version ||
false; then
echo "Debugging is not enabled with llvm $llvm_version"
llvm_be=llvm4-nodebug

View File

@ -0,0 +1,12 @@
diff --git a/configure b/configure
index c1c1a6d..dad7c38 100755
--- a/configure
+++ b/configure
@@ -280,6 +280,7 @@ if test $backend = llvm; then
check_version 9.0 $llvm_version ||
check_version 10.0 $llvm_version ||
check_version 11.0 $llvm_version ||
+ check_version 12.0 $llvm_version ||
false; then
echo "Debugging is enabled with llvm $llvm_version"
else

View File

@ -6,8 +6,8 @@
# #
pkgname=ghdl pkgname=ghdl
reverts="20181129_1" reverts="20181129_1"
version=0.37 version=1.0.0
revision=3 revision=1
build_style=configure build_style=configure
configure_args="--prefix=/usr --srcdir=.. --incdir=lib/ghdl/include" configure_args="--prefix=/usr --srcdir=.. --incdir=lib/ghdl/include"
makedepends="zlib-devel" makedepends="zlib-devel"
@ -16,7 +16,7 @@ maintainer="m3tav3rse <mtvrs@tuta.io>"
license="GPL-2.0-or-later" license="GPL-2.0-or-later"
homepage="https://github.com/ghdl/ghdl" homepage="https://github.com/ghdl/ghdl"
distfiles="https://github.com/ghdl/ghdl/archive/v${version}.tar.gz" distfiles="https://github.com/ghdl/ghdl/archive/v${version}.tar.gz"
checksum=3008616201cc3b0b596872e4ad59d8bc36e6ee3ff798bdce066828fbdad041e4 checksum=cb424766fbe831ff41bec84016a6af0406d735c272b0b639d507c3503df30495
nocross=yes nocross=yes
patch_args="-Np1" patch_args="-Np1"
make_check=extended make_check=extended
@ -52,7 +52,7 @@ fi
if [ "$build_option_llvm" ]; then if [ "$build_option_llvm" ]; then
subpackages+=" ghdl-llvm" subpackages+=" ghdl-llvm"
makedepends+=" llvm11" makedepends+=" llvm12"
fi fi
do_configure() { do_configure() {