Skip to content

Commit 1ca3d8f

Browse files
authored
fix: use separator properties when running JMH (#228)
* fix: use separator properties when running JMH This makes the build cross-platform and fixes execution on, e.g., Windows. * Quote the classpath argument * Use CLASSPATH environment variable
1 parent e38bdce commit 1ca3d8f

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

pom.xml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -671,8 +671,11 @@
671671
<goal>exec</goal>
672672
</goals>
673673
<configuration>
674-
<executable>${java.home}/bin/java</executable>
675-
<commandlineArgs>-cp target/classes:target/test-classes:${test.classpath} org.openjdk.jmh.Main ${jmh.args}</commandlineArgs>
674+
<environmentVariables>
675+
<CLASSPATH>target${file.separator}classes${path.separator}target${file.separator}test-classes${path.separator}${test.classpath}</CLASSPATH>
676+
</environmentVariables>
677+
<executable>${java.home}${file.separator}bin${file.separator}java</executable>
678+
<commandlineArgs>org.openjdk.jmh.Main ${jmh.args}</commandlineArgs>
676679
</configuration>
677680
</execution>
678681
</executions>

0 commit comments

Comments
 (0)