libncurses: Import https://ftp.gnu.org/pub/gnu/ncurses/ncurses-6.5.tar.gz changes

Change-Id: I3433d30ca01359fd2e3623ede96b531f0b39cbfa
Signed-off-by: micky387 <mickaelsaibi@free.fr>
diff --git a/Ada95/package/debian/compat b/Ada95/package/debian/compat
index 7ed6ff8..48082f7 100644
--- a/Ada95/package/debian/compat
+++ b/Ada95/package/debian/compat
@@ -1 +1 @@
-5
+12
diff --git a/Ada95/package/debian/control b/Ada95/package/debian/control
index 88af970..1a9aefd 100644
--- a/Ada95/package/debian/control
+++ b/Ada95/package/debian/control
@@ -2,14 +2,16 @@
 Maintainer: Thomas E. Dickey <dickey@invisible-island.net>
 Section: misc
 Priority: optional
-Standards-Version: 3.8.4
-Build-Depends: debhelper (>= 5)
-Homepage: http://invisible-island.net/adacurses/
+Build-Depends: debhelper (>= 5),
+  gnat,
+  gprbuild
+Homepage: https://invisible-island.net/adacurses/
+Standards-Version: 4.6.1.0
 
 Package: adacurses
 Architecture: any
 Depends: ${shlibs:Depends}, ${misc:Depends}
-Description: AdaCurses - Ada95 binding for ncurses
+Description: Ada95 binding for ncurses
  This package installs as "adacurses" to avoid conflict with other packages.
  This is the Ada95 binding from the ncurses distribution.
  .
diff --git a/Ada95/package/debian/copyright b/Ada95/package/debian/copyright
index b24950a..b406015 100644
--- a/Ada95/package/debian/copyright
+++ b/Ada95/package/debian/copyright
@@ -1,15 +1,16 @@
-Upstream source http://invisible-island.net/ncurses/ncurses-examples.html
+Upstream source https://invisible-island.net/ncurses/Ada95.html
 
 Current ncurses maintainer: Thomas Dickey <dickey@invisible-island.net>
 
 -------------------------------------------------------------------------------
 Files: *
-Copyright: 1998-2014,2015 Free Software Foundation, Inc.
-Licence: X11
+Copyright: 2017-2023,2024 by Thomas E. Dickey
+Copyright: 1998-2016,2017 Free Software Foundation, Inc.
+License: X11
 
 Files: aclocal.m4 package
-Copyright: 2010-2014,2015 by Thomas E. Dickey
-Licence: X11
+Copyright: 2010-2023,2024 by Thomas E. Dickey
+License: X11
 
     Permission is hereby granted, free of charge, to any person obtaining a
     copy of this software and associated documentation files (the
@@ -38,7 +39,7 @@
 -------------------------------------------------------------------------------
 Files: install-sh
 Copyright:  1994 X Consortium
-Licence: X11
+License: X11
 
     Permission is hereby granted, free of charge, to any person obtaining a copy
     of this software and associated documentation files (the "Software"), to
diff --git a/Ada95/package/debian/rules b/Ada95/package/debian/rules
index 5805f8b..0adde8d 100755
--- a/Ada95/package/debian/rules
+++ b/Ada95/package/debian/rules
@@ -12,9 +12,11 @@
 DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
 
 TARGET_DIR = $(CURDIR)/debian/adacurses
-SAMPLE_DIR = $(TARGET_DIR)/usr/bin/AdaCurses
+SAMPLE_DIR = $(TARGET_DIR)/usr/libexec/AdaCurses
 
-CFLAGS =
+CFLAGS   = $(shell dpkg-buildflags --get CFLAGS) $(CC_NORMAL)
+CPPFLAGS = $(shell dpkg-buildflags --get CPPFLAGS)
+LDFLAGS  = $(shell dpkg-buildflags --get LDFLAGS)
 
 ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
         CFLAGS += -O0
@@ -30,7 +32,9 @@
 configure-stamp:
 	dh_testdir
 
-	CFLAGS="$(CFLAGS)" ./configure \
+	CFLAGS="$(CFLAGS)" \
+	CPPFLAGS="$(CPPFLAGS)" \
+	LDFLAGS="$(LDFLAGS)" ./configure \
 		--host=$(DEB_HOST_GNU_TYPE) \
 		--build=$(DEB_BUILD_GNU_TYPE) \
 		--prefix=/usr \
@@ -63,11 +67,11 @@
 install-stamp: build-stamp
 	dh_testdir
 	dh_testroot
-	dh_clean -k
+	dh_prep
 	dh_installdirs
 
 	$(MAKE) install DESTDIR=$(TARGET_DIR)
-	
+
 	# FIXME: it would be nice to make these into separate packages
 	( cd samples && $(MAKE) install.examples DESTDIR=$(TARGET_DIR) BINDIR=$(SAMPLE_DIR) )
 	( cd doc && $(MAKE) install.html DESTDIR=$(TARGET_DIR) )
diff --git a/Ada95/package/debian/watch b/Ada95/package/debian/watch
index 4794ae3..1b870ba 100644
--- a/Ada95/package/debian/watch
+++ b/Ada95/package/debian/watch
@@ -1,4 +1,4 @@
 version=3
 
-opts=passive ftp://invisible-island.net/AdaCurses/AdaCurses-([\d.]+)\.tgz \
+opts=passive ftp://ftp.invisible-island.net/AdaCurses/AdaCurses-([\d.]+)\.tgz \
  debian  uupdate