Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
942 views
in Technique[技术] by (71.8m points)

c++ - How to fix error "GLib-GIO-ERROR**: No GSettings schemas are installed on the system"?

I have to create a one-file (.exe) program with InstallShield2015LimitedEdition that works with GTK3.4.2 and OpenCV 3.0.0 in Windows 7 x64. In this program the user can choose a directory from their computer. But when I invoke FileChooser (click on executable) I get this error:

GLib-GIO-ERROR**: No GSettings schemas are installed on the system

enter image description here

and the program terminates.

I visited these pages:

Glib-GIO-ERROR when opening an file chooser dialog

GLib-GIO-ERROR**: No GSettings schemas are installed on the system

How deal with FileChooser in GTK with static compilation

But I never understood exactly how to fix this error. It is related to org.gtk.Settings.FileChooser.gschema.xml file in this path: ...shareglib-2.0schemas.

Is it related to system environment variable? What things should I add to it?

enter image description here

Add to system variable or User variable? What is name and path?

For example. I added GSETTINGS_SCHEMA_DIR as variable name and E:Works for Gov ProjectHelpSource codes for GTK+gtk+-bundle_3.4.2-20130513_win64shareglib-2.0schemas as path for both of system variable and User variable.

Is this correct?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

I solved it:

First: add GSETTINGS_SCHEMA_DIR as variable name and E:Works for Gov ProjectHelpSource codes for GTK+gtk+-bundle_3.4.2-20130513_win64shareglib-2.0schemas as path for User variable.

Then, in system variable ---> path add E:Works for Gov ProjectHelpSource codes for GTK+gtk+-bundle_3.4.2-20130513_win64shareglib-2.0schemas with ; in first it, e.g. ;E:Works for Gov ProjectHelpSource codes for GTK+gtk+-bundle_3.4.2-20130513_win64shareglib-2.0schemas


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...