Make off-target loc hal libraries built

CRs-fixed: 605821

Change-Id: I334ccf21f6e5d045d32c718cb060c67e167be733
This commit is contained in:
Dongmei Wang 2014-08-14 17:27:52 -07:00 committed by Gerrit - the friendly Code Review server
parent 91ece00117
commit 3e16bc32b5
6 changed files with 12 additions and 8 deletions

View file

@ -34,7 +34,7 @@ extern "C" {
#endif /* __cplusplus */ #endif /* __cplusplus */
#include <gps_extended_c.h> #include <gps_extended_c.h>
#ifdef USE_GLIB #if defined(USE_GLIB) || defined(OFF_TARGET)
#include <string.h> #include <string.h>
#endif #endif

View file

@ -61,8 +61,10 @@
#endif /* USE_GLIB */ #endif /* USE_GLIB */
#ifdef USE_GLIB #if defined(USE_GLIB) && !defined(OFF_TARGET)
#include <glib.h> #include <glib.h>
#endif
#ifdef USE_GLIB
#include <sys/syscall.h> #include <sys/syscall.h>
#endif /* USE_GLIB */ #endif /* USE_GLIB */

View file

@ -41,7 +41,7 @@
#include <loc_timer.h> #include <loc_timer.h>
#include <LocEngAdapter.h> #include <LocEngAdapter.h>
#ifdef USE_GLIB #if defined(USE_GLIB) && !defined(OFF_TARGET)
#include <glib.h> #include <glib.h>
#endif /* USE_GLIB */ #endif /* USE_GLIB */

View file

@ -43,7 +43,7 @@
#ifndef SSID_BUF_SIZE #ifndef SSID_BUF_SIZE
#define SSID_BUF_SIZE (32+1) #define SSID_BUF_SIZE (32+1)
#endif #endif
#ifdef USE_GLIB #if defined(USE_GLIB) && !defined(OFF_TARGET)
#include <glib.h> #include <glib.h>

View file

@ -51,10 +51,13 @@ extern "C" {
#ifdef USE_GLIB #ifdef USE_GLIB
#ifndef OFF_TARGET
#define strlcat g_strlcat #define strlcat g_strlcat
#define strlcpy g_strlcpy #define strlcpy g_strlcpy
#else
#define strlcat strncat
#define strlcpy strncpy
#endif
#define ALOGE(format, x...) TS_PRINTF("E/%s (%d): " format , LOG_TAG, getpid(), ##x) #define ALOGE(format, x...) TS_PRINTF("E/%s (%d): " format , LOG_TAG, getpid(), ##x)
#define ALOGW(format, x...) TS_PRINTF("W/%s (%d): " format , LOG_TAG, getpid(), ##x) #define ALOGW(format, x...) TS_PRINTF("W/%s (%d): " format , LOG_TAG, getpid(), ##x)
#define ALOGI(format, x...) TS_PRINTF("I/%s (%d): " format , LOG_TAG, getpid(), ##x) #define ALOGI(format, x...) TS_PRINTF("I/%s (%d): " format , LOG_TAG, getpid(), ##x)
@ -66,7 +69,6 @@ extern "C" {
#define LOC_EXT_CREATE_THREAD_CB_PLATFORM_LIB_ABSTRACTION createPthread #define LOC_EXT_CREATE_THREAD_CB_PLATFORM_LIB_ABSTRACTION createPthread
#define ELAPSED_MILLIS_SINCE_BOOT_PLATFORM_LIB_ABSTRACTION (elapsedMillisSinceBoot()) #define ELAPSED_MILLIS_SINCE_BOOT_PLATFORM_LIB_ABSTRACTION (elapsedMillisSinceBoot())
#else #else
pid_t gettid(void); pid_t gettid(void);

View file

@ -39,7 +39,7 @@
#include <time.h> #include <time.h>
#include <loc_cfg.h> #include <loc_cfg.h>
#include <log_util.h> #include <log_util.h>
#ifdef USE_GLIB #if defined(USE_GLIB) && !defined(OFF_TARGET)
#include <glib.h> #include <glib.h>
#endif #endif
#include "platform_lib_includes.h" #include "platform_lib_includes.h"