apache / apache/maven-surefire

[SUREFIRE-1648] Failsafe does not pass LD_LIBRARY_PATH to JVM on Mac with SIP enabled

Open
#2,117 0 comments 0 reactions 0 assignees View on GitHub
bug priority:major
Dominant language
Java
Stars
461
Forks
588
Avg merge
1d 8h
Merged PRs (30d)
19

Description

**[Dmitry Timofeev](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=dt)** opened **[SUREFIRE-1648](https://issues.apache.org/jira/browse/SUREFIRE-1648?redirect=false)** and commented

Hi,

We encountered a problem with using maven-failsafe-plugin on Mac with SIP (System Integrity Protection) enabled. We’re using failsafe to run our integration tests that depend on a native library that also requires LD_LIBRARY_PATH to be set. Failsafe plugin does not pass LD_LIBRARY_PATH to the process which leads to tests failures. According to the documentation [1] we can use environmentVariables parameter like this:

```java

  ${myLdLibraryPath}

```

This configuration works perfectly with Exec Maven Plugin, but it doesn't in failsafe.

Is it desired behaviour? Do you have any ideas how to pass necessary LD_LIBRARY_PATH to the integration tests?

[1]: http://maven.apache.org/surefire/maven-failsafe-plugin/integration-test-mojo.html#environmentVariables

---

**Affects:** 2.22.1

Contributor guide

Open the contributing guide

Research direction

Start with the maven-failsafe-plugin integration-test documentation linked in the issue, especially the environmentVariables parameter, then trace how Failsafe launches integration-test JVMs. Done means the configured LD_LIBRARY_PATH reaches the test process on macOS with SIP enabled; add or update coverage if the repository provides a relevant test location.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
build-system, testing-qa
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.