Unbreak gen command and sync with current tree
Fix location of UnsupportedAppUsage.java. Update templates to match current sources. Add set-up sanity checks to gen script. Bug: 151443957 Test: ./gen and observe no source changes Change-Id: I095ef85ba9b2ef6617c451221a35f3545c3933a3
This commit is contained in:
parent
08768df307
commit
62d2c9c82c
3 changed files with 23 additions and 8 deletions
|
@ -1,6 +1,18 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
set -u
|
set -u
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
|
if [ -z "$ANDROID_BUILD_TOP" ] ; then
|
||||||
|
echo "ANDROID_BUILD_TOP is not set, did you run lunch?"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Avoid spewing files in any location other than the intended one.
|
||||||
|
if [ ! -x "$PWD/gen" ] ; then
|
||||||
|
echo "Run this script from its parent directory".
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
rm -rf out generated
|
rm -rf out generated
|
||||||
|
|
||||||
mkdir out
|
mkdir out
|
||||||
|
@ -92,7 +104,7 @@ rm src/*.class
|
||||||
|
|
||||||
# Add UnsupportedAppUsage.java to known sources.
|
# Add UnsupportedAppUsage.java to known sources.
|
||||||
mkdir -p out/android/compat/annotation
|
mkdir -p out/android/compat/annotation
|
||||||
cp ../../../../../tools/platform-compat/annotation/src/java/android/compat/annotation/UnsupportedAppUsage.java out/android/compat/annotation
|
cp ${ANDROID_BUILD_TOP}/tools/platform-compat/java/android/compat/annotation/UnsupportedAppUsage.java out/android/compat/annotation
|
||||||
|
|
||||||
pushd out > /dev/null
|
pushd out > /dev/null
|
||||||
mkdir classes
|
mkdir classes
|
||||||
|
@ -153,23 +165,23 @@ compareGenerated() {
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
compareGenerated ../../../../base/core/jni generated/C com_google_android_gles_jni_GLImpl.cpp
|
compareGenerated ${ANDROID_BUILD_TOP}/frameworks/base/core/jni generated/C com_google_android_gles_jni_GLImpl.cpp
|
||||||
compareGenerated ../../../../base/opengl/java/com/google/android/gles_jni generated/com/google/android/gles_jni GLImpl.java
|
compareGenerated ${ANDROID_BUILD_TOP}/frameworks/base/opengl/java/com/google/android/gles_jni generated/com/google/android/gles_jni GLImpl.java
|
||||||
|
|
||||||
for x in GL.java GL10.java GL10Ext.java GL11.java GL11Ext.java GL11ExtensionPack.java
|
for x in GL.java GL10.java GL10Ext.java GL11.java GL11Ext.java GL11ExtensionPack.java
|
||||||
do
|
do
|
||||||
compareGenerated ../../../../base/opengl/java/javax/microedition/khronos/opengles generated/javax/microedition/khronos/opengles $x
|
compareGenerated ${ANDROID_BUILD_TOP}/frameworks/base/opengl/java/javax/microedition/khronos/opengles generated/javax/microedition/khronos/opengles $x
|
||||||
done
|
done
|
||||||
|
|
||||||
for x in EGL14 EGL15 EGLExt GLES10 GLES10Ext GLES11 GLES11Ext GLES20 GLES30 GLES31 GLES31Ext GLES32
|
for x in EGL14 EGL15 EGLExt GLES10 GLES10Ext GLES11 GLES11Ext GLES20 GLES30 GLES31 GLES31Ext GLES32
|
||||||
do
|
do
|
||||||
compareGenerated ../../../../base/opengl/java/android/opengl generated/android/opengl ${x}.java
|
compareGenerated ${ANDROID_BUILD_TOP}/frameworks/base/opengl/java/android/opengl generated/android/opengl ${x}.java
|
||||||
compareGenerated ../../../../base/core/jni generated/C android_opengl_${x}.cpp
|
compareGenerated ${ANDROID_BUILD_TOP}/frameworks/base/core/jni generated/C android_opengl_${x}.cpp
|
||||||
done
|
done
|
||||||
|
|
||||||
for x in EGLConfig EGLContext EGLDisplay EGLObjectHandle EGLSurface EGLImage EGLSync
|
for x in EGLConfig EGLContext EGLDisplay EGLObjectHandle EGLSurface EGLImage EGLSync
|
||||||
do
|
do
|
||||||
compareGenerated ../../../../base/opengl/java/android/opengl generated/android/opengl ${x}.java
|
compareGenerated ${ANDROID_BUILD_TOP}/frameworks/base/opengl/java/android/opengl generated/android/opengl ${x}.java
|
||||||
done
|
done
|
||||||
|
|
||||||
if [ $KEEP_GENERATED == "0" ] ; then
|
if [ $KEEP_GENERATED == "0" ] ; then
|
||||||
|
|
|
@ -21,8 +21,8 @@ package android.opengl;
|
||||||
import android.compat.annotation.UnsupportedAppUsage;
|
import android.compat.annotation.UnsupportedAppUsage;
|
||||||
import android.graphics.SurfaceTexture;
|
import android.graphics.SurfaceTexture;
|
||||||
import android.view.Surface;
|
import android.view.Surface;
|
||||||
import android.view.SurfaceView;
|
|
||||||
import android.view.SurfaceHolder;
|
import android.view.SurfaceHolder;
|
||||||
|
import android.view.SurfaceView;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* EGL 1.4
|
* EGL 1.4
|
||||||
|
|
|
@ -19,6 +19,7 @@
|
||||||
package com.google.android.gles_jni;
|
package com.google.android.gles_jni;
|
||||||
|
|
||||||
import android.app.AppGlobals;
|
import android.app.AppGlobals;
|
||||||
|
import android.compat.annotation.UnsupportedAppUsage;
|
||||||
import android.content.pm.ApplicationInfo;
|
import android.content.pm.ApplicationInfo;
|
||||||
import android.content.pm.IPackageManager;
|
import android.content.pm.IPackageManager;
|
||||||
import android.os.Build;
|
import android.os.Build;
|
||||||
|
@ -26,6 +27,7 @@ import android.os.UserHandle;
|
||||||
import android.util.Log;
|
import android.util.Log;
|
||||||
|
|
||||||
import java.nio.Buffer;
|
import java.nio.Buffer;
|
||||||
|
|
||||||
import javax.microedition.khronos.opengles.GL10;
|
import javax.microedition.khronos.opengles.GL10;
|
||||||
import javax.microedition.khronos.opengles.GL10Ext;
|
import javax.microedition.khronos.opengles.GL10Ext;
|
||||||
import javax.microedition.khronos.opengles.GL11;
|
import javax.microedition.khronos.opengles.GL11;
|
||||||
|
@ -55,6 +57,7 @@ public class GLImpl implements GL10, GL10Ext, GL11, GL11Ext, GL11ExtensionPack {
|
||||||
private boolean have_OES_framebuffer_object;
|
private boolean have_OES_framebuffer_object;
|
||||||
private boolean have_OES_texture_cube_map;
|
private boolean have_OES_texture_cube_map;
|
||||||
|
|
||||||
|
@UnsupportedAppUsage
|
||||||
public GLImpl() {
|
public GLImpl() {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue