mirror of
https://github.com/TeamVanced/VancedMicroG
synced 2025-01-05 17:15:57 +01:00
Reflect UnifiedNlp changes
This commit is contained in:
parent
975ff9bd69
commit
de24dcc33c
29
Android.mk
29
Android.mk
@ -17,19 +17,34 @@ include $(CLEAR_VARS)
|
|||||||
|
|
||||||
LOCAL_MODULE_TAGS := optional
|
LOCAL_MODULE_TAGS := optional
|
||||||
unified_dir := ../UnifiedNlp
|
unified_dir := ../UnifiedNlp
|
||||||
res_dir := res $(unified_dir)/res
|
appcompat_dir := ../../../prebuilts/sdk/current/support/v7/appcompat
|
||||||
|
res_dir := res $(unified_dir)/res $(appcompat_dir)/res
|
||||||
|
|
||||||
|
LOCAL_SRC_FILES := $(call all-java-files-under, src) \
|
||||||
|
$(call all-Iaidl-files-under, src) \
|
||||||
|
$(call all-java-files-under, $(unified_dir)/src) \
|
||||||
|
|
||||||
LOCAL_SRC_FILES := $(call all-java-files-under, src)
|
|
||||||
LOCAL_SRC_FILES += $(call all-Iaidl-files-under, src)
|
|
||||||
LOCAL_SRC_FILES += $(call all-java-files-under, $(unified_dir)/src)
|
|
||||||
LOCAL_RESOURCE_DIR := $(addprefix $(LOCAL_PATH)/, $(res_dir))
|
LOCAL_RESOURCE_DIR := $(addprefix $(LOCAL_PATH)/, $(res_dir))
|
||||||
LOCAL_AAPT_FLAGS := --auto-add-overlay --extra-packages org.microg.nlp
|
|
||||||
|
LOCAL_AAPT_FLAGS := --auto-add-overlay \
|
||||||
|
--extra-packages android.support.v7.appcompat \
|
||||||
|
--extra-packages org.microg.nlp \
|
||||||
|
|
||||||
# For some reason framework has to be added here else GeocoderParams is not found,
|
# For some reason framework has to be added here else GeocoderParams is not found,
|
||||||
# this way everything else is duplicated, but atleast compiles...
|
# this way everything else is duplicated, but atleast compiles...
|
||||||
LOCAL_JAVA_LIBRARIES := com.google.android.maps framework com.android.location.provider
|
LOCAL_JAVA_LIBRARIES := com.google.android.maps \
|
||||||
|
framework \
|
||||||
|
com.android.location.provider
|
||||||
|
|
||||||
|
# Include compat v9 files if necassary
|
||||||
|
ifeq ($(shell [ $(PLATFORM_SDK_VERSION) -ge 17 ] && echo true), true)
|
||||||
|
LOCAL_JAVA_LIBRARIES += UnifiedNlpCompatV9
|
||||||
|
endif
|
||||||
|
|
||||||
|
LOCAL_STATIC_JAVA_LIBRARIES := UnifiedNlpApi \
|
||||||
|
android-support-v4 \
|
||||||
|
android-support-v7-appcompat \
|
||||||
|
|
||||||
LOCAL_STATIC_JAVA_LIBRARIES := UnifiedNlpApi
|
|
||||||
LOCAL_PACKAGE_NAME := GmsCore
|
LOCAL_PACKAGE_NAME := GmsCore
|
||||||
LOCAL_SDK_VERSION := current
|
LOCAL_SDK_VERSION := current
|
||||||
LOCAL_PRIVILEGED_MODULE := true
|
LOCAL_PRIVILEGED_MODULE := true
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
|
|
||||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
package="com.google.android.gms"
|
package="com.google.android.gms"
|
||||||
android:versionCode="5089036">
|
android:versionCode="6111030">
|
||||||
|
|
||||||
<uses-sdk android:minSdkVersion="16" />
|
<uses-sdk android:minSdkVersion="16" />
|
||||||
|
|
||||||
@ -31,6 +31,7 @@
|
|||||||
<uses-permission android:name="android.permission.USE_CREDENTIALS" />
|
<uses-permission android:name="android.permission.USE_CREDENTIALS" />
|
||||||
|
|
||||||
<application
|
<application
|
||||||
|
android:theme="@style/AppTheme"
|
||||||
android:label="@string/gms_app_name">
|
android:label="@string/gms_app_name">
|
||||||
<uses-library
|
<uses-library
|
||||||
android:name="com.android.location.provider"
|
android:name="com.android.location.provider"
|
||||||
@ -77,8 +78,8 @@
|
|||||||
</service>
|
</service>
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="org.microg.nlp.ui.LocationBackendConfig"
|
android:name="org.microg.nlp.ui.SettingsActivity"
|
||||||
android:theme="@android:style/Theme.Holo.Light">
|
android:label="@string/nlp_settings_label">
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
<action android:name="android.intent.action.MAIN" />
|
<action android:name="android.intent.action.MAIN" />
|
||||||
<category android:name="android.intent.category.LAUNCHER" />
|
<category android:name="android.intent.category.LAUNCHER" />
|
||||||
|
@ -87,12 +87,12 @@ public class AuthManagerServiceImpl extends IAuthManagerService.Stub {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void checkPackage(String packageName, int callerUid, int callingUid) {
|
private void checkPackage(String packageName, int callerUid, int callingUid) {
|
||||||
if (callerUid != callingUid) {
|
if (callerUid != 0 && callerUid != callingUid) {
|
||||||
throw new SecurityException("callerUid [" + callerUid + "] and real calling uid [" + callingUid + "] mismatch!");
|
throw new SecurityException("callerUid [" + callerUid + "] and real calling uid [" + callingUid + "] mismatch!");
|
||||||
}
|
}
|
||||||
String[] packagesForUid = context.getPackageManager().getPackagesForUid(callerUid);
|
String[] packagesForUid = context.getPackageManager().getPackagesForUid(callingUid);
|
||||||
if (!Arrays.asList(packagesForUid).contains(packageName)) {
|
if (packagesForUid != null && !Arrays.asList(packagesForUid).contains(packageName)) {
|
||||||
throw new SecurityException("callerUid [" + callerUid + "] is not related to packageName [" + packageName + "]");
|
throw new SecurityException("callingUid [" + callingUid + "] is not related to packageName [" + packageName + "]");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user