Build Luminance HDR on Windows using msys2

In past, windows builds of Luminance HDR used MSVC.

I made a first step to compile and link Luminance HDR using msys2. Here are build instructions
Following this instructions it’s quite easy to compile and link Luminance HDR on Windows using msys2.

Now the part where I really need some help from more experienced people:

I’m an absolute cmake noob and don’t know how and where to modify all the CMakeLists.txt files to make a correct install for the msys2 build.

Any help is greatly appreciated.

Ping @TooWaBoo, @gaaned92, @sguyader, @Carmelo_DrRaw and others

Ingo

1 Like

I would like to help but I’m a noob too. :weary:

@heckflosse I’m a noob too. But my question is, if Rawtherapee uses InnoSetup for the windows packaging, can it be used also for making the LHDR Windows packages?

@heckflosse
Ingo, can you check whether the the cmake you have installed in MSYS2 is the 64 bits version?
Also, take a look at this: https://gitlab.kitware.com/cmake/cmake/commit/09b2f1c3f5819a5a3ec03069e7c2811172ac3591?view=parallel
If I understand, there was a change in CMake to make windows paths detected more robustly, maybe the version installed in MSYS2 is older than the date this change was committed?

@sguyader

I’m using mingw64/mingw-w64-x86_64-cmake 3.9.6-1

As a workaround we can use -DCMAKE_INSTALL_PREFIX={destination folder}.

Using InnoSetup should be possible for windows packaging.
But first we have to find out why some icons are missing in the windows build…

OK. I currently haven’t installed a Windows virtual machine, so I can’t check.
Which icons are missing?
Did you issue the gtk-update-icon-cache command after you had finished setting up the MSYS2 environment? It may have nothing to do, but as I said I can’t check right now, so I’m just throwing ideas…

Most icons are loaded at runtime from <installation_path>/icons so if you run lhdr from the build root you won’t get those icons.

Hi Ingo, unfortunately I have no experience with MSYS2 or compilation under windows… all my Win64 builds are cross-compiled with mingw-w64 under Linux (actually a custom-built Docker container).
In case you are interested to go along this path, I can certainly help! One advantage is that the packaging can then be automated with Travis…

@fcomida Some icons show fine while others don’t.
Here’s a screenshot

Edit: That was started from <installation_path>

I think the bottom of the three icons is incorrect, it could be a “missing icon” icon.

src/HdrWizard/HdrWizard.ui designates the icons, the three buttons use:

  • list-add
  • list-remove
  • edit-clear-list
$ find . -iname "*list-add*" -o -iname "*list-remove*" -o -iname "*edit-clear-list*"
./icons-breeze/luminance-hdr/apps/edit-clear-list.svg
./icons-breeze/luminance-hdr/apps/list-add.svg
./icons-breeze/luminance-hdr/apps/list-remove.svg
./icons/luminance-hdr/apps/edit-clear-list.png
./icons/luminance-hdr/apps/list-add.png
./icons/luminance-hdr/apps/list-remove.png
./program-icons/edit-clear-list.png

I don’t have any of those in my lhdr CMAKE_INSTALL_PREFIX, but I guess they are available on my system.

There are two sets of icons in LHDR, first the program icons LuminanceHDR/program-icons at master · LuminanceHDR/LuminanceHDR · GitHub which are compiled, second the icons which are bundled and meant to be changeable according to the free-desktop naming convention used in that folder LuminanceHDR/icons at master · LuminanceHDR/LuminanceHDR · GitHub or LuminanceHDR/icons-breeze at master · LuminanceHDR/LuminanceHDR · GitHub or whichever icons you have chosen. You would have to check something in your scripts or cmake lists is copying over the proper icons to the proper directory structure for your bundle.

make install or whatever failed to copy “icons” folder to the right place.

@heckflosse I will neither be of great help :frowning_face:

1- Luminance-hdr.exe is installed in installdir/bin. How to do to install it directly in installdir?

2- to get the icons, I copied master/icons in installdir/bin:
robocopy <clonedir>/icons <installdir>/bin/icons -s

3- list of dependencies dependencies.txt (897 Bytes)

@Hombre is the one who set up innosetup for RT. perhaps he can help here.

And here https://drive.google.com/open?id=0B2q9OrgyDEfPS2FpdDAtMVI1RG8

I have uploaded an installer
LuminanceHDR_master_v.2.5.1-123-g17efa5b8_WinVista_64.exe

I have first to clean the the files. Then I dont know what to generate from my local repository, a patch or a dif and how to do (the simplest please)

@gaaned92

What do you need ? I know how to create cmakefiles and innosetup too, but don’t know where things go in the linux tree, or do we talk about windows install only ?

@Hombre
we speak only about building with msys2 and generate an installer on windows.

I am trying to make a patch with all I made to build and make an installer.
A diff is not sufficient as I added files.

  • if you can explain how to make a patch with all added files, it would be fine

  • then your help will be useful and essential to check, clean and improve that

@gaaned92 What do you mean by “a patch with all added files” ? Could you share your patch with me already ? I could give some hint from this starting point. I’m installing lhdr as explained by @heckflosse. Damn, qt5 is huge !

@gaaned92 @Hombre hello, you guys can send a pull request on GitHub. That’s why git was created in the 1st place, no more patches floating around. Thank you.

@fcomida
You are right but really it is beyond my skills to do that as I have very rusty and rudimentary programming knowledge.

I made a patch installer.patch (128.9 KB) to be checked by knowledgeable people @Hombre @heckflosse or you.

Sure after checking you will make a PR for code review.

1 Like

@fcomida I don’t know github enough to answer this question, but it’s not possible to commit to a PR of a forked repository, unless you have commit right to this fork ?

@gaaned92 Thanks, I’ll look at it asap.