忍者ブログ
[431]  [430]  [429]  [428]  [427]  [426]  [425]  [424]  [423]  [422]  [421
×

[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()を追加
buildscript {
repositories {
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.4.0'
}
}
allprojects {
repositories {
google()
jcenter()
}
}
・bilde.Gdadle model compleをimplementationに
apply plugin: 'com.android.application'
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ファイルに記載追加が必要


・ビルドの打ち切りと再実行
 長時間gradleが終わらないときはいったんTry Againを事項

・ADTはbiosでIntel/VTを有効にWindowsではHyper-Vを無効にする



 

拍手

PR
カレンダー
03 2025/04 05
S M T W T F S
1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30
フリーエリア
最新CM
[03/10 DORA]
最新TB
プロフィール
HN:
dorabu
性別:
非公開
バーコード
ブログ内検索
P R
Copyright © ドラブーのアンドロイドとIoTなブログ All rights reserved. / Template by 四季. / Material by てんせん.

忍者ブログ [PR]