×
[PR]上記の広告は3ヶ月以上新規記事投稿のないブログに表示されています。新しい記事を書く事で広告が消えます。
・Eclipse+JAVAで開発したAndroidソースをAndroidStudio3.4へ移行した
注意点をメモしておく
(shift-jisで作成したソースからの変換)
・AndroidManifest
<uses-sdkをすべて削除
ソースコード内にshift-jisの全角スペースがある場合は、
APPのbuildでその行がエラーとして表示されるがAndroidManifestとは
表示されない
・エンコーディング すべてutf-8にする
File >> Settings >> Editer >> File encoding project すべてUTF8に
・bilde.Gradleを修正project google()を追加
・ADTはbiosでIntel/VTを有効にWindowsではHyper-Vを無効にする
注意点をメモしておく
(shift-jisで作成したソースからの変換)
・AndroidManifest
<uses-sdkをすべて削除
ソースコード内にshift-jisの全角スペースがある場合は、
APPのbuildでその行がエラーとして表示されるがAndroidManifestとは
表示されない
・エンコーディング すべてutf-8にする
File >> Settings >> Editer >> File encoding project すべてUTF8に
・bilde.Gradleを修正project google()を追加
buildscript {・bilde.Gdadle model compleをimplementationに
repositories {
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.4.0'
}
}
allprojects {
repositories {
google()
jcenter()
}
}
apply plugin: 'com.android.application'長時間gradleが終わらないときはいったんTry Againを事項
android {
compileSdkVersion 28
buildToolsVersion "28.0.3"
defaultConfig {
applicationId "com.XXXXXX.AppYYYYYActivity"
minSdkVersion 15
targetSdkVersion 28
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
}
}
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
}
・ここから面倒だが
EclipseのJAVAソースをNotoPad+でオープン
エンコードをすべてUTF-8にしておく android studioにコピーペースト 画面下がUFT8になっている事を
確認
・projectをコピペした時はClearProjectをわすれずに
・ディレクトリができない
セキュリティの強化でAndrodi6.0以上では、設定>>アプリ>>権限で
ストレージをONにしておく事
無論Manifestでの定義も忘れすずに
・WiFiが接続やステータスが正常に表示されない
manifestファイルに記載追加が必要
・ビルドの打ち切りと再実行
・ADTはbiosでIntel/VTを有効にWindowsではHyper-Vを無効にする
PR