Skip to content

Commit

Permalink
Bug 1180461 - Part 1: Build gaia during b2gdroid build. r=glandium
Browse files Browse the repository at this point in the history
--HG--
extra : commitid : EsVFILuJ091
extra : rebase_source : a491d749017a2ccec6c16b40f051053d6a1fa317
  • Loading branch information
Fabrice Desré committed Jul 6, 2015
1 parent 2e46ff4 commit 38d8405
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 15 deletions.
3 changes: 2 additions & 1 deletion b2g/gaia/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.

GAIA_PATH := gaia/profile
# For b2gdroid, gaia ends up in the assets/gaia folder in the APK.
GAIA_PATH := $(if MOZ_B2GDROID,gaia/assets/gaia,gaia/profile)

GENERATED_DIRS += $(DIST)/bin/$(GAIA_PATH)

Expand Down
28 changes: 15 additions & 13 deletions b2g/gaia/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,21 @@
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.

Program(CONFIG['MOZ_APP_NAME'])
if not CONFIG['MOZ_B2GDROID']:
# b2gdroid does not build a runner executable, but it does build gaia; see Makefile.in.
Program(CONFIG['MOZ_APP_NAME'])

if CONFIG['OS_ARCH'] == 'WINNT':
SOURCES += [
'run-b2g.cpp',
]
DEFINES['B2G_NAME'] = 'L"%s-bin%s"' % (PROGRAM, CONFIG['BIN_SUFFIX'])
DEFINES['GAIA_PATH'] = 'L"gaia\\\\profile"'
else:
SOURCES += [
'run-b2g.c',
]
DEFINES['B2G_NAME'] = '"%s-bin%s"' % (PROGRAM, CONFIG['BIN_SUFFIX'])
DEFINES['GAIA_PATH'] = '"gaia/profile"'
if CONFIG['OS_ARCH'] == 'WINNT':
SOURCES += [
'run-b2g.cpp',
]
DEFINES['B2G_NAME'] = 'L"%s-bin%s"' % (PROGRAM, CONFIG['BIN_SUFFIX'])
DEFINES['GAIA_PATH'] = 'L"gaia\\\\profile"'
else:
SOURCES += [
'run-b2g.c',
]
DEFINES['B2G_NAME'] = '"%s-bin%s"' % (PROGRAM, CONFIG['BIN_SUFFIX'])
DEFINES['GAIA_PATH'] = '"gaia/profile"'

FAIL_ON_WARNINGS = True
6 changes: 5 additions & 1 deletion configure.in
Original file line number Diff line number Diff line change
Expand Up @@ -7498,7 +7498,7 @@ fi
AC_SUBST(MOZ_DISABLE_STARTUPCACHE)

dnl ========================================================
dnl = Enable packaging Gaia with B2G desktop
dnl = Enable packaging Gaia with B2G desktop and b2gdroid
dnl ========================================================
if test x"$MOZ_WIDGET_TOOLKIT" != x"gonk"; then
if test -n "$GAIADIR" -a ! -d "$GAIADIR" ; then
Expand All @@ -7514,6 +7514,10 @@ if test x"$MOZ_WIDGET_TOOLKIT" != x"gonk"; then
AC_MSG_ERROR([FXOS_SIMULATOR=1 requires GAIADIR to be defined])
fi

if test "$MOZ_BUILD_APP" = "mobile/android/b2gdroid" -a -z "$GAIADIR"; then
AC_MSG_ERROR([GAIADIR needs to be set in b2gdroid builds])
fi

if test -n "$FXOS_SIMULATOR" ; then
AC_DEFINE(FXOS_SIMULATOR)
AC_SUBST(FXOS_SIMULATOR)
Expand Down
1 change: 1 addition & 0 deletions mobile/android/b2gdroid/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,5 @@ DIRS += [
'../geckoview_library',
'/b2g/components',
'/b2g/chrome',
'/b2g/gaia',
]

0 comments on commit 38d8405

Please sign in to comment.