On 2015-03-19 10:51, Felipe Monteiro de Carvalho wrote:
> On Thu, Mar 19, 2015 at 11:26 AM, Lukasz Sokol <[email protected]> wrote:
>> Click on 'commits' then on the file link.
> 
> This leads to: 
> https://github.com/shenxh/lazarus/commit/633dc282555e9d12d945628d1c069bfcdba871d7

You can then click the "View" button to see the complete new file which
you can copy over your existing one. SVN will then show you the diff.

It doesn't seem that GitHub's web inteface allows downloading of patch
files. Seeing a I use the git mirror, I quickly created a patch file for
you - see attached. Hope that helps.


Regards,
  - Graeme -

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/
>From 633dc282555e9d12d945628d1c069bfcdba871d7 Mon Sep 17 00:00:00 2001
From: shenxh <[email protected]>
Date: Thu, 19 Mar 2015 14:06:56 +0800
Subject: [PATCH] Fixed build_debug_apk.bat

In new Android SDK, dx.bat and apkbuild.bat is removed, and this old build_debug_apk is not support JDK1.7 or JDK 1.8 Signing APK ,so this patch is fixed this problem.
---
 examples/androidlcl/android/build_debug_apk.bat | 13 ++++++++-----
 1 file changed, 8 insertions(+), 5 deletions(-)

diff --git a/examples/androidlcl/android/build_debug_apk.bat b/examples/androidlcl/android/build_debug_apk.bat
index 95df05f..08e55ba 100644
--- a/examples/androidlcl/android/build_debug_apk.bat
+++ b/examples/androidlcl/android/build_debug_apk.bat
@@ -30,24 +30,27 @@ call aapt p -v -f -M AndroidManifest.xml -F bin\%APP_NAME%.ap_ -I %APK_SDK_PLATF
 REM Java compiler
 call javac -verbose -encoding UTF8 -classpath %APK_SDK_PLATFORM%\android.jar -d bin\classes src\com\pascal\lcltest\LCLActivity.java
 
-REM DX to convert the java bytecode to dalvik bytecode
-call dx --dex --verbose --output=%APK_PROJECT_PATH%\bin\classes.dex %APK_PROJECT_PATH%\bin\classes
+REM Convert the java bytecode to dalvik bytecode
+call java -Djava.ext.dirs=%ANDROID_HOME%\platform-tools\lib\ -jar %ANDROID_HOME%\platform-tools\lib\dx.jar --dex --verbose --output=%APK_PROJECT_PATH%\bin\classes.dex %APK_PROJECT_PATH%\bin\classes
 
 REM It seams that dx calls echo off
 @echo on
 REM Now build the unsigned APK
 del %APK_PROJECT_PATH%\bin\%APP_NAME%-unsigned.apk
-call apkbuilder %APK_PROJECT_PATH%\bin\%APP_NAME%-unsigned.apk -v -u -z %APK_PROJECT_PATH%\bin\%APP_NAME%.ap_ -f %APK_PROJECT_PATH%\bin\classes.dex
+call java -classpath %ANDROID_HOME%\tools\lib\sdklib.jar com.android.sdklib.build.ApkBuilderMain %APK_PROJECT_PATH%\bin\%APP_NAME%-unsigned.apk -v -u -z %APK_PROJECT_PATH%\bin\%APP_NAME%.ap_ -f %APK_PROJECT_PATH%\bin\classes.dex
 
 REM Generating on the fly a debug key
 rem keytool -genkey -v -keystore bin\LCLDebugKey.keystore -alias LCLDebugKey -keyalg RSA -validity 10000 -dname NAME -storepass senhas -keypass senhas
 
 REM Signing the APK with a debug key
 del bin\%APP_NAME%-unaligned.apk
-jarsigner -verbose -keystore bin\LCLDebugKey.keystore -keypass senhas -storepass senhas -signedjar bin\%APP_NAME%-unaligned.apk bin\%APP_NAME%-unsigned.apk LCLDebugKey
+REM JDK1.6,Please use this command
+jarsigner -verbose -keystore bin\LCLDebugKey.keystore -keypass 123456 -storepass 123456 -signedjar bin\%APP_NAME%-unaligned.apk bin\%APP_NAME%-unsigned.apk LCLDebugKey
+REM JDK1.7 OR JDK1.8,Please use this command
+REM jarsigner -verbose -sigalg MD5withRSA -digestalg SHA1 -keystore bin\LCLDebugKey.keystore -keypass 123456 -storepass 123456 -signedjar bin\%APP_NAME%-unaligned.apk bin\%APP_NAME%-unsigned.apk LCLDebugKey
 
 REM Align the final APK package
 zipalign -v 4 bin\%APP_NAME%-unaligned.apk bin\%APP_NAME%.apk
 
 REM call and pause together allow us to see the results in the end
-pause
\ No newline at end of file
+pause
-- 
2.2.2

--
_______________________________________________
Lazarus mailing list
[email protected]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to