[ 
https://issues.apache.org/jira/browse/MNG-8471?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17916506#comment-17916506
 ] 

Anders Hammar commented on MNG-8471:
------------------------------------

I get the same behavior just typing "mvn -v" with 4.0.0-rc-2 on macOS Sonoma 
14.7. I remember thinking WTF when I first tested out Maven 4...
What I did to get rid of the warning message and the two pop-ups was click 
"Allow Anyway" for this library in the "Privacy & Security" macOS settings. 
It's a one-off config but I guess it needs to be done for each maven 
installation/version.

This isn't specific to Maven but what's bad about forcing the user to do this 
is that for every time I need to do this I will probably check less the next 
time (for any library). I get tired and just want things to work. You can 
compare this to the unsigned stuff asked about when installing plugins in 
Eclipse. Does anyone even bother checking anymore? So when something bad is to 
be installed and macOS blocks it, many people will think less before allowing.

>  library load disallowed by system policy on Mac
> ------------------------------------------------
>
>                 Key: MNG-8471
>                 URL: https://issues.apache.org/jira/browse/MNG-8471
>             Project: Maven
>          Issue Type: Bug
>    Affects Versions: 4.0.0-rc-2
>            Reporter: Elliotte Rusty Harold
>            Priority: Minor
>         Attachments: Screenshot 2024-12-25 at 6.10.01 PM.png
>
>
> On a Mac with Sequoia 15.1.1 running the binary 4.0-RC2 release to "mvn clean 
> verify" the maven-compiler-plugin 
> {code}
> WARNING: Failed to load native library:libjlinenative.jnilib. osinfo: 
> Mac/arm64 (caused by: java.lang.UnsatisfiedLinkError: 
> /opt/java/apache-maven-4.0.0-rc-2/lib/jline-native/Mac/arm64/libjlinenative.jnilib:
>  
> dlopen(/opt/java/apache-maven-4.0.0-rc-2/lib/jline-native/Mac/arm64/libjlinenative.jnilib,
>  0x0001): tried: 
> '/opt/java/apache-maven-4.0.0-rc-2/lib/jline-native/Mac/arm64/libjlinenative.jnilib'
>  (code signature in <E83722FF-713D-3654-A603-EEBC715887FE> 
> '/opt/java/apache-maven-4.0.0-rc-2/lib/jline-native/Mac/arm64/libjlinenative.jnilib'
>  not valid for use in process: library load disallowed by system policy), 
> '/System/Volumes/Preboot/Cryptexes/OS/opt/java/apache-maven-4.0.0-rc-2/lib/jline-native/Mac/arm64/libjlinenative.jnilib'
>  (no such file), 
> '/opt/java/apache-maven-4.0.0-rc-2/lib/jline-native/Mac/arm64/libjlinenative.jnilib'
>  (code signature in <E83722FF-713D-3654-A603-EEBC715887FE> 
> '/opt/java/apache-maven-4.0.0-rc-2/lib/jline-native/Mac/arm64/libjlinenative.jnilib'
>  not valid for use in process: library load disallowed by system policy), 
> enable debug logging for stacktrace)
> {code}
> The build still seems to complete normally.
> openjdk version "17.0.12" 2024-07-16
> OpenJDK Runtime Environment Homebrew (build 17.0.12+0)
> OpenJDK 64-Bit Server VM Homebrew (build 17.0.12+0, mixed mode, sharing)
> Further, this isn't just a warning on the console. The mac actually pops up 
> two alert dialogs to warn about this problem that user must click away during 
> the build.
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to