RawTherapee 5.0 Revision 1 Released

Here’s my cmake command:

cmake -G "MSYS Makefiles" -C ../win.cmake -DCMAKE_BUILD_TYPE="release" -DPROC_TARGET_NUMBER="1" -DBUILD_BUNDLE="ON" -DCMAKE_INSTALL_PREFIX="." -DBINDIR="." -DDATADIR="." -DCACHE_NAME_SUFFIX="" ..

But in general I use a personal win.cmake file with some flags specific to Win 64.

Check the cmakelists.txt, as I think some compilation flags are specified in that file.

1 Like

Use -DCMAKE_C_FLAGS="-mwindows" or call win.cmake as sguyader does.

1 Like

@sguyader, @Morgan_Hardwood

The parameter -C ../win.cmake solved it. :slight_smile: Thanks.

This should be updated in RawPedia. A compiler noob like me can’t figure this out.

Now you can try to duplicate the win.cmake file, rename it to something like my.win64.cmake and change the flags to:

# Important: MinGW-w64 user may need to specify the -m32 or -m64 flag in CMAKE_CXX_FLAGS,
# CMAKE_C_FLAGS and CMAKE_EXE_LINKER_FLAGS to select between 32/64bit build
set(CMAKE_CXX_FLAGS "-m64 -mwin32 -mthreads" CACHE STRING "Compiler options for C++ source files")
set(CMAKE_CXX_FLAGS_DEBUG "-fopenmp -O0 -g2" CACHE STRING "Compiler options for C++ source files and Debug target")
set(CMAKE_CXX_FLAGS_RELEASE "-msse -msse2 -mwindows -fopenmp -Wno-aggressive-loop-optimizations -DNDEBUG -O3" CACHE STRING "Compiler options for C++ source files and Release target")
set(CMAKE_CXX_FLAGS_MINSIZEREL "-mwindows -DNDEBUG -Os" CACHE STRING "Compiler options for C++ source files and MinSizeRel target")
set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g" CACHE STRING "Compiler options for C++ source files and RelWithDebInfo target")

# Uncomment the next line and set the right value to override the default value (special compiling flags for RTEngine)
#set(RTENGINE_CXX_FLAGS "-funroll-loops" CACHE STRING "Special compilation flags for RTEngine")

set(CMAKE_C_FLAGS "-m64 -mwin32 -mthreads" CACHE STRING "Compiler options for C source files")
set(CMAKE_C_FLAGS_DEBUG "-O0 -g2" CACHE STRING "Compiler options for C source files and Debug target")
set(CMAKE_C_FLAGS_RELEASE "-mwindows -DNDEBUG -O2" CACHE STRING "Compiler options for C source files and Release target")
set(CMAKE_C_FLAGS_MINSIZEREL "-mwindows -DNDEBUG -Os" CACHE STRING "Compiler options for C source files and MinSizeRel target")
set(CMAKE_C_FLAGS_RELWITHDEBINFO "-O2 -g" CACHE STRING "Compiler options for C source files and RelWithDebInfo target")

set(CMAKE_EXE_LINKER_FLAGS "-m64 -mwin32 -mthreads -static-libgcc" CACHE STRING "Linker options")
set(CMAKE_EXE_LINKER_FLAGS_DEBUG "-O0" CACHE STRING "Linkage options for the Debug target")
set(CMAKE_EXE_LINKER_FLAGS_RELEASE "-mwindows -s -O3" CACHE STRING "Linkage options for the Release target")
set(CMAKE_EXE_LINKER_FLAGS_MINSIZEREL "-mwindows -s -Os" CACHE STRING "Linkage options for the MinSizeRel target")
set(CMAKE_EXE_LINKER_FLAGS_RELWITHDEBINFO "-s -O2" CACHE STRING "Linkage options for the RelWithDebInfo target")

and call it with -C ../my.win64.cmake

The additional flags are for optimizing builds for Win 64 bits.

Great, I will do that.

@Morgan_Hardwood
I suggest to have a win32.cmake and a win64.cmake in the repository and a description in RawPedia. This would make all things much easier.

EDIT: I got this error with the original win.cmake modified only with the -m64 parameter.

C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/6.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: unrecognized option '--large-address-aware'

It looks like this parameter is only valid for 32bit builds.

I will add this info, but ideally a Windows user should be keeping the Windows docs up to date, as I don’t use Windows and I rely on what you tell me and can’t test things for myself.

I am having problems with current version on Downloads page:
Uploaded by DrSlony on 2017-02-05 21:51
Branch: 5.0-r1-gtk3 Release Type: Stable (recommended)
Commit: 50114c1 Build Type: release
Processor: generic x86 Gtkmm Version: V3.18.0
Compiler: gcc 5.3.0

Installed on Windows 7 64bit but program won’t open when executed.
Task Manager shows the process running at constant 25% CPU and escalating memory usage.
Tried uninstalling previous version 4.2.1 but no change.
I reverted to restore point created before installation so I’m back on version 4.

Any ideas as others are reporting success?

@David_McAllister Can you try the pixelshift version from here? It’s a gtk2 version, but the functionality is the same as the version you tried (+ some stuff for pentax pixelshift). If that version works for you, maybe we can find the culprit in the gtk3 build…

Thank you, was just heading to bed when I got your reply. I’ll give that version a try tomorrow and let you know how I got on.

1 Like