URL:
  <http://gna.org/bugs/?20281>

                 Summary: Fails to build for non-English locales if gettext()
has translations for brushsettings.json strings
                 Project: MyPaint
            Submitted by: achadwick
            Submitted on: Fri Nov  2 15:33:28 2012
                Severity: 4 - Important
                Priority: 5 - Normal
                  Status: Need Info
                 Privacy: Public
             Assigned to: None
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any
                 Release: git master f7b9ba53ed
         Planned Release: None
        Operating System: Ubuntu 12.04 x64

    _______________________________________________________

Details:

From IRC, MyPaint appears to fail to build if gettext can find translations -
assuming my speculation is correct that brushlib/generate.py is trying to cram
translated non-ascii strings into C code when it shouldn't.


Symptoms observed: with a PPA build of MyPaint installed, which installs its
translations with a /usr prefix thus putting them where gettext can see them,
the build fails with


scons: Reading SConscript files ...
Building for python2.7
python2.7 generate.py
Checked mypaint-brush-settings-gen.h
Traceback (most recent call last):
  File "generate.py", line 117, in <module>
    writefile('brushsettings-gen.h', generate_internal_settings_code())
  File "generate.py", line 88, in generate_internal_settings_code
    [settings_info_struct(i) for i in brushsettings.settings])
  File "generate.py", line 53, in generate_static_struct_array
    entries.append(indent + "{%s}" % (", ".join(entry)))
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 5:
ordinal not in range(128)
scons: *** Error 1
application SConscript
swig -o mypaintlib_wrap.cpp -noproxydel -python -c++ mypaintlib.i
rm -f _mypaintlib.so
set umask to 0022 (was 0002)
scons: done reading SConscript files.
scons: Building targets ...
g++ -o lib/mypaintlib_wrap.os -c -Wall -Wno-sign-compare -Wno-write-strings
-O3 -pthread -fno-strict-aliasing -fwrapv -O2 -Wall -Wstrict-prototypes -g
-fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security
-Werror=format-security -Xlinker -export-dynamic -fPIC -Ilib
-I/usr/include/json -I/usr/include/glib-2.0
-I/usr/lib/x86_64-linux-gnu/glib-2.0/include -I/usr/include/libpng12
-I/usr/include/gtk-2.0 -I/usr/lib/x86_64-linux-gnu/gtk-2.0/include
-I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0
-I/usr/include/pango-1.0 -I/usr/include/gio-unix-2.0 -I/usr/include/pixman-1
-I/usr/include/freetype2 -I/usr/include/pygtk-2.0
-I/usr/lib/python2.7/dist-packages/numpy/core/include -I/usr/include/python2.7
-Ibrushlib lib/mypaintlib_wrap.cpp
cc1plus: Warnung: Kommandozeilenoption »-Wstrict-prototypes« ist gültig
für Ada/C/ObjC, aber nicht für C++ [standardmäßig aktiviert]
gcc -o brushlib/mypaint-brush-settings.os -c -std=c99
-D_POSIX_C_SOURCE=200809L -Wall -O3 -g -fPIC -Ibrushlib -I/usr/include/json
brushlib/mypaint-brush-settings.c
brushlib/mypaint-brush-settings.c:15:31: schwerwiegender Fehler:
brushsettings-gen.h: Datei oder Verzeichnis nicht gefunden
Kompilierung beendet.
scons: *** [brushlib/mypaint-brush-settings.os] Error 1
scons: building terminated because of errors.


on a system running Ubuntu 12.04 where locale(1) reports:


LANG=de_DE.UTF-8
LANGUAGE=
LC_CTYPE="de_DE.UTF-8"
LC_NUMERIC="de_DE.UTF-8"
LC_TIME="de_DE.UTF-8"
LC_COLLATE="de_DE.UTF-8"
LC_MONETARY="de_DE.UTF-8"
LC_MESSAGES="de_DE.UTF-8"
LC_PAPER="de_DE.UTF-8"
LC_NAME="de_DE.UTF-8"
LC_ADDRESS="de_DE.UTF-8"
LC_TELEPHONE="de_DE.UTF-8"
LC_MEASUREMENT="de_DE.UTF-8"
LC_IDENTIFICATION="de_DE.UTF-8"
LC_ALL=


I've not been able to reproduce this in full yet from an en_GB.UTF-8 11.10
workstation, but I may well not be doing the right thing with generated
locales, language packs and environment variables to be able to test
thoroughly (curse of the monoglot English speaker). Setting as Need Info for
now.




    _______________________________________________________

Reply to this item at:

  <http://gna.org/bugs/?20281>

_______________________________________________
  Message sent via/by Gna!
  http://gna.org/


_______________________________________________
Mypaint-bugs mailing list
[email protected]
https://mail.gna.org/listinfo/mypaint-bugs

Reply via email to