2011-10-06 02:15:45 +04:00
|
|
|
#
|
2012-05-21 15:12:37 +04:00
|
|
|
# This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
# 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/.
|
2011-10-06 02:15:45 +04:00
|
|
|
|
2012-08-04 22:26:44 +04:00
|
|
|
DEPTH = @DEPTH@
|
2011-10-06 02:15:45 +04:00
|
|
|
topsrcdir = @top_srcdir@
|
|
|
|
srcdir = @srcdir@
|
|
|
|
VPATH = \
|
|
|
|
$(srcdir) \
|
2011-11-02 19:28:26 +04:00
|
|
|
$(srcdir)/android \
|
2011-12-20 23:31:53 +04:00
|
|
|
$(srcdir)/gonk \
|
2011-10-06 02:15:45 +04:00
|
|
|
$(srcdir)/fallback \
|
|
|
|
$(srcdir)/sandbox \
|
2011-11-03 14:33:31 +04:00
|
|
|
$(srcdir)/linux \
|
2011-12-05 14:34:27 +04:00
|
|
|
$(srcdir)/windows \
|
2012-03-21 10:36:17 +04:00
|
|
|
$(srcdir)/cocoa \
|
2011-10-06 02:15:45 +04:00
|
|
|
$(NULL)
|
|
|
|
|
|
|
|
include $(DEPTH)/config/autoconf.mk
|
|
|
|
|
|
|
|
LIBRARY_NAME = hal_s
|
|
|
|
FORCE_STATIC_LIB = 1
|
|
|
|
LIBXUL_LIBRARY = 1
|
|
|
|
EXPORT_LIBRARY = 1
|
2012-07-12 23:34:18 +04:00
|
|
|
FAIL_ON_WARNINGS = 1
|
2011-10-06 02:15:45 +04:00
|
|
|
|
|
|
|
EXPORTS_NAMESPACES = mozilla
|
|
|
|
EXPORTS_mozilla = \
|
|
|
|
Hal.h \
|
|
|
|
HalImpl.h \
|
|
|
|
HalSandbox.h \
|
2012-02-05 23:51:06 +04:00
|
|
|
HalSensor.h \
|
2012-02-02 10:09:00 +04:00
|
|
|
HalTypes.h \
|
2012-03-07 15:03:25 +04:00
|
|
|
HalWakeLock.h \
|
2011-10-06 02:15:45 +04:00
|
|
|
$(NULL)
|
|
|
|
|
|
|
|
CPPSRCS = \
|
|
|
|
Hal.cpp \
|
|
|
|
SandboxHal.cpp \
|
2011-12-18 01:04:26 +04:00
|
|
|
WindowIdentifier.cpp \
|
2012-03-07 15:03:25 +04:00
|
|
|
HalWakeLock.cpp \
|
2011-10-06 02:15:45 +04:00
|
|
|
$(NULL)
|
|
|
|
|
2011-08-03 22:12:08 +04:00
|
|
|
ifeq (stub,$(MOZ_GAMEPAD_BACKEND))
|
|
|
|
CPPSRCS += FallbackGamepad.cpp
|
|
|
|
endif
|
2011-08-03 16:06:00 +04:00
|
|
|
ifeq (cocoa,$(MOZ_GAMEPAD_BACKEND))
|
|
|
|
CPPSRCS += CocoaGamepad.cpp
|
|
|
|
endif
|
2011-08-03 22:12:08 +04:00
|
|
|
ifeq (windows,$(MOZ_GAMEPAD_BACKEND))
|
|
|
|
CPPSRCS += WindowsGamepad.cpp
|
|
|
|
endif
|
2011-08-03 22:12:08 +04:00
|
|
|
ifeq (linux,$(MOZ_GAMEPAD_BACKEND))
|
|
|
|
CPPSRCS += LinuxGamepad.cpp
|
|
|
|
endif
|
2011-08-03 22:12:08 +04:00
|
|
|
|
2011-11-22 23:51:51 +04:00
|
|
|
ifeq (android,$(MOZ_WIDGET_TOOLKIT))
|
2012-02-05 23:51:06 +04:00
|
|
|
CPPSRCS += \
|
|
|
|
AndroidHal.cpp \
|
|
|
|
AndroidSensor.cpp \
|
2012-05-03 14:05:32 +04:00
|
|
|
FallbackPower.cpp \
|
2012-07-06 14:42:10 +04:00
|
|
|
FallbackAlarm.cpp \
|
2012-02-05 23:51:06 +04:00
|
|
|
$(NULL)
|
2011-12-20 23:31:53 +04:00
|
|
|
else ifeq (gonk,$(MOZ_WIDGET_TOOLKIT))
|
2012-02-05 23:51:06 +04:00
|
|
|
CPPSRCS += \
|
|
|
|
GonkHal.cpp \
|
2012-05-03 14:05:32 +04:00
|
|
|
LinuxPower.cpp \
|
2012-02-06 06:41:15 +04:00
|
|
|
GonkSensor.cpp \
|
2012-04-13 08:02:33 +04:00
|
|
|
UeventPoller.cpp \
|
2012-04-22 22:09:22 +04:00
|
|
|
GonkSwitch.cpp \
|
2012-09-19 19:17:13 +04:00
|
|
|
GonkFMRadio.cpp \
|
2012-02-05 23:51:06 +04:00
|
|
|
$(NULL)
|
2011-11-03 14:33:31 +04:00
|
|
|
else ifeq (Linux,$(OS_TARGET))
|
2012-02-05 23:51:06 +04:00
|
|
|
CPPSRCS += \
|
2012-05-03 14:05:32 +04:00
|
|
|
LinuxPower.cpp \
|
2012-05-09 01:36:07 +04:00
|
|
|
FallbackScreenConfiguration.cpp \
|
2012-02-05 23:51:06 +04:00
|
|
|
FallbackSensor.cpp \
|
2012-05-03 14:05:32 +04:00
|
|
|
FallbackVibration.cpp \
|
2012-07-06 14:42:10 +04:00
|
|
|
FallbackAlarm.cpp \
|
2012-02-05 23:51:06 +04:00
|
|
|
$(NULL)
|
2011-11-03 14:33:31 +04:00
|
|
|
ifdef MOZ_ENABLE_DBUS
|
|
|
|
CPPSRCS += UPowerClient.cpp
|
2012-05-03 14:05:32 +04:00
|
|
|
else
|
|
|
|
CPPSRCS += FallbackBattery.cpp
|
2011-11-03 14:33:31 +04:00
|
|
|
endif
|
2011-12-05 14:34:27 +04:00
|
|
|
else ifeq (WINNT,$(OS_TARGET))
|
2012-02-05 23:51:06 +04:00
|
|
|
CPPSRCS += \
|
|
|
|
WindowsBattery.cpp \
|
2012-05-01 07:04:30 +04:00
|
|
|
WindowsSensor.cpp \
|
2012-05-03 14:05:32 +04:00
|
|
|
FallbackVibration.cpp \
|
2012-05-09 01:36:07 +04:00
|
|
|
FallbackScreenConfiguration.cpp \
|
2012-05-03 14:05:32 +04:00
|
|
|
FallbackPower.cpp \
|
2012-07-06 14:42:10 +04:00
|
|
|
FallbackAlarm.cpp \
|
2012-02-05 23:51:06 +04:00
|
|
|
$(NULL)
|
2012-03-21 10:36:17 +04:00
|
|
|
else ifeq (cocoa,$(MOZ_WIDGET_TOOLKIT))
|
|
|
|
CPPSRCS += \
|
2012-09-22 07:36:14 +04:00
|
|
|
CocoaBattery.cpp \
|
2012-05-03 14:05:32 +04:00
|
|
|
FallbackVibration.cpp \
|
|
|
|
FallbackPower.cpp \
|
2012-05-09 01:36:07 +04:00
|
|
|
FallbackScreenConfiguration.cpp \
|
2012-07-06 14:42:10 +04:00
|
|
|
FallbackAlarm.cpp \
|
2012-03-21 10:36:17 +04:00
|
|
|
$(NULL)
|
|
|
|
CMMSRCS += \
|
|
|
|
CocoaSensor.mm \
|
|
|
|
smslib.mm \
|
|
|
|
$(NULL)
|
2012-09-06 15:01:55 +04:00
|
|
|
else ifneq (,$(filter OpenBSD NetBSD FreeBSD DragonFly,$(OS_TARGET)))
|
2012-05-29 12:57:15 +04:00
|
|
|
CPPSRCS += \
|
|
|
|
FallbackSensor.cpp \
|
|
|
|
FallbackVibration.cpp \
|
|
|
|
FallbackPower.cpp \
|
|
|
|
FallbackScreenConfiguration.cpp \
|
2012-07-06 14:42:10 +04:00
|
|
|
FallbackAlarm.cpp \
|
2012-05-29 12:57:15 +04:00
|
|
|
$(NULL)
|
|
|
|
ifdef MOZ_ENABLE_DBUS
|
|
|
|
CPPSRCS += UPowerClient.cpp
|
|
|
|
else
|
|
|
|
CPPSRCS += FallbackBattery.cpp
|
|
|
|
endif
|
2011-11-02 19:28:26 +04:00
|
|
|
else
|
2012-02-05 23:51:06 +04:00
|
|
|
CPPSRCS += \
|
2012-05-03 14:05:32 +04:00
|
|
|
FallbackBattery.cpp \
|
2012-02-05 23:51:06 +04:00
|
|
|
FallbackSensor.cpp \
|
2012-05-03 14:05:32 +04:00
|
|
|
FallbackVibration.cpp \
|
|
|
|
FallbackPower.cpp \
|
2012-05-09 01:36:07 +04:00
|
|
|
FallbackScreenConfiguration.cpp \
|
2012-07-06 14:42:10 +04:00
|
|
|
FallbackAlarm.cpp \
|
2012-02-05 23:51:06 +04:00
|
|
|
$(NULL)
|
2011-11-02 19:28:26 +04:00
|
|
|
endif
|
2011-10-06 02:15:45 +04:00
|
|
|
|
2011-08-03 16:06:00 +04:00
|
|
|
ifdef MOZ_GAMEPAD
|
|
|
|
LOCAL_INCLUDES = -I$(topsrcdir)/dom/base
|
|
|
|
endif
|
|
|
|
|
2012-05-03 14:05:32 +04:00
|
|
|
# Fallbacks for backends implemented on Gonk only.
|
2012-02-02 10:09:00 +04:00
|
|
|
ifneq (gonk,$(MOZ_WIDGET_TOOLKIT)) #{
|
2012-04-17 02:35:33 +04:00
|
|
|
CPPSRCS += \
|
|
|
|
FallbackLights.cpp \
|
|
|
|
FallbackTime.cpp \
|
|
|
|
FallbackWakeLocks.cpp \
|
2012-04-22 22:09:22 +04:00
|
|
|
FallbackSwitch.cpp \
|
2012-05-03 14:05:32 +04:00
|
|
|
FallbackScreenPower.cpp \
|
2012-08-05 09:09:39 +04:00
|
|
|
FallbackProcessPriority.cpp \
|
2012-09-19 19:17:13 +04:00
|
|
|
FallbackFMRadio.cpp \
|
2012-10-04 13:28:34 +04:00
|
|
|
FallbackFactoryReset.cpp \
|
2012-04-17 02:35:33 +04:00
|
|
|
$(NULL)
|
2012-02-02 10:09:00 +04:00
|
|
|
endif #}
|
|
|
|
|
2012-05-03 14:05:32 +04:00
|
|
|
# Fallbacks for backends implemented on Android only.
|
2012-03-20 17:09:45 +04:00
|
|
|
ifneq (android,$(MOZ_WIDGET_TOOLKIT))
|
2012-05-09 01:36:07 +04:00
|
|
|
CPPSRCS += FallbackNetwork.cpp
|
|
|
|
endif
|
|
|
|
|
2011-10-06 02:15:45 +04:00
|
|
|
include $(topsrcdir)/config/config.mk
|
|
|
|
include $(topsrcdir)/ipc/chromium/chromium-config.mk
|
|
|
|
include $(topsrcdir)/config/rules.mk
|
2011-11-03 14:33:31 +04:00
|
|
|
|
2013-03-28 05:20:27 +04:00
|
|
|
CFLAGS += $(GLIB_CFLAGS) $(MOZ_DBUS_GLIB_CFLAGS)
|
|
|
|
CXXFLAGS += $(GLIB_CFLAGS) $(MOZ_DBUS_GLIB_CFLAGS)
|
2012-05-09 01:36:07 +04:00
|
|
|
|
|
|
|
ifeq (gonk,$(MOZ_WIDGET_TOOLKIT))
|
|
|
|
# So that we can call nsScreenManagerGonk::GetConfiguration().
|
|
|
|
LOCAL_INCLUDES += -I$(topsrcdir)/widget/gonk
|
|
|
|
LOCAL_INCLUDES += -I$(topsrcdir)/widget/xpwidgets
|
2012-07-06 14:42:10 +04:00
|
|
|
endif
|