forked from Xiaojuanmao/Quic-Bench
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
148 additions
and
113 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
# Proguard config for apps that depend on cronet_impl_native_java.jar. | ||
|
||
# This constructor is called using the reflection from Cronet API (cronet_api.jar). | ||
-keep class org.chromium.net.impl.NativeCronetProvider { | ||
public <init>(android.content.Context); | ||
} | ||
|
||
# Suppress unnecessary warnings. | ||
-dontnote org.chromium.net.ProxyChangeListener$ProxyReceiver | ||
-dontnote org.chromium.net.AndroidKeyStore | ||
# Needs 'void setTextAppearance(int)' (API level 23). | ||
-dontwarn org.chromium.base.ApiCompatibilityUtils | ||
# Needs 'boolean onSearchRequested(android.view.SearchEvent)' (API level 23). | ||
-dontwarn org.chromium.base.WindowCallbackWrapper | ||
|
||
# Generated for chrome apk and not included into cronet. | ||
-dontwarn org.chromium.base.library_loader.NativeLibraries | ||
-dontwarn org.chromium.base.multidex.ChromiumMultiDexInstaller | ||
-dontwarn org.chromium.base.metrics.CachedMetrics | ||
-dontwarn org.chromium.base.library_loader.LibraryLoader | ||
-dontwarn org.chromium.base.SysUtils | ||
|
||
# Objects of this type are passed around by native code, but the class | ||
# is never used directly by native code. Since the class is not loaded, it does | ||
# not need to be preserved as an entry point. | ||
-dontnote org.chromium.net.UrlRequest$ResponseHeadersMap | ||
|
||
# This class should be explicitly kept to avoid failure if | ||
# class/merging/horizontal proguard optimization is enabled. | ||
-keep class org.chromium.base.CollectionUtil | ||
|
||
|
||
# Proguard config for apps that depend on cronet_impl_platform_java.jar. | ||
|
||
# This constructor is called using the reflection from Cronet API (cronet_api.jar). | ||
-keep class org.chromium.net.impl.JavaCronetProvider { | ||
public <init>(android.content.Context); | ||
} | ||
|
||
-keepattributes Signature,InnerClasses,SourceFile,LineNumberTable | ||
-dontwarn io.netty.** | ||
-keep class io.netty.** { *; } | ||
|
||
# Do not obfuscate this class for testing since some of the tests check the class | ||
# name in order to check that an instantiated engine is the Java one. | ||
-keepnames class org.chromium.net.impl.JavaCronetEngine | ||
|
||
|
||
# Generated for chrome apk and not included into cronet. | ||
-dontwarn org.chromium.base.library_loader.NativeLibraries | ||
|
||
#-keep class org.chromium.base.AnimationFrameTimeHistogram | ||
#-keep class org.chromium.base.metrics.RecordUserAction | ||
#-keep class org.chromium.base.JNIUtils | ||
|
||
-keep class org.chromium.** { | ||
native <methods>; | ||
} | ||
|
||
# Understand the @Keep support annotation. | ||
-keep class android.support.annotation.Keep | ||
|
||
-keepclasseswithmembers class * { | ||
@org.chromium.base.annotations.CalledByNative <methods>; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# Keep annotations used by chromium to keep members referenced by native code | ||
-keep class org.chromium.base.annotations.*Native* | ||
-keep class org.chromium.base.annotations.JNINamespace | ||
-keepclasseswithmembers class org.chromium.** { | ||
@org.chromium.base.annotations.AccessedByNative <fields>; | ||
} | ||
-keepclasseswithmembers class org.chromium.** { | ||
@org.chromium.base.annotations.*Native* <methods>; | ||
} | ||
|
||
# TODO(mef) remove unnecessary classes from base, so we don't have to preserve | ||
# their methods | ||
-keepclasseswithmembers class org.chromium.** { | ||
native <methods>; | ||
} | ||
|
||
# TODO(xunjieli): Find an alternative to explictly preserving public classes. | ||
-keep public class org.chromium.net.* | ||
|
||
-keep class org.chromium.net.impl.CronetUrlRequest$HeadersList | ||
-keep class org.chromium.net.impl.ChromiumUrlRequest$ResponseHeadersMap | ||
|
||
# Needed so that multiple optimization passes will detect annotations | ||
-keepattributes *Annotation* | ||
|
||
# Keep methods used by reflection | ||
-keep class org.chromium.base.annotations.UsedByReflection | ||
-keep @org.chromium.base.annotations.UsedByReflection class * | ||
-keepclassmembers class * { | ||
@org.chromium.base.annotations.UsedByReflection *; | ||
} | ||
|
||
# Suppress unnecessary warnings. | ||
-dontnote org.chromium.net.ProxyChangeListener$ProxyReceiver | ||
-dontnote org.chromium.net.AndroidKeyStore | ||
# Needs 'void setTextAppearance(int)' (API level 23). | ||
-dontwarn org.chromium.base.ApiCompatibilityUtils | ||
# Needs 'boolean onSearchRequested(android.view.SearchEvent)' (API level 23). | ||
-dontwarn org.chromium.base.WindowCallbackWrapper | ||
# Generated for chrome apk and not included into cronet. | ||
-dontwarn org.chromium.base.library_loader.NativeLibraries | ||
# Generated for chrome apk and not included into cronet. | ||
-dontwarn org.chromium.base.multidex.ChromiumMultiDexInstaller | ||
# Objects of this type are passed around by native code, but the class | ||
# is never used directly by native code. Since the class is not loaded, it does | ||
# not need to be preserved as an entry point. | ||
-dontnote org.chromium.net.UrlRequest$ResponseHeadersMap | ||
# https://android.googlesource.com/platform/sdk/+/marshmallow-mr1-release/files/proguard-android.txt#54 | ||
-dontwarn android.support.** |