jmeter-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject [Bug 61667] New: Bad detection of Java home in bin/jmeter
Date Wed, 25 Oct 2017 21:36:31 GMT
https://bz.apache.org/bugzilla/show_bug.cgi?id=61667

            Bug ID: 61667
           Summary: Bad detection of Java home in bin/jmeter
           Product: JMeter
           Version: Nightly (Please specify date)
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Main
          Assignee: issues@jmeter.apache.org
          Reporter: ra0077@gmail.com
  Target Milestone: ---

Hi,

In the line if $darwin; then

darwin variable is not defined in my Linux (Mageia)

When I run JMeter I have this error

ra77@localhost bin]$ ./jmeter
Neither the JAVA_HOME nor the JRE_HOME environment variable is defined
At least one of these environment variable is needed to run this program

To fix it, we need to initialize the darwin variable with uname or $OSTYPE

Check 
http://f00bar.com/blog/2011/07/09/simple-robust-os-detection-in-bash-using-ostype/

https://stackoverflow.com/questions/394230/detect-the-os-from-a-bash-script

Proposed fix

if $darwin; then

become

if [ "$(uname)" == "Darwin" ]; then

Antonio

-- 
You are receiving this mail because:
You are the assignee for the bug.
Mime
View raw message