OpenSearch/plugins
Lee Hinman 482843e27b Fix build to run correctly on FreeBSD
This adds the required changes/checks so that the build can run on
FreeBSD.

There are a few things that differ between FreeBSD and Linux:

- CPU probes return -1 for CPU usage
- `hot_threads` cannot be supported on FreeBSD

From OpenJDK's `os_bsd.cpp`:

```c++
bool os::is_thread_cpu_time_supported() {
  #ifdef __APPLE__
  return true;
  #else
  return false;
  #endif
}
```

So this API now returns (for each FreeBSD node):

```
curl -s localhost:9200/_nodes/hot_threads
::: {Devil Hunter Gabriel}{q8OJnKCcQS6EB9fygU4R4g}{127.0.0.1}{127.0.0.1:9300}
   hot_threads is not supported on FreeBSD
```

- multicast fails in native `join` method - known bug:
  https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=193246

Which causes:

```
1> Caused by: java.net.SocketException: Invalid argument
1>    at java.net.PlainDatagramSocketImpl.join(Native Method)
1>    at java.net.AbstractPlainDatagramSocketImpl.join(AbstractPlainDatagramSocketImpl.java:179)
1>    at java.net.MulticastSocket.joinGroup(MulticastSocket.java:323)
1>    at org.elasticsearch.plugin.discovery.multicast.MulticastChannel$Plain.buildMulticastSocket(MulticastChannel.java:309)
```

So these tests are skipped on FreeBSD.

Resolves #15562
2015-12-22 12:36:04 -07:00
..
analysis-icu Upgrade to lucene-5.5.0-snapshot-1721183. 2015-12-21 17:02:08 +01:00
analysis-kuromoji Upgrade to lucene-5.5.0-snapshot-1721183. 2015-12-21 17:02:08 +01:00
analysis-phonetic Upgrade to lucene-5.5.0-snapshot-1721183. 2015-12-21 17:02:08 +01:00
analysis-smartcn Upgrade to lucene-5.5.0-snapshot-1721183. 2015-12-21 17:02:08 +01:00
analysis-stempel Upgrade to lucene-5.5.0-snapshot-1721183. 2015-12-21 17:02:08 +01:00
delete-by-query Remove wildcard imports 2015-12-18 12:43:47 -08:00
discovery-azure Remove wildcard imports 2015-12-18 12:43:47 -08:00
discovery-ec2 Remove wildcard imports 2015-12-18 12:43:47 -08:00
discovery-gce Remove wildcard imports 2015-12-18 12:43:47 -08:00
discovery-multicast Fix build to run correctly on FreeBSD 2015-12-22 12:36:04 -07:00
jvm-example Build: Add fixture capabilities to integ tests 2015-12-19 15:46:21 -08:00
lang-javascript Remove wildcard imports 2015-12-18 12:43:47 -08:00
lang-plan-a Remove wildcard imports 2015-12-18 12:43:47 -08:00
lang-python Remove wildcard imports 2015-12-18 12:43:47 -08:00
mapper-attachments Make mappings tests more realistic. 2015-12-21 10:44:00 +01:00
mapper-murmur3 Make mappings tests more realistic. 2015-12-21 10:44:00 +01:00
mapper-size Make mappings tests more realistic. 2015-12-21 10:44:00 +01:00
repository-azure Remove wildcard imports 2015-12-18 12:43:47 -08:00
repository-hdfs Remove wildcard imports 2015-12-18 12:43:47 -08:00
repository-s3 Rename InternalFilters.Bucket to InternalFilters.InternalBucket to avoid name collision 2015-12-18 13:22:20 -08:00
site-example Remove "empty" licenses dir 2015-12-02 10:22:52 +01:00
store-smb Remove wildcard imports 2015-12-18 12:43:47 -08:00
build.gradle Build: Add fixture capabilities to integ tests 2015-12-19 15:46:21 -08:00