Bug#1053405: darktable: FTBFS on arm64 (gcc bug?)

2024-02-21 Thread Gianfranco Costamagna

On Mon, 19 Feb 2024 11:47:25 +0100 Tino Mettler  wrote:

Version: 4.4.2-1.1

Hi,

OPENMP support was disabled for arm64 in the 4.4.2-1.1 package, so this
bug can be closed.

I also stumbled again over this FTBFS bug after accidently enabling
OPENMP yesterday for the darktable 4.6.1-1 package, so it looks like
this workaround is still needed.



Only gcc-14 was patched.
I tried to force gcc-14 and g++-14 on arm64, and this bug is indeed fixed.
Until Matthias updates gcc-13 with the patch for 
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111677#add_comment
We can't really drop the hack (unless we add the hack to use gcc-14)


diff -Nru darktable-4.6.1/debian/control darktable-4.6.1/debian/control
--- darktable-4.6.1/debian/control  2024-02-18 18:29:32.0 +0100
+++ darktable-4.6.1/debian/control  2024-02-21 10:16:44.0 +0100
@@ -38,7 +38,9 @@
libsqlite3-dev,
libtiff-dev,
libwebp-dev,
-   xsltproc
+   xsltproc,
+   gcc-14 [arm64],
+   g++-14 [arm64]
 Standards-Version: 4.6.2
 Homepage: http://www.darktable.org/
 Vcs-Git: https://salsa.debian.org/debian-phototools-team/darktable.git
diff -Nru darktable-4.6.1/debian/rules darktable-4.6.1/debian/rules
--- darktable-4.6.1/debian/rules2024-02-18 18:29:32.0 +0100
+++ darktable-4.6.1/debian/rules2024-02-21 10:17:45.0 +0100
@@ -14,8 +14,8 @@
 endif
 
 ifeq ($(DEB_HOST_ARCH),arm64)

-# Disable OPENMP for arm64 builds. See LP: #2038351
-DISABLE_OPENMP = -DUSE_OPENMP=OFF
+   export CC=gcc-14
+   export CXX=g++-14
 endif
 
 %:

@@ -26,8 +26,7 @@
-DBINARY_PACKAGE_BUILD=1 \
-DCMAKE_BUILD_TYPE=Release \
-DRAWSPEED_ENABLE_LTO=ON \
-   -DDONT_USE_INTERNAL_LIBRAW=ON \
-   $(DISABLE_OPENMP)
+   -DDONT_USE_INTERNAL_LIBRAW=ON
 
 describe-current-version:

git describe --tags upstream | sed 's,^release-,,;s,-,+,;s,-,~,;'


Otherwise we can just switch to gcc-14 everywhere.

G.


OpenPGP_signature.asc
Description: OpenPGP digital signature


Bug#1053405: darktable: FTBFS on arm64 (gcc bug?)

2023-11-27 Thread Boyuan Yang
On Thu, 5 Oct 2023 08:56:00 +0200 Gianfranco Costamagna
 wrote:
> control: reassign -1 src:gcc-13
> control: found -1 13.2.0-4
> control: affects -1 src:darktable.
> 
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111677
> According to upstream, we need a patch that was added some days ago on 13
branch

Can we disable openmp support in darktable for now? This bug has been blocking
many transitions (that I care) for way too long.

Thanks,
Boyuan Yang

 
> On Wed, 4 Oct 2023 08:21:31 +0200 Gianfranco Costamagna
 wrote:
> > Hello,
> > 
> > > 
> > > Do you think maybe there should be a debian gcc bug? after all, the
> > > distinction you point to is a difference of debian version.
> > > 
> > 
> > Not really sure, somewhat it fails with gcc-12 too, so it might be
something that was even backported to older gcc, or something else
> > 
> > 
> > For sure, it builds if we disable OPENMP support
> > 
> > diff -Nru darktable-4.4.2/debian/changelog darktable-
4.4.2/debian/changelog
> > --- darktable-4.4.2/debian/changelog2023-08-20 12:26:40.0
+
> > +++ darktable-4.4.2/debian/changelog2023-10-03 15:58:01.0
+
> > @@ -1,3 +1,10 @@
> > +darktable (4.4.2-1.1) unstable; urgency=medium
> > +
> > +  * Disable openmp for arm64 builds (LP: #2038351)
> > +    See Debian bug: #1053405
> > +
> > + -- Mitchell Dzurick   Tue, 03 Oct 2023
08:58:01 -0700
> > +
> >   darktable (4.4.2-1) unstable; urgency=medium
> >   
> > * Update to new upstream version 4.4.2.
> > diff -Nru darktable-4.4.2/debian/rules darktable-4.4.2/debian/rules
> > --- darktable-4.4.2/debian/rules2023-08-20 12:26:40.0 +
> > +++ darktable-4.4.2/debian/rules2023-10-03 15:58:01.0 +
> > @@ -20,7 +20,12 @@
> > dh $@
> >   
> >   override_dh_auto_configure: cmake/version.cmake
> > +ifeq ($(DEB_HOST_ARCH),arm64)
> > +   # Disable OPENMP for arm64 builds. See LP: #2038351
> > +   dh_auto_configure -- -DBINARY_PACKAGE_BUILD=1 -
DCMAKE_BUILD_TYPE=Release -DRAWSPEED_ENABLE_LTO=ON -DUSE_OPENMP=OFF
> > +else
> > dh_auto_configure -- -DBINARY_PACKAGE_BUILD=1 -
DCMAKE_BUILD_TYPE=Release -DRAWSPEED_ENABLE_LTO=ON
> > +endif
> >   
> >   describe-current-version:
> > git describe --tags upstream | sed 's,^release-,,;s,-,+,;s,-,~,;'



signature.asc
Description: This is a digitally signed message part


Bug#1053405: darktable: FTBFS on arm64 (gcc bug?)

2023-10-05 Thread Gianfranco Costamagna

control: reassign -1 src:gcc-13
control: found -1 13.2.0-4
control: affects -1 src:darktable.

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111677
According to upstream, we need a patch that was added some days ago on 13 branch

G.

On Wed, 4 Oct 2023 08:21:31 +0200 Gianfranco Costamagna 
 wrote:

Hello,

> 
> Do you think maybe there should be a debian gcc bug? after all, the

> distinction you point to is a difference of debian version.
> 


Not really sure, somewhat it fails with gcc-12 too, so it might be something 
that was even backported to older gcc, or something else


For sure, it builds if we disable OPENMP support

diff -Nru darktable-4.4.2/debian/changelog darktable-4.4.2/debian/changelog
--- darktable-4.4.2/debian/changelog2023-08-20 12:26:40.0 +
+++ darktable-4.4.2/debian/changelog2023-10-03 15:58:01.0 +
@@ -1,3 +1,10 @@
+darktable (4.4.2-1.1) unstable; urgency=medium
+
+  * Disable openmp for arm64 builds (LP: #2038351)
+See Debian bug: #1053405
+
+ -- Mitchell Dzurick   Tue, 03 Oct 2023 
08:58:01 -0700
+
  darktable (4.4.2-1) unstable; urgency=medium
  
* Update to new upstream version 4.4.2.

diff -Nru darktable-4.4.2/debian/rules darktable-4.4.2/debian/rules
--- darktable-4.4.2/debian/rules2023-08-20 12:26:40.0 +
+++ darktable-4.4.2/debian/rules2023-10-03 15:58:01.0 +
@@ -20,7 +20,12 @@
dh $@
  
  override_dh_auto_configure: cmake/version.cmake

+ifeq ($(DEB_HOST_ARCH),arm64)
+   # Disable OPENMP for arm64 builds. See LP: #2038351
+   dh_auto_configure -- -DBINARY_PACKAGE_BUILD=1 
-DCMAKE_BUILD_TYPE=Release -DRAWSPEED_ENABLE_LTO=ON -DUSE_OPENMP=OFF
+else
dh_auto_configure -- -DBINARY_PACKAGE_BUILD=1 
-DCMAKE_BUILD_TYPE=Release -DRAWSPEED_ENABLE_LTO=ON
+endif
  
  describe-current-version:

git describe --tags upstream | sed 's,^release-,,;s,-,+,;s,-,~,;'


OpenPGP_signature.asc
Description: OpenPGP digital signature


Bug#1053405: darktable: FTBFS on arm64 (gcc bug?)

2023-10-04 Thread Gianfranco Costamagna

Hello,



Do you think maybe there should be a debian gcc bug? after all, the
distinction you point to is a difference of debian version.



Not really sure, somewhat it fails with gcc-12 too, so it might be something 
that was even backported to older gcc, or something else


For sure, it builds if we disable OPENMP support

diff -Nru darktable-4.4.2/debian/changelog darktable-4.4.2/debian/changelog
--- darktable-4.4.2/debian/changelog2023-08-20 12:26:40.0 +
+++ darktable-4.4.2/debian/changelog2023-10-03 15:58:01.0 +
@@ -1,3 +1,10 @@
+darktable (4.4.2-1.1) unstable; urgency=medium
+
+  * Disable openmp for arm64 builds (LP: #2038351)
+See Debian bug: #1053405
+
+ -- Mitchell Dzurick   Tue, 03 Oct 2023 
08:58:01 -0700
+
 darktable (4.4.2-1) unstable; urgency=medium
 
   * Update to new upstream version 4.4.2.

diff -Nru darktable-4.4.2/debian/rules darktable-4.4.2/debian/rules
--- darktable-4.4.2/debian/rules2023-08-20 12:26:40.0 +
+++ darktable-4.4.2/debian/rules2023-10-03 15:58:01.0 +
@@ -20,7 +20,12 @@
dh $@
 
 override_dh_auto_configure: cmake/version.cmake

+ifeq ($(DEB_HOST_ARCH),arm64)
+   # Disable OPENMP for arm64 builds. See LP: #2038351
+   dh_auto_configure -- -DBINARY_PACKAGE_BUILD=1 
-DCMAKE_BUILD_TYPE=Release -DRAWSPEED_ENABLE_LTO=ON -DUSE_OPENMP=OFF
+else
dh_auto_configure -- -DBINARY_PACKAGE_BUILD=1 
-DCMAKE_BUILD_TYPE=Release -DRAWSPEED_ENABLE_LTO=ON
+endif
 
 describe-current-version:

git describe --tags upstream | sed 's,^release-,,;s,-,+,;s,-,~,;'


OpenPGP_signature.asc
Description: OpenPGP digital signature


Bug#1053405: darktable: FTBFS on arm64 (gcc bug?)

2023-10-03 Thread David Bremner
Gianfranco Costamagna  writes:

> Source: darktable
> Version: 4.4.2-1
> Severity: serious
> forwarded: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111677
> tags: ftbfs
>

Do you think maybe there should be a debian gcc bug? after all, the
distinction you point to is a difference of debian version.

d