mirror of
https://github.com/SpartanJ/eepp.git
synced 2026-08-18 06:55:48 +03:00
Android build fixes and improvements.
Updated jpeg-compressor. eterm: More clean up and improvements.
This commit is contained in:
@@ -26,13 +26,67 @@ android {
|
||||
}
|
||||
externalNativeBuild {
|
||||
ndkBuild {
|
||||
arguments "APP_LDLIBS=-llog -lGLESv2 -lGLESv1_CM -lm -lz -lOpenSLES -lEGL -landroid"
|
||||
arguments "APP_PLATFORM=android-19"
|
||||
arguments getProcessesCountArg()
|
||||
}
|
||||
}
|
||||
signingConfig signingConfigs.debug
|
||||
}
|
||||
flavorDimensions "eepp"
|
||||
productFlavors {
|
||||
ecode {
|
||||
buildConfigField "String", "SO_NAME", "\"ecode\""
|
||||
applicationId "com.ensoft.ecode"
|
||||
dimension "eepp"
|
||||
resValue "string", "app_name", "ecode"
|
||||
externalNativeBuild {
|
||||
ndkBuild {
|
||||
arguments "APP_MODULES=ecode"
|
||||
}
|
||||
}
|
||||
}
|
||||
eterm {
|
||||
buildConfigField "String", "SO_NAME", "\"eterm\""
|
||||
applicationId "com.ensoft.eterm"
|
||||
dimension "eepp"
|
||||
resValue "string", "app_name", "eterm"
|
||||
externalNativeBuild {
|
||||
ndkBuild {
|
||||
arguments "APP_MODULES=eterm"
|
||||
}
|
||||
}
|
||||
}
|
||||
fulltest {
|
||||
buildConfigField "String", "SO_NAME", "\"main\""
|
||||
versionNameSuffix "-test"
|
||||
dimension "eepp"
|
||||
resValue "string", "app_name", "eepp"
|
||||
externalNativeBuild {
|
||||
ndkBuild {
|
||||
arguments "APP_MODULES=main"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
buildTypes {
|
||||
debug {
|
||||
debuggable true
|
||||
externalNativeBuild {
|
||||
ndkBuild {
|
||||
arguments "APP_CFLAGS=-g -DDEBUG -DEE_DEBUG"
|
||||
arguments "APP_CPPFLAGS=-std=c++14 -frtti -fexceptions"
|
||||
arguments "APP_OPTIM=debug"
|
||||
}
|
||||
}
|
||||
}
|
||||
release {
|
||||
externalNativeBuild {
|
||||
ndkBuild {
|
||||
arguments "APP_CFLAGS=-fno-strict-aliasing -O3 -s -DNDEBUG -ffast-math"
|
||||
arguments "APP_CPPFLAGS=-std=c++14 -frtti -fexceptions"
|
||||
}
|
||||
}
|
||||
minifyEnabled false
|
||||
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
|
||||
}
|
||||
|
||||
@@ -46,6 +46,50 @@ LOCAL_STATIC_LIBRARIES := eepp
|
||||
include $(BUILD_SHARED_LIBRARY)
|
||||
#************ external_shader ************
|
||||
|
||||
#************* ecode *************
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
LOCAL_PATH := $(EEPP_BASE_PATH)
|
||||
|
||||
LOCAL_MODULE := ecode
|
||||
|
||||
LOCAL_LDLIBS := $(EEPP_LDLIBS)
|
||||
|
||||
LOCAL_CFLAGS := $(EEPP_C_FLAGS)
|
||||
|
||||
LOCAL_C_INCLUDES := $(EEPP_C_INCLUDES)
|
||||
|
||||
CORE_SRCS := tools/ecode/*.cpp tools/ecode/plugins/autocomplete/*.cpp tools/ecode/plugins/linter/*.cpp tools/ecode/plugins/formatter/*.cpp
|
||||
|
||||
LOCAL_SRC_FILES := $(SDL_MAIN_PATH) $(foreach F, $(CORE_SRCS), $(addprefix $(dir $(F)),$(notdir $(wildcard $(LOCAL_PATH)/$(F)))))
|
||||
|
||||
LOCAL_STATIC_LIBRARIES := eepp efsw
|
||||
|
||||
include $(BUILD_SHARED_LIBRARY)
|
||||
#************ ecode ************
|
||||
|
||||
#************* etern *************
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
LOCAL_PATH := $(EEPP_BASE_PATH)
|
||||
|
||||
LOCAL_MODULE := eterm
|
||||
|
||||
LOCAL_LDLIBS := $(EEPP_LDLIBS)
|
||||
|
||||
LOCAL_CFLAGS := $(EEPP_C_FLAGS)
|
||||
|
||||
LOCAL_C_INCLUDES := $(EEPP_C_INCLUDES)
|
||||
|
||||
CORE_SRCS := tools/eterm/*.cpp tools/eterm/system/*.cpp tools/eterm/terminal/*.cpp
|
||||
|
||||
LOCAL_SRC_FILES := $(SDL_MAIN_PATH) $(foreach F, $(CORE_SRCS), $(addprefix $(dir $(F)),$(notdir $(wildcard $(LOCAL_PATH)/$(F)))))
|
||||
|
||||
LOCAL_STATIC_LIBRARIES := eepp
|
||||
|
||||
include $(BUILD_SHARED_LIBRARY)
|
||||
#************ etern ************
|
||||
|
||||
#************* full_test *************
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
||||
@@ -3,21 +3,5 @@ APP_PROJECT_PATH := $(call my-dir)/..
|
||||
EE_SDL_VERSION := EE_SDL_VERSION_2
|
||||
|
||||
EE_GLES_VERSION := -DEE_GLES2 -DSOIL_GLES2 -DSDL_GLES2 -DEE_GLES1 -DSOIL_GLES1 -DSDL_GLES1
|
||||
EE_GLES_LINK := -lGLESv2 -lGLESv1_CM
|
||||
|
||||
APP_STL := c++_static
|
||||
|
||||
APP_LDLIBS := -llog $(EE_GLES_LINK) -lm -lz -lOpenSLES -lEGL -landroid
|
||||
|
||||
#Debug Build
|
||||
#APP_CFLAGS := -g -DDEBUG -DEE_DEBUG
|
||||
#APP_CPPFLAGS := -std=c++14 -frtti -fexceptions
|
||||
#APP_OPTIM := debug
|
||||
|
||||
#Release Build
|
||||
APP_CFLAGS := -fno-strict-aliasing -O3 -s -DNDEBUG -ffast-math
|
||||
APP_CPPFLAGS := -std=c++14 -frtti -fexceptions
|
||||
|
||||
APP_PLATFORM := android-16
|
||||
APP_MODULES := main
|
||||
APP_ABI := armeabi-v7a arm64-v8a x86 x86_64
|
||||
|
||||
@@ -20,7 +20,8 @@ EEPP_C_INCLUDES := \
|
||||
$(EEPP_THIRD_PARTY_PATH)/libvorbis/include \
|
||||
$(EEPP_THIRD_PARTY_PATH)/libogg/include \
|
||||
$(EEPP_THIRD_PARTY_PATH)/mbedtls/include \
|
||||
$(EEPP_THIRD_PARTY_PATH)/mojoAL
|
||||
$(EEPP_THIRD_PARTY_PATH)/mojoAL \
|
||||
$(EEPP_THIRD_PARTY_PATH)/efsw/include
|
||||
|
||||
EEPP_C_FLAGS := \
|
||||
-Wl,--undefined=Java_org_libsdl_app_SDLActivity_nativeInit \
|
||||
@@ -35,6 +36,7 @@ EEPP_C_FLAGS := \
|
||||
-DEE_MBEDTLS \
|
||||
-D$(EE_SDL_VERSION) \
|
||||
-DAL_LIBTYPE_STATIC \
|
||||
-DNO_POSIX_SPAWN \
|
||||
-I$(EEPP_INC_PATH) \
|
||||
-I$(EEPP_BASE_PATH)
|
||||
|
||||
@@ -244,7 +246,6 @@ endif
|
||||
LOCAL_STATIC_LIBRARIES := cpufeatures
|
||||
|
||||
include $(BUILD_SHARED_LIBRARY)
|
||||
#**************** SDL 2 ***************
|
||||
|
||||
###########################
|
||||
#
|
||||
@@ -266,3 +267,24 @@ LOCAL_LDLIBS := -llog
|
||||
include $(BUILD_SHARED_LIBRARY)
|
||||
|
||||
$(call import-module,android/cpufeatures)
|
||||
#**************** SDL 2 ***************
|
||||
|
||||
|
||||
#*************** EFSW ***************
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
LOCAL_PATH := $(EEPP_THIRD_PARTY_PATH)
|
||||
|
||||
LOCAL_MODULE := efsw
|
||||
|
||||
LIBPNG_SRCS := \
|
||||
efsw/src/efsw/*.cpp \
|
||||
efsw/src/efsw/platform/posix/*.cpp
|
||||
|
||||
LOCAL_C_INCLUDES := $(LOCAL_PATH)/efsw/include $(LOCAL_PATH)/efsw/src
|
||||
LOCAL_CFLAGS := -Os -DEFSW_USE_CXX11
|
||||
|
||||
LOCAL_SRC_FILES := $(foreach F, $(LIBPNG_SRCS), $(addprefix $(dir $(F)),$(notdir $(wildcard $(LOCAL_PATH)/$(F)))))
|
||||
|
||||
include $(BUILD_STATIC_LIBRARY)
|
||||
#*************** EFSW ***************
|
||||
|
||||
@@ -5,8 +5,7 @@
|
||||
android:versionName="1.0"
|
||||
android:installLocation="auto">
|
||||
<application android:label="@string/app_name"
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
android:debuggable="true"
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
android:allowBackup="true"
|
||||
android:theme="@android:style/Theme.NoTitleBar.Fullscreen"
|
||||
android:hardwareAccelerated="true" >
|
||||
|
||||
@@ -2,7 +2,6 @@ package org.libsdl.app;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.util.Arrays;
|
||||
import java.util.Hashtable;
|
||||
import java.lang.reflect.Method;
|
||||
import java.lang.Math;
|
||||
@@ -31,6 +30,8 @@ import android.content.pm.ActivityInfo;
|
||||
import android.content.pm.PackageManager;
|
||||
import android.content.pm.ApplicationInfo;
|
||||
|
||||
import com.ensoft.eepp.BuildConfig;
|
||||
|
||||
/**
|
||||
SDL Activity
|
||||
*/
|
||||
@@ -143,7 +144,8 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
||||
// "SDL2_mixer",
|
||||
// "SDL2_net",
|
||||
// "SDL2_ttf",
|
||||
"main"
|
||||
// "main"
|
||||
BuildConfig.SO_NAME
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<string name="app_name">eepp</string>
|
||||
</resources>
|
||||
|
||||
Reference in New Issue
Block a user