Uploaded image for project: 'Maven Surefire'
  1. Maven Surefire
  2. SUREFIRE-1648

Failsafe does not pass LD_LIBRARY_PATH to JVM on Mac with SIP enabled

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 2.22.1
    • None
    • None
    • None
    • OS: macOS Mojave with SIP enabled (default)
      JVM: OpenJDK 11.0.2

    Description

      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:

      <environmentVariables>
        <LD_LIBRARY_PATH>${myLdLibraryPath}</LD_LIBRARY_PATH>
      </environmentVariables>

      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

      Attachments

        Activity

          People

            Unassigned Unassigned
            dt Dmitry Timofeev
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: