diff mbox series

[bug#42807,1/2] gnu: darktable: Update to 3.2.1.

Message ID 20200810232325.61515-1-monego@posteo.net
State Accepted
Headers show
Series [bug#42807,1/2] gnu: darktable: Update to 3.2.1. | expand

Checks

Context Check Description
cbaines/comparison success View comparision
cbaines/git branch success View Git branch
cbaines/applying patch success View Laminar job
cbaines/comparison success View comparision
cbaines/git branch success View Git branch
cbaines/applying patch success View Laminar job

Commit Message

Vinicius Monego Aug. 10, 2020, 11:23 p.m. UTC
* gnu/packages/photo.scm (darktable): update to 3.2.1.
---
 gnu/packages/photo.scm | 29 +++++++++++++++--------------
 1 file changed, 15 insertions(+), 14 deletions(-)

Comments

Brett Gilio Aug. 10, 2020, 11:31 p.m. UTC | #1
Vinicius Monego <monego@posteo.net> writes:

--8<---------------cut here---------------start------------->8---
> +             ;; Build fails with every version of GCC.
>               (setenv "CC" "clang") (setenv "CXX" "clang++")
--8<---------------cut here---------------end--------------->8---

Hey, is this issue with GCC reported upstream? I'm not opposed to
compiling against clang<++>, especially since it is already in the
closure for the package. But if there is a reported issue for this, the
ticket number should be referenced in the comment ideally. Otherwise,
could you report it?

Thanks!

Brett Gilio
Vinicius Monego Aug. 11, 2020, 1:12 a.m. UTC | #2
Brett Gilio writes:

> Hey, is this issue with GCC reported upstream? I'm not opposed 
> to
> compiling against clang<++>, especially since it is already in 
> the
> closure for the package. But if there is a reported issue for 
> this, the
> ticket number should be referenced in the comment 
> ideally. Otherwise,
> could you report it?

I debugged the build with -K and the problem seems to be this tiny 
detail:

`ld: cannot find -lpthreads`

From a quick read online, -lpthreads is Clang syntax. In GCC it's 
only
-lpthread or -pthread. That flag is not changed for GCC. Some 
 other flags are
also using -s termination which GCC doesn't recognize.

I'm not sure who's at fault here. I may be missing something in 
the
build steps, but I don't have enough time to investigate this.

The ticket/issue that more closely matches this problem is #5185 
and GCC 8+ is
officially supported by Darktable.
Vinicius Monego Aug. 12, 2020, 1:01 a.m. UTC | #3
Vinicius Monego writes:

> I debugged the build with -K and the problem seems to be this 
> tiny
> detail:
>
> `ld: cannot find -lpthreads`

To correct myself, that's only normal CMake check, nothing wrong
there. Pthread is passed correctly to make.

The actual failure in my build log is something to do with OpenMP 
(libgomp):

VC5Decompressor.cpp:744: undefined reference to 
`GOMP_loop_nonmonotonic_dynamic_next'
collect2: error: ld returned 1 exit status

Could this be merged as is for now? I may send a v2 with better
comments and leave GCC for another patch. I'd make sure that the 
issue
is with upstream before submitting an issue there.
Ludovic Courtès Sept. 4, 2020, 9:06 a.m. UTC | #4
Hi,

Vinicius Monego <monego@posteo.net> skribis:

> The actual failure in my build log is something to do with OpenMP
> (libgomp):
>
> VC5Decompressor.cpp:744: undefined reference to
> `GOMP_loop_nonmonotonic_dynamic_next'
> collect2: error: ld returned 1 exit status

It looks like a case where ‘-fopenmp’ is used as compile time but
omitted at link time.  The fix is to add it at link time (to the LDFLAGS
of the executable at hand).

It would be nice to see eventually if this can be fixed so we can switch
back to GCC.

Thanks,
Ludo’.
diff mbox series

Patch

diff --git a/gnu/packages/photo.scm b/gnu/packages/photo.scm
index abdb751a5a..6be0094a8d 100644
--- a/gnu/packages/photo.scm
+++ b/gnu/packages/photo.scm
@@ -465,7 +465,7 @@  photographic equipment.")
 (define-public darktable
   (package
     (name "darktable")
-    (version "3.0.2")
+    (version "3.2.1")
     (source
      (origin
        (method url-fetch)
@@ -473,7 +473,7 @@  photographic equipment.")
              "https://github.com/darktable-org/darktable/releases/"
              "download/release-" version "/darktable-" version ".tar.xz"))
        (sha256
-        (base32 "1yrnkw8c47kmy2x6m1xp69hwyk02xyc8pd9kvcmyj54lzrhzdfka"))))
+        (base32 "035rvqmw386hm0jpi14lf4dnpr5rjkalzjkyprqh42nwi3m86dkf"))))
     (build-system cmake-build-system)
     (arguments
      `(#:tests? #f                      ; there are no tests
@@ -482,6 +482,7 @@  photographic equipment.")
        (modify-phases %standard-phases
          (add-before 'configure 'prepare-build-environment
            (lambda* (#:key inputs #:allow-other-keys)
+             ;; Build fails with every version of GCC.
              (setenv "CC" "clang") (setenv "CXX" "clang++")
              ;; Darktable looks for opencl-c.h in the LLVM dir. Guix installs
              ;; it to the Clang dir. We fix this by patching CMakeLists.txt.
@@ -524,35 +525,35 @@  photographic equipment.")
     (inputs
      `(("cairo" ,cairo)
        ("colord-gtk" ,colord-gtk)
-       ("cups" ,cups)
+       ("cups" ,cups) ;optional, for printing support
        ("curl" ,curl)
        ("dbus-glib" ,dbus-glib)
        ("exiv2" ,exiv2)
        ("freeimage" ,freeimage)
-       ("gmic" ,gmic)
+       ("gmic" ,gmic) ;optional
        ("graphicsmagick" ,graphicsmagick)
        ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)
        ("gtk+" ,gtk+)
        ("ilmbase" ,ilmbase)
-       ("iso-codes" ,iso-codes)
+       ("iso-codes" ,iso-codes) ;optional
        ("json-glib" ,json-glib)
        ("lcms" ,lcms)
-       ("lensfun" ,lensfun)
-       ("libgphoto2" ,libgphoto2)
+       ("lensfun" ,lensfun) ;optional
+       ("libgphoto2" ,libgphoto2) ;optional
        ("libjpeg" ,libjpeg-turbo)
        ("libomp" ,libomp)
        ("libpng" ,libpng)
        ("librsvg" ,librsvg)
-       ("libsecret" ,libsecret)
-       ("libsoup" ,libsoup)
+       ("libsecret" ,libsecret) ;optional
+       ("libsoup" ,libsoup) ;optional
        ("libtiff" ,libtiff)
-       ("libwebp" ,libwebp)
-       ("libxml2" ,libxml2)
+       ("libwebp" ,libwebp) ;optional, for WebP support
+       ("libxml2" ,libxml2) ;optional, for validation of data/cameras.xml
        ("libxslt" ,libxslt)
-       ("lua" ,lua) ;for plugins
+       ("lua" ,lua) ;optional, for plugins
        ("openexr" ,openexr)
-       ("openjpeg" ,openjpeg)
-       ("osm-gps-map" ,osm-gps-map)
+       ("openjpeg" ,openjpeg) ;optional
+       ("osm-gps-map" ,osm-gps-map) ;optional,
        ("pugixml" ,pugixml)
        ("python-jsonschema" ,python-jsonschema)
        ("sqlite" ,sqlite)))