obs1dium / BetterManual

An app for manual mode on Sony Alpha 5100 cameras
MIT License
38 stars 20 forks source link

Trouble building gradle on linux - error #20

Open gree303 opened 2 years ago

gree303 commented 2 years ago

I've tried all kind of configs. Maybe one of you guys/girls do know the solution to my issue.

root build.gradle `apply plugin: 'com.android.application'

android { compileSdkVersion 10 buildToolsVersion '30.0.2'

defaultConfig {
    applicationId "com.obsidium.bettermanual"
    minSdkVersion 10
    targetSdkVersion 10
    versionCode 7
    versionName "1.5"
    archivesBaseName = "BetterManual-${versionName}"
}
buildTypes {
    release {
        minifyEnabled true
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }
}

compileOptions {
    sourceCompatibility JavaVersion.VERSION_1_6
    targetCompatibility JavaVersion.VERSION_1_6
}

}

repositories { google() mavenCentral() maven { url "https://jitpack.io" } }

dependencies { compileOnly 'com.github.ma1co.OpenMemories-Framework:stubs:-SNAPSHOT' implementation 'com.github.ma1co.OpenMemories-Framework:framework:-SNAPSHOT' } `

app/build.gradle (none of the commented worked out) `buildscript { repositories { mavenCentral() //google() //gradlePluginPortal() } dependencies { //classpath 'com.android.tools.build:gradle:4.1.0' //classpath 'com.google.gms:google-services:4.3.3' classpath "com.android.tools.build:gradle:4.1.2"

    // NOTE: Do not place your application dependencies here; they belong
    // in the individual module build.gradle files
}

}

allprojects { repositories { //gradlePluginPortal() //jcenter() //google() mavenCentral() //mavenCentral { url 'https://maven.aliyun.com/repository/jcenter' } //maven { url "https://jitpack.io" } //maven { url 'http://repo1.maven.org/maven2' } jcenter { url "http://jcenter.bintray.com/" } } }`

gradle.wrapper #Thu Jun 24 20:15:04 EDT 2021 distributionBase=GRADLE_USER_HOME distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.4-all.zip distributionPath=wrapper/dists zipStorePath=wrapper/dists zipStoreBase=GRADLE_USER_HOME

Terminal gradle --info ....Compiling build file '/home/user/Downloads/openmeories/BetterManual-master/build.gradle' using SubsetScriptTransformer. Resource missing. [HTTP GET: https://repo1.maven.org/maven2/com/android/tools/build/gradle/4.1.2/gradle-4.1.2.pom] Resource missing. [HTTP HEAD: https://repo1.maven.org/maven2/com/android/tools/build/gradle/4.1.2/gradle-4.1.2.jar]

FAILURE: Build failed with an exception.

BUILD FAILED

Total time: 0.996 secs Received result Failure[value=org.gradle.initialization.ReportedException: org.gradle.internal.exceptions.LocationAwareException: A problem occurred configuring root project 'BetterManual-master'.] from daemon DaemonInfo{pid=10042, address=[2094e9c2-0fdd-4b3a-92c4-2ddc3532f5a2 port:41411, addresses:[/0:0:0:0:0:0:0:1, /127.0.0.1]], state=Idle, lastBusy=1646205025918, context=DefaultDaemonContext[uid=9c25e298-7d36-436d-a082-811908da0a24,javaHome=/usr/lib/jvm/java-8-openjdk-amd64,daemonRegistryDir=/root/.gradle/daemon,pid=10042,idleTimeout=10800000,daemonOpts=-XX:MaxPermSize=256m,-XX:+HeapDumpOnOutOfMemoryError,-Xmx1024m,-Dfile.encoding=UTF-8,-Duser.country=US,-Duser.language=en,-Duser.variant]} (build should be done).

Any help is very much welcome. Thanks all

gree303 commented 2 years ago

Update: I managed to setup Android SDK and the project. But now I ran into dependency issues. I've tried several sources. All result in the same error - missing repo/dependencies.

I just wanted to change two digits within the source code to see if the overall system doesn't block/limit the values. File: ManualActivity.java Line: ~ 1403 changing the following lines...

//            m_bracketPicCount = 3;
//            m_bracketStep = 3;

... to ....

          m_bracketPicCount = 9;
              m_bracketStep = 3;

In case anybody has this running could you send me the .apk? This way I can test this...

Thanks.

gree303 commented 2 years ago

@obs1dium do you suggest any update to build.gradle config file(s) ? Not sure if I miss some important step or if it's just outdated in terms of dependencies? Any help is very much very welcome - thanks.

obs1dium commented 2 years ago

Sorry, it's been a while since I tried building this code. I've got a similar project that builds fine with Android Studio 2021.1.1, gradle 4.1.2 and SDK 25.