RT starting problems in CLI on Mac OS

Hi,
I would like to start RawTherapee (Ver. 5.12) with specifying a file in command line interface of Mac OS (Ver. 15.7.3).
I used following command as on Linux, however RT crashed.

$ /Applications/RawTherapee.app/Contents/MacOS/rawtherapee TEST.NEF

Next, instead of it, I tried to use the command below.

$ open -a /Applications/RawTherapee.app TEST.NEF
$ open -a /Applications/RawTherapee.app/Contents/MacOS/rawtherapee TEST.NEF

RT successfully started, but it ignored the file.
ART, a derivative of RawTherapee, doesn’t have these problems.
Is there anyone who knows the solutions?

I recently fixed the open -a method for 5.13 to resolve this issue:

If you wish to call the binary inside Contents/MacOS you must set the environment according to what is set in the app’s Info.plist.

XDG_DATA_DIRS=/Applications/RawTherapee.app/Contents/Resources/share \
DYLD_FALLBACK_LIBRARY_PATH=/Applications/RawTherapee.app/Contents/Frameworks \
GTK_PATH=/Applications/RawTherapee.app/Contents/Resources/share/gtk-3.0 \
GTK_IM_MODULE_FILE=/Applications/RawTherapee.app/Contents/Resources/etc/gtk-3.0/gtk.immodules \
GTK_MODULES=/Applications/RawTherapee.app/Contents/Frameworks/im-quartz.so \
XDG_DATA_HOME=/Applications/RawTherapee.app/Contents/Resources/share \
GSETTINGS_SCHEMA_DIR=/Applications/RawTherapee.app/Contents/Resources/share/glib-2.0/schemas \
GDK_PIXBUF_MODULE_FILE=/Applications/RawTherapee.app/Contents/Resources/etc/gtk-3.0/gdk-pixbuf.loaders \
GDK_PIXBUF_MODULEDIR=/Applications/RawTherapee.app/Contents/Frameworks \
FONTCONFIG_PATH=/Applications/RawTherapee.app/Contents/Resources/etc/fonts \
LIBDIR=/Applications/RawTherapee.app/Contents/Frameworks \
DATADIR=/Applications/RawTherapee.app/Contents/Resources \
GDK_RENDERING=similar \
GTK_OVERLAY_SCROLLING=0 \
GDK_NATIVE_WINDOWS=1 \
/Applications/RawTherapee.app/Contents/MacOS/rawtherapee

You can alias all that stuff in the shell.

ART is different as it diverges from a much older fork.

The RT method is intended for Hardened Runtime operation for compatibility with Notarization.

The test version is in my iCloud Drive:

I have not checked if it’s still compatible with macOS 15 as I’ve been doing this on 26.

1 Like

Thank you very much!
It works as intended.

1 Like

Hi, Richard.
I have another question.
I try to control RawTherapee using CLI interface from Python scripts on Mac OS.
And I try to execute “open -a /Applications/RawTherapee.app ” from subprocess of Python, however I haven’t succeeded it yet. But it seems that from os.system it is executable.
Do you know the reason?

Here is the sample python script.

#!/usr/bin/env python3
# -*- coding: utf-8 -*-
#
#   RTsubprocess_test.py 
#   2026-07-17

import sys, os, subprocess, platform
from pathlib import Path

command = "/Applications/RawTherapee.app/Contents/MacOS/rawtherapee"
selected_file = "~/TEST.NEF"
useSubprocess = True
if useSubprocess == True:
    command_args = [
        "open",
        "-a",
        command,
        selected_file
    ]
else: # use os.system
    command_args = [
        "open -a " +\
        command + " " +\
        selected_file
    ]

print(command_args)
try:
    if useSubprocess == True:
        result = subprocess.run(
                command_args,
                check=True,
                capture_output=True,
                text=True,
                shell=True
        )
    else:
        os.system(command_args[0])

except subprocess.CalledProcessError as e:
            print(e, "open -a ", command, selected_file)

According to your code you are specifying the internal binary executable which you set as command instead of the plain ole’ app name as registered in launch services. open -a rawtherapee is sufficient.

Thank you.
However, with following commands…

open -a rawtherapee
open -a /Applications/RawTherapee.app
open -a /Applications/RawTherapee.app/Contents/MacOS/rawtherapee

it seems that the results are same.

Ok, let’s see some error messages.

1 Like