Closed Bug 1123590 Opened 10 years ago Closed 8 years ago

Syntax error on compare-locales script

Categories

(Firefox OS Graveyard :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INCOMPLETE

People

(Reporter: michael.moroni, Unassigned)

Details

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Firefox/38.0 Build ID: 20150115030228 Steps to reproduce: I tried to build my "own" images of Firefox OS 3.0 for my Flame (see this bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1112663). Something went wrong. I list ALL command given to reproduce my error From https://developer.mozilla.org/en-US/Firefox_OS/Firefox_OS_build_prerequisites#Arch_Linux * sudo pacman -S --needed alsa-lib autoconf2.13 bison ccache curl firefox flex gcc-multilib git gperf libnotify libxt libx11 mesa multilib-devel wget wireless_tools yasm zip lib32-mesa lib32-mesa-libgl lib32-ncurses lib32-readline lib32-zlib * I installed gcc46-multilib from AUR * export CC=gcc-4.6.4 * export CXX=g++-4.6.4 * sudo pacman -S python-virtualenvwrapper * source /usr/bin/virtualenvwrapper.sh * mkvirtualenv -p `which python2` firefoxos * workon firefoxos * I installed make-3.81 from AUR * mkdir -p ~/bin * ln -s `which make-3.81` ~/bin/make * export PATH=~/bin:$PATH * I installed jdk6 from AUR * sudo archlinux-java set java-6-jdk * ccache --max-size 10GB From https://developer.mozilla.org/en-US/Firefox_OS/Preparing_for_your_first_B2G_build * git clone git://github.com/mozilla-b2g/B2G.git * cd B2G * ./config.sh flame-kk From https://developer.mozilla.org/en-US/Firefox_OS/Building#Building_multilocale * cd gaia/locales/ * hg clone http://hg.mozilla.org/gaia-l10n/it * hg clone http://hg.mozilla.org/gaia-l10n/eo * hg clone http://hg.mozilla.org/gaia-l10n/fi * cd .. * export LOCALE_BASEDIR=$PWD/locales * cp locales/languages_dev.json locales/languages_own.json * nano locales/languages_own.json { "en_US" "English (USA)", "eo" "Esperanto", "fi" "Suomi", "it" "Italian" } * export LOCALES_FILE=$PWD/locales/languages_dev.json * export GAIA_DEFAULT_LOCALE=it * GAIA_KEYBOARD_LAYOUTS=en,it * export GAIA_KEYBOARD_LAYOUTS=en,it (it is not clear which one is correct) * cd * cd B2G/gecko * mkdir locales * cd locales * hg clone http://hg.mozilla.org/l10n-central/it * hg clone http://hg.mozilla.org/l10n-central/eo * hg clone http://hg.mozilla.org/l10n-central/fi * cd .. * hg clone http://hg.mozilla.org/build/compare-locales * export L10NBASEDIR=$PWD/locales * export MOZ_CHROME_MULTILOCALE="it en eo fi" * export PATH="$PATH:$PWD/compare-locales/scripts" * export PYTHONPATH="$PWD/compare-locales/lib" * ./build.sh -j1 Actual results: [...] Packaging quitter@mozilla.org.xpi... make[1]: Entering directory `/home/airon/B2G/objdir-gecko/b2g/locales' rm -f -rf /home/airon/B2G/objdir-gecko/b2g/locales/merge-it MACOSX_DEPLOYMENT_TARGET= compare-locales -m /home/airon/B2G/objdir-gecko/b2g/locales/merge-it /home/airon/B2G/gecko/b2g/locales/l10n.ini /home/airon/B2G/gecko/locales it File "/home/airon/B2G/gecko/locales/compare-locales/scripts/compare-locales", line 84 except (OSError, IOError), e: ^ SyntaxError: invalid syntax make[1]: *** [merge-it] Error 1 make[1]: Leaving directory `/home/airon/B2G/objdir-gecko/b2g/locales' make[1]: Entering directory `/home/airon/B2G/objdir-gecko/b2g/locales' rm -f -rf /home/airon/B2G/objdir-gecko/b2g/locales/merge-en MACOSX_DEPLOYMENT_TARGET= compare-locales -m /home/airon/B2G/objdir-gecko/b2g/locales/merge-en /home/airon/B2G/gecko/b2g/locales/l10n.ini /home/airon/B2G/gecko/locales en File "/home/airon/B2G/gecko/locales/compare-locales/scripts/compare-locales", line 84 except (OSError, IOError), e: ^ SyntaxError: invalid syntax make[1]: *** [merge-en] Error 1 make[1]: Leaving directory `/home/airon/B2G/objdir-gecko/b2g/locales' make[1]: Entering directory `/home/airon/B2G/objdir-gecko/b2g/locales' rm -f -rf /home/airon/B2G/objdir-gecko/b2g/locales/merge-eo MACOSX_DEPLOYMENT_TARGET= compare-locales -m /home/airon/B2G/objdir-gecko/b2g/locales/merge-eo /home/airon/B2G/gecko/b2g/locales/l10n.ini /home/airon/B2G/gecko/locales eo File "/home/airon/B2G/gecko/locales/compare-locales/scripts/compare-locales", line 84 except (OSError, IOError), e: ^ SyntaxError: invalid syntax make[1]: *** [merge-eo] Error 1 make[1]: Leaving directory `/home/airon/B2G/objdir-gecko/b2g/locales' make[1]: Entering directory `/home/airon/B2G/objdir-gecko/b2g/locales' rm -f -rf /home/airon/B2G/objdir-gecko/b2g/locales/merge-fi MACOSX_DEPLOYMENT_TARGET= compare-locales -m /home/airon/B2G/objdir-gecko/b2g/locales/merge-fi /home/airon/B2G/gecko/b2g/locales/l10n.ini /home/airon/B2G/gecko/locales fi File "/home/airon/B2G/gecko/locales/compare-locales/scripts/compare-locales", line 84 except (OSError, IOError), e: ^ SyntaxError: invalid syntax make[1]: *** [merge-fi] Error 1 make[1]: Leaving directory `/home/airon/B2G/objdir-gecko/b2g/locales' make: *** [out/target/product/flame/obj/DATA/gecko_intermediates/gecko] Error 2 real 465m58.060s user 272m53.988s sys 23m8.300s > Build failed! < Build with |./build.sh -j1| for better messages If all else fails, use |rm -rf objdir-gecko| to clobber gecko and |rm -rf out| to clobber everything else. Expected results: My Firefox OS images!
> "en_US" "English (USA)", There is a typo, it's "en-US". Also, you shouldn't use MOZ_CHROME_MULTILOCALE. It was an experiment at the time of B2G 1.0, we don't use it anymore to create multilocales builds. I'm not even sure why we keep it on the MDN page.
I'm so sorry, but in the file there is "en-US" and not "en_US" :) So, if I do the same without using MOZ_CHROME_MULTILOCALE it should build my images correctly. Am I right? Thank you very much Théo for your answer!
(In reply to michael.moroni from comment #2) > So, if I do the same without using MOZ_CHROME_MULTILOCALE it should build my > images correctly. Am I right? On l10n side, it should be okay, yeah. You should also remove L10NBASEDIR. (So basically, only follow instructions in Gaia section of https://developer.mozilla.org/en-US/Firefox_OS/Building#Gaia )
This bug report can be closed.
Status: UNCONFIRMED → RESOLVED
Closed: 8 years ago
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.