kotlin icon indicating copy to clipboard operation
kotlin copied to clipboard

brew install danger/tap/danger-kotlin error on Apple M1

Open apps4everyone opened this issue 3 years ago • 10 comments

brew install danger/tap/danger-kotlin error on Apple M1:

==> Installing dependencies for danger/tap/danger-kotlin: danger/tap/danger-js, openjdk, kotlin, maven and gradle ==> Installing danger/tap/danger-kotlin dependency: danger/tap/danger-js 🍺 /opt/homebrew/Cellar/danger-js/11.0.2: 3 files, 115.3MB, built in 2 seconds ==> Installing danger/tap/danger-kotlin dependency: openjdk ==> Pouring openjdk--17.0.2.arm64_monterey.bottle.tar.gz 🍺 /opt/homebrew/Cellar/openjdk/17.0.2: 640 files, 306.4MB ==> Installing danger/tap/danger-kotlin dependency: kotlin ==> Pouring kotlin--1.6.10.all.bottle.tar.gz 🍺 /opt/homebrew/Cellar/kotlin/1.6.10: 112 files, 74MB ==> Installing danger/tap/danger-kotlin dependency: maven ==> Pouring maven--3.8.4.arm64_monterey.bottle.tar.gz 🍺 /opt/homebrew/Cellar/maven/3.8.4: 79 files, 10MB ==> Installing danger/tap/danger-kotlin dependency: gradle ==> Pouring gradle--7.4.all.bottle.tar.gz 🍺 /opt/homebrew/Cellar/gradle/7.4: 11,253 files, 267.7MB ==> Installing danger/tap/danger-kotlin ==> make install PREFIX=/opt/homebrew/Cellar/danger-kotlin/1.0.0 Last 15 lines from /Users/stefanfessler/Library/Logs/Homebrew/danger-kotlin/01.make: at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) at org.gradle.internal.concurrent.ThreadFactoryImpl$ManagedThreadRunnable.run(ThreadFactoryImpl.java:56) at java.base/java.lang.Thread.run(Thread.java:833)
1 error

  • Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

  • Get more help at https://help.gradle.org

BUILD FAILED in 5s make: *** [build] Error 1

apps4everyone avatar Feb 10 '22 20:02 apps4everyone

java --version openjdk 17.0.2 2022-01-18 OpenJDK Runtime Environment Temurin-17.0.2+8 (build 17.0.2+8) OpenJDK 64-Bit Server VM Temurin-17.0.2+8 (build 17.0.2+8, mixed mode)

apps4everyone avatar Feb 10 '22 20:02 apps4everyone

also with openjdk 11.0.12 2021-07-20 OpenJDK Runtime Environment Homebrew (build 11.0.12+0) OpenJDK 64-Bit Server VM Homebrew (build 11.0.12+0, mixed mode)

apps4everyone avatar Feb 10 '22 20:02 apps4everyone

@f-meloni is there any updates on this? i'm having the same issue since I switched to M1 from last year.

k0shk0sh avatar Feb 18 '22 11:02 k0shk0sh

Does this happen even if you install it via the script?

f-meloni avatar Feb 18 '22 18:02 f-meloni

only tried brew install danger/tap/danger-kotlin. Maybe you can guide me how to try with the script? thx

apps4everyone avatar Feb 18 '22 19:02 apps4everyone

git clone + ./scripts/install.sh look's like is working

Screenshot 2022-02-18 at 16 07 42

apps4everyone avatar Feb 18 '22 19:02 apps4everyone

Does this happen even if you install it via the script?

with the script it actually always fails because of permissions so had to hack it by creating the folders in usr manually.

k0shk0sh avatar Feb 20 '22 20:02 k0shk0sh

same issue. looks like the problem is the java version it's trying to use though.

General error during semantic analysis: Unsupported class file major version 63

01.make.txt

snowe2010 avatar Dec 03 '22 22:12 snowe2010

I have this same exact issue with homebrew. Apparently, it still tries today to download version 1.0.0 even if the version on Github is 1.2.0 also may I point out that the version of kotlin and gradle inside the installation script are pretty old? Anyway, even with the script i receive error like this `

Task :danger-kotlin:linkDebugExecutableRunner FAILED
e: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld invocation reported errors

The /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld command returned non-zero exit code: 1.
output:
-macosx_version_min has been renamed to -macos_version_min
ld: unknown options: -sdk_version 

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':danger-kotlin:linkDebugExecutableRunner'.
Compilation finished with errors

* Try:
Run with --stacktrace option to get the stack trace.
Run with --info or --debug option to get more log output.
Run with --scan to get full insights.

* Get more help at https://help.gradle.org

Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

See https://docs.gradle.org/7.4.2/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 12s
4 actionable tasks: 4 executed
make: *** [build] Error 1

` Some suggestions?

spectrumIG avatar Feb 23 '24 08:02 spectrumIG