Opened 10 years ago

Closed 10 years ago

Last modified 10 years ago

#44498 closed defect (invalid)

GIMP-APP fails to launch

Reported by: marga07@… Owned by: dbevans (David B. Evans)
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc:
Port: gimp gimp2 gimp-app

Description

Installed XCode, MacPorts on Mountain Lion. Tried installing both GIMP and GIMP-APP, but neither will work. I cannot find any logs with errors, but when I double click on the GIMP icon in the MacPorts folder, it briefly appears and then disappears. Error message in system.log:

com.apple.launchd.peruser.501[229] ([0x0-0xbb0bb].org.gimp.GIMP[12817]): Exited with code: 1

Attachments (1)

main.log (1.0 MB) - added by marga07@… 10 years ago.

Download all attachments as: .zip

Change History (20)

comment:1 Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Keywords: gimp gimp-app removed
Owner: changed from macports-tickets@… to devans@…
Port: gimp gimp-app added; GIMP GIMP-APP removed

comment:2 Changed 10 years ago by dbevans (David B. Evans)

Port: gimp2 added
Status: newassigned
Version: 2.3.1

Unfortunately, I'm not able to reproduce your problem. Running ML 10.8.5, clicking on the gimp-app icon launches GIMP as expected with no related errors in system.log.

For clarity, the various gimp related ports are as follows:

  • gimp2 -- installs the GIMP application itself including binary ${prefix}/bin/gimp
  • gimp-app -- Mac launcher application which executes gimp when clicked
  • gimp -- a meta port that installs the previous 2 ports as well as a collection of third party GIMP plugins

Are you able to start GIMP by executing the gimp binary from a terminal command line?

$ gimp

comment:3 Changed 10 years ago by marga07@…

I can see the ports Gimp2, Gimp-app and GImp-help-en installed.

Starting gimp on command line gives

(gimp:13325): Gtk-WARNING **: Locale not supported by C library.
	Using the fallback 'C' locale.
Cannot open display: 

comment:4 Changed 10 years ago by dbevans (David B. Evans)

GIMP uses X11 by default and it looks like you don't have it installed. From ML on, OS X no longer installs X11 by default. You have several options.

  • Install XQuartz (latest version is 2.7.6 available here as a dmg)
  • Install port xorg-server or xorg-server-devel, which comes from the same code base but may be a more recent version and is updated more often.

In either case, after installing the X11 server you need to log out and log back in again. After this, gimp should work for you.

Let me know if this solves the problem for you.

comment:5 Changed 10 years ago by marga07@…

I installed the xorg-server, after that GIMP-GAP. There are still errors, but it works (mostly).

Errors:

(gimp:44323): Gtk-WARNING **: Locale not supported by C library.
	Using the fallback 'C' locale.
Session D-Bus not running. Try running `launchctl load -w /Library/LaunchAgents/org.freedesktop.dbus-session.plist'.
Dynamic session lookup supported but failed: launchd did not provide a socket path, verify that org.freedesktop.dbus-session.plist is loaded!
Not enough memory
Fontconfig warning: ignoring UTF-8: not a valid region tag
gimp: Fatal IO error 35 (Resource temporarily unavailable) on X server /tmp/launch-BTQPcv/org.macports:0.

When I quit the X11 application, the following error occurs:

(script-fu:44404): LibGimpBase-WARNING **: script-fu: gimp_wire_read(): error

The main reason I installed through Macports, was that I needed GIMP-GAP: I managed to install it, and I've been able to use it. Not everything seems to work in the application: for example if you want to put text in an image, there is no way to select a font-family.

If you don't have a solution for the problem, that's ok: I'm not planning to use it a lot.

comment:6 in reply to:  5 Changed 10 years ago by dbevans (David B. Evans)

Replying to marga07@…:

Session D-Bus not running. Try running `launchctl load -w /Library/LaunchAgents/org.freedesktop.dbus-session.plist'. Dynamic session lookup supported but failed: launchd did not provide a socket path, verify that org.freedesktop.dbus-session.plist is loaded! Not enough memory


As this error message says, port dbus is installed but you haven't initialized it to start automatically. This is done by issuing the command

launchctl load -w /Library/LaunchAgents/org.freedesktop.dbus-session.plist

in the terminal window. The session D-Bus will be started immediately and each time you login thereafter so it's only necessary to do this once. If you want to stop this behavior use the same command substituting unload for load.

See also

port notes dbus


 (gimp:44323): Gtk-WARNING **: Locale not supported by C library.
	Using the fallback 'C' locale.
Fontconfig warning: ignoring UTF-8: not a valid region tag
 gimp: Fatal IO error 35 (Resource temporarily unavailable) on X server /tmp/launch-BTQPcv/org.macports:0.


These errors are obviously locale specific. What locale (LANG environment variable) are you using? I don't any such errors in my installation using

LANG=en_US.UTF-8


When I quit the X11 application, the following error occurs:

(script-fu:44404): LibGimpBase-WARNING **: script-fu: gimp_wire_read(): error


This error is typically seen when the X11 Server is killed when GIMP is still running. Normally the X11 server will start automatically when needed and doesn't need to be shut down when you're finished with GIMP. Just quit GIMP itself using File->Quit from the main image window. If you want to shut down the X11 server manually, make sure to quit all running client apps (such as GIMP) first to avoid this sort of error when the server goes away without warning.


The main reason I installed through Macports, was that I needed GIMP-GAP: I managed to install it, and I've been able to use it. Not everything seems to work in the application: for example if you want to put text in an image, there is no way to select a font-family.


When adding a Text layer you can use the Text tool to select the font and related properties. From the Image window, use Tools->Text and then click on the Aa icon in the Text properties area at the bottom of the toolbar window to see a list of available fonts.


If you don't have a solution for the problem, that's ok: I'm not planning to use it a lot.


Finally let me suggest that you use port gimp-gap-devel instead of gimp-gap. The latter is very old and, although there hasn't been a newer release, there have been a lot of changes/improvements in upstream git. The gimp-gap-devel port is a recent git snapshot that works well and has lots of new features as well as bug fixes.

You can't have both active at the same time, so if gimp-gap is installed, use these commands to install gimp-gap-devel:

<shut down gimp>
sudo port deactivate gimp-gap
sudo port install gimp-gap-devel
<restart gimp>

and the reverse if you want to switch back to compare.

Again, let me know your locale setting and I'll see if I can reproduce that problem.

comment:7 Changed 10 years ago by dbevans (David B. Evans)

Resolution: invalid
Status: assignedclosed

Closing since the initially reported issue has been addressed.

comment:8 in reply to:  7 ; Changed 10 years ago by marga07@…

Replying to devans@…:

Closing since the initially reported issue has been addressed.

Well, I'm not getting closer to a solution, and I'm afraid it's all getting a bit too complicated for me.

First I tried loading D-Bus. This resulted in the following message:

p.dbus-session.plist
org.freedesktop.dbus-session: Already loaded

Then I deinstalled gimp-gap and installed gimp-gap-devel. This didn't go to wel either:

Error: org.macports.destroot for port gimp-gap-devel returned: command execution failed
Please see the log file for port gimp-gap-devel for details:
    /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_graphics_gimp-gap-devel/gimp-gap-devel/main.log
To report a bug, follow the instructions in the guide:
    http://guide.macports.org/#project.tickets
Error: Processing of port gimp-gap-devel failed

Somewhere in the log I see, but I don't know if this is the real error (the log file is 1,1 MB):

:debug:build Privilege de-escalation not attempted as not running as root.
:debug:destroot destroot phase started at Fri Aug  8 11:26:41 CEST 2014
:notice:destroot --->  Staging gimp-gap-devel into destroot
:debug:destroot Can't run destroot under sudo without elevated privileges (due to mtree).
:debug:destroot Run destroot without sudo to avoid root privileges.

As for the locale, where and how can I find this? Sorry, I feel a bit stupid right now... But your help is greatly appreciated.

comment:9 in reply to:  8 Changed 10 years ago by dbevans (David B. Evans)

Replying to marga07@…:

First I tried loading D-Bus. This resulted in the following message:

p.dbus-session.plist
org.freedesktop.dbus-session: Already loaded

D-Bus should be OK then.

Then I deinstalled gimp-gap and installed gimp-gap-devel. This didn't go to wel either:

Error: org.macports.destroot for port gimp-gap-devel returned: command execution failed
Please see the log file for port gimp-gap-devel for details:
    /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_graphics_gimp-gap-devel/gimp-gap-devel/main.log
To report a bug, follow the instructions in the guide:
    http://guide.macports.org/#project.tickets
Error: Processing of port gimp-gap-devel failed

Somewhere in the log I see, but I don't know if this is the real error (the log file is 1,1 MB):

:debug:build Privilege de-escalation not attempted as not running as root.
:debug:destroot destroot phase started at Fri Aug  8 11:26:41 CEST 2014
:notice:destroot --->  Staging gimp-gap-devel into destroot
:debug:destroot Can't run destroot under sudo without elevated privileges (due to mtree).
:debug:destroot Run destroot without sudo to avoid root privileges.

I know the log file is large but you really need to attach it for me to see the full picture of what is going on here.

As for the locale, where and how can I find this? Sorry, I feel a bit stupid right now... But your help is greatly appreciated.

No problem. To see your current locale settings, type on a terminal command line (I'm showing the results on my machine).

$ locale
LANG="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_CTYPE="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_ALL=

To see what locales are available:

$ locale -a

Changed 10 years ago by marga07@…

Attachment: main.log added

comment:10 Changed 10 years ago by marga07@…

Well, it looks like the locale is empty:

LANG=
LC_COLLATE="C"
LC_CTYPE="C"
LC_MESSAGES="C"
LC_MONETARY="C"
LC_NUMERIC="C"
LC_TIME="C"
LC_ALL=

All I have to do is figure out how to set it; it looks like most locales are available.

I've attached the logfile. How you can find out what's the problem.

comment:11 Changed 10 years ago by dbevans (David B. Evans)

To set the locale, close all running applications and then open System Preferences, Language & Text and select Region. Then select which region you want from the pull down Region menu. Depending on what you want, you may need to check "Show all regions."

When you restart your applications, the change should be apparent.

For instance, as a test on my machine, I selected Netherlands (Dutch). After opening a new terminal window I see

$ locale
LANG="nl_NL.UTF-8"
LC_COLLATE="nl_NL.UTF-8"
LC_CTYPE="nl_NL.UTF-8"
LC_MESSAGES="nl_NL.UTF-8"
LC_MONETARY="nl_NL.UTF-8"
LC_NUMERIC="nl_NL.UTF-8"
LC_TIME="nl_NL.UTF-8"
LC_ALL=

and when I run /opt/local/bin/gimp all the menus, etc are in Dutch.

While you're doing that, I'll take a look at the log file and see if there are any additional clues to what's going on.

comment:12 Changed 10 years ago by marga07@…

I changed the Region in the System Preferences, but this didn't set the locale. And I don't know which region to use: I'm Dutch, but live in France and use only English language software. Maybe US is the best in that case?

comment:13 in reply to:  12 Changed 10 years ago by dbevans (David B. Evans)

Replying to marga07@…:

I changed the Region in the System Preferences, but this didn't set the locale. And I don't know which region to use: I'm Dutch, but live in France and use only English language software. Maybe US is the best in that case?

US, not US (computer), works for me and probably has the best coverage as far as i18n goes, but I live in the US and may be biased. Remember to close the Terminal program and restart it after changing your Region to see the differences.

comment:14 Changed 10 years ago by marga07@…

Ok, the locale works: I set the Region to US, and checked in the Terminal Preferences "Set locale environment variables on startup" (which I had unchecked after reading somewhere this could be the solution).

Have you been able to find anything in the log file?

comment:15 Changed 10 years ago by dbevans (David B. Evans)

The log file shows that gimp-gap-devel configured and built correctly but failed during the destroot phase (pre-install staging) due to this error

:info:destroot  /opt/local/bin/gmkdir -p '/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_graphics_gimp-gap-devel/gimp-gap-devel/work/destroot/opt/local/lib/gimp-gap-2.7'
:info:destroot /bin/sh: /opt/local/bin/gmkdir: No such file or directory
:info:destroot make[2]: *** [install-scriptdataDATA] Error 1

/opt/local/bin/gmkdir is provided by port coreutils.

Looks like something like this happened

  • you had coreutils installed (installing /opt/local/bin/gmkdir)
  • you ran the configured gimp-gap-devel which decided to use gmkdir
  • something happened but you ended up uninstalling coreutils and then tried to build gimp-gap-devel again without cleaning it first.
  • you get this failure because gimp-gap-devel is configured to use gmkdir but its not there now

Solution is to clean gimp-gap-devel and try again

sudo port clean gimp-gap-devel
sudo port install gimp-gap-devel

comment:16 Changed 10 years ago by dbevans (David B. Evans)

So here's my questions for you:

  • is /opt/local/bin/gimp working for you now without errors?
  • if so, then can you start it using gimp-app?
  • does a clean build fix your gimp-gap-devel problems?

comment:17 Changed 10 years ago by marga07@…

Sorry for not replying any sooner, but I've been away on vacation.

I did as you told: port clean gimp-gap-devel, then a port install gimp-gap-devel. It installed without errors.

I can start Gimp from the terminal and it seems to work. There's however still a problem with selecting a Font family: it won't let me. Otherwise it looks ok.

comment:18 Changed 10 years ago by dbevans (David B. Evans)

I can't reproduce the font issue so I suspect there remains some configuration issues with your computer. I'd try rebuilding gimp2 to make sure it wasn't effected by some of the previous problems.

GIMP 2.8.14 has now been released and I commit the updated port later this week. This has many bug fixes so that may help you as well.

If the problem remains with the updated version (2.8.14) please open a ticket for the font problem including step-by-step instructions for reproducing the problem, what you expect to happen and what happens instead.

comment:19 Changed 10 years ago by marga07@…

Have you already rebuilt GIMP 2.8.14? If so, I'll try to rebuild everything to so if it works better.

Anyway, thanks a lot for your help and your patience.

Note: See TracTickets for help on using tickets.