S
S
StrangeAttractor2015-11-18 16:34:53
linux
StrangeAttractor, 2015-11-18 16:34:53

How to deal with the error "Error: Unable to initialize GTK+, is DISPLAY set properly?" when trying to run a proprietary Linux application with AppArmor?

I'm trying to create a profile for a proprietary native Linux application. And even if you allow it (through aa-genprof) absolutely whatever it wants (literally or with generalization), when you run it in enforce mode, this error pops up:
Error: Unable to initialize GTK+, is DISPLAY set properly?
and the launch fails.
I checked: echo $DISPLAY says: 0, experiments with a script written by myself that accesses it from under AppArmor were successful (it seems AppArmor does not control access to environment variables at all), in complain mode this application works fine, but in enforce this is bullshit. Please let me know if anyone has any ideas. Thanks in advance.
The same question in English on AskUbuntu.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
alexxandr, 2015-11-18
@alexxandr

remove ubuntu install debian

A
Alexey Dementiev, 2019-11-04
@Styletton

Run from a script and in the script before starting the program, insert
export DISPLAY=:0.0

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question