dconf编译错误 #1835

Closed
hgneng opened this Issue Dec 7, 2015 · 4 comments

Projects

None yet

2 participants

@hgneng
hgneng commented Dec 7, 2015

环境Ubuntu 15.10 64bit
代码github master最新代码

编译命令:
sudo apt-get install -y gnome-common gtk-doc-tools libdconf-dev libnotify-dev valac
./autogen.sh
./configure
make

错误信息:
Making all in dconf
make[3]: Entering directory '/home/hgneng/ibus-master/data/dconf'
GEN org.freedesktop.ibus.gschema.xml.in
File "/usr/bin/gsettings-schema-convert", line 606
except GSettingsSchemaConvertException, e:
^
SyntaxError: invalid syntax
Makefile:760: recipe for target 'org.freedesktop.ibus.gschema.xml.in' failed
make[3]: *** [org.freedesktop.ibus.gschema.xml.in] Error 1
make[3]: Leaving directory '/home/hgneng/ibus-master/data/dconf'

临时解决方案:
./configure --disable-dconf && make

@fujiwarat
Member

except GSettingsSchemaConvertException, e:

The format is python2 but does not work with python3.
This is caused because your /usr/bin/python is python3.
The workaround is to modify /usr/bin/gsettings-schema-convert ::
'''
% diff /usr/bin/gsettings-schema-convert.orig /usr/bin/gsettings-schema-convert
1c1
< #!/usr/bin/env python

> #!/usr/bin/env python2
'''

Please file a bug in gconf2.

@fujiwarat fujiwarat closed this Dec 7, 2015
@hgneng
hgneng commented Dec 8, 2015

It works. Thank you!

@hgneng
hgneng commented Dec 11, 2015

Here is another workaround:

data/dconf/Makefile.am
@@ -51,7 +51,7 @@ dconfdbdir = $(sysconfdir)/dconf/db/ibus.d
dconfdb_DATA = 00-upstream-settings

org.freedesktop.ibus.gschema.xml.in: $(top_srcdir)/data/ibus.schemas.in

  • $(AM_V_GEN) gsettings-schema-convert --force --gconf --xml \
  • $(AM_V_GEN) python2 /usr/bin/gsettings-schema-convert --force --gconf --xml
    --schema-id "org.freedesktop.ibus"
    --output $@ $<
@fujiwarat
Member

It seems you don't file a bug in gconf.
Now I filed the bug.
https://bugzilla.gnome.org/show_bug.cgi?id=759334

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment