From b03023470efb2d99f410dcd55b2867245a131bfc Mon Sep 17 00:00:00 2001
From: David Li
Date: Wed, 8 Dec 2021 14:49:37 -0500
Subject: [PATCH 01/13] Add recipe for proto-opentelemetry-proto
---
recipes/proto-opentelemetry-proto/bld.bat | 11 ++++++
recipes/proto-opentelemetry-proto/build.sh | 12 ++++++
recipes/proto-opentelemetry-proto/meta.yaml | 44 +++++++++++++++++++++
3 files changed, 67 insertions(+)
create mode 100644 recipes/proto-opentelemetry-proto/bld.bat
create mode 100644 recipes/proto-opentelemetry-proto/build.sh
create mode 100644 recipes/proto-opentelemetry-proto/meta.yaml
diff --git a/recipes/proto-opentelemetry-proto/bld.bat b/recipes/proto-opentelemetry-proto/bld.bat
new file mode 100644
index 0000000000000..c47e9ef9ca1c4
--- /dev/null
+++ b/recipes/proto-opentelemetry-proto/bld.bat
@@ -0,0 +1,11 @@
+@echo on
+
+set DEST_DIR=%LIBRARY_PREFIX%\share\opentelemetry\opentelemetry-proto
+mkdir %DEST_DIR%
+if %ERRORLEVEL% NEQ 0 exit 1
+
+copy LICENSE %DEST_DIR%
+if %ERRORLEVEL% NEQ 0 exit 1
+
+robocopy /S /E opentelemetry\ %DEST_DIR%\
+if %ERRORLEVEL% NEQ 0 exit 1
diff --git a/recipes/proto-opentelemetry-proto/build.sh b/recipes/proto-opentelemetry-proto/build.sh
new file mode 100644
index 0000000000000..b64cb82f8bf95
--- /dev/null
+++ b/recipes/proto-opentelemetry-proto/build.sh
@@ -0,0 +1,12 @@
+#!/bin/bash
+
+set -ex
+
+main() {
+ local -r dest_dir="$PREFIX/share/opentelemetry/opentelemetry-proto"
+ mkdir -p "$dest_dir"
+ cp LICENSE "$dest_dir"
+ cp -r opentelemetry/ "$dest_dir"
+}
+
+main
diff --git a/recipes/proto-opentelemetry-proto/meta.yaml b/recipes/proto-opentelemetry-proto/meta.yaml
new file mode 100644
index 0000000000000..3e8854b23cf92
--- /dev/null
+++ b/recipes/proto-opentelemetry-proto/meta.yaml
@@ -0,0 +1,44 @@
+{% set name = "proto-opentelemetry-proto" %}
+{% set version = "0.11.0" %}
+
+package:
+ name: {{ name|lower }}
+ version: {{ version }}
+
+source:
+ url: https://github.com/open-telemetry/opentelemetry-proto/archive/refs/tags/v{{ version }}.tar.gz
+ sha256: 985367f8905e91018e636cbf0d83ab3f834b665c4f5899a27d10cae9657710e2
+
+build:
+ noarch: generic
+ number: 0
+
+requirements:
+ build:
+ host:
+ run:
+
+test:
+ commands:
+ - test -f $PREFIX/share/opentelemetry/opentelemetry-proto/LICENSE # [unix]
+ - test -f $PREFIX/share/opentelemetry/opentelemetry-proto/opentelemetry/proto/common/v1/common.proto # [unix]
+ - if not exist %PREFIX%\\share\\opentelemetry\\opentelemetry-proto\\LICENSE exit 1 # [win]
+ - if not exist %PREFIX%\\share\\opentelemetry\\opentelemetry-proto\\opentelemetry\\proto\\common\\v1\\common.proto exit 1 # [win]
+
+about:
+ home: https://github.com/open-telemetry/opentelemetry-proto
+ license: Apache-2.0
+ license_family: Apache
+ license_file: LICENSE
+ summary: 'Protobuf definitions for the OpenTelemetry protocol (OTLP)'
+ description: |
+ OpenTelemetry is a collection of tools, APIs, and SDKs. Use it to
+ instrument, generate, collect, and export telemetry data (metrics,
+ logs, and traces) to help you analyze your software’s performance
+ and behavior.
+ doc_url: https://github.com/open-telemetry/opentelemetry-proto
+ dev_url: https://opentelemetry.io/docs/reference/specification/
+
+extra:
+ recipe-maintainers:
+ - lidavidm
From 8633066b5a610e11080fd05b036e870f00eb35dc Mon Sep 17 00:00:00 2001
From: David Li
Date: Wed, 8 Dec 2021 15:11:31 -0500
Subject: [PATCH 02/13] Add recipe for cpp-opentelemetry-api
---
recipes/cpp-opentelemetry-api/bld.bat | 19 +++++++++++
recipes/cpp-opentelemetry-api/build.sh | 21 +++++++++++++
recipes/cpp-opentelemetry-api/meta.yaml | 42 +++++++++++++++++++++++++
3 files changed, 82 insertions(+)
create mode 100644 recipes/cpp-opentelemetry-api/bld.bat
create mode 100644 recipes/cpp-opentelemetry-api/build.sh
create mode 100644 recipes/cpp-opentelemetry-api/meta.yaml
diff --git a/recipes/cpp-opentelemetry-api/bld.bat b/recipes/cpp-opentelemetry-api/bld.bat
new file mode 100644
index 0000000000000..3a75510aed8a4
--- /dev/null
+++ b/recipes/cpp-opentelemetry-api/bld.bat
@@ -0,0 +1,19 @@
+@echo on
+
+mkdir build-cpp
+if errorlevel 1 exit 1
+
+cd build-cpp
+cmake .. ^
+ -GNinja %
+ -DCMAKE_BUILD_TYPE=Release %
+ -DCMAKE_CXX_FLAGS="$CXXFLAGS" %
+ -DCMAKE_PREFIX_PATH=%CONDA_PREFIX% %
+ -DCMAKE_INSTALL_PREFIX=%LIBRARY_PREFIX% %
+ -DBUILD_TESTING=OFF %
+ -DWITH_API_ONLY=ON %
+ -DWITH_ETW=OFF %
+ -DWITH_EXAMPLES=OFF
+
+cmake --build . --config Release --target install
+if errorlevel 1 exit 1
diff --git a/recipes/cpp-opentelemetry-api/build.sh b/recipes/cpp-opentelemetry-api/build.sh
new file mode 100644
index 0000000000000..66f1fdde90f88
--- /dev/null
+++ b/recipes/cpp-opentelemetry-api/build.sh
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+set -ex
+
+export CMAKE_ARGS="${CMAKE_ARGS} -DCMAKE_CXX_STANDARD=11"
+
+mkdir -p build-cpp
+pushd build-cpp
+
+cmake ${CMAKE_ARGS} .. \
+ -GNinja \
+ -DCMAKE_BUILD_TYPE=Release \
+ -DCMAKE_CXX_FLAGS="$CXXFLAGS" \
+ -DCMAKE_PREFIX_PATH=$PREFIX \
+ -DCMAKE_INSTALL_PREFIX=$PREFIX \
+ -DBUILD_TESTING=OFF \
+ -DWITH_API_ONLY=ON \
+ -DWITH_EXAMPLES=OFF
+
+ninja install
+popd
diff --git a/recipes/cpp-opentelemetry-api/meta.yaml b/recipes/cpp-opentelemetry-api/meta.yaml
new file mode 100644
index 0000000000000..bdf83ef3d8f10
--- /dev/null
+++ b/recipes/cpp-opentelemetry-api/meta.yaml
@@ -0,0 +1,42 @@
+{% set name = "cpp-opentelemetry-api" %}
+{% set version = "1.1.0" %}
+
+package:
+ name: {{ name|lower }}
+ version: {{ version }}
+
+source:
+ url: https://github.com/open-telemetry/opentelemetry-cpp/archive/refs/tags/v{{ version }}.tar.gz
+ sha256: f8fd3adddd47be382dc79c19d7e7efcf86a0dfbb5a237db6e0618dbb7eb8e058
+
+build:
+ number: 0
+
+requirements:
+ build:
+ - {{ compiler('cxx') }}
+ - cmake >=3.1
+ - ninja
+
+test:
+ commands:
+ - test -d $PREFIX/include/opentelemetry/ # [unix]
+ - if not exist %PREFIX%\\include\\opentelemetry exit 1 # [win]
+
+about:
+ home:
+ license: Apache-2.0
+ license_family: Apache
+ license_file: LICENSE
+ summary: 'The OpenTelemetry C++ Client'
+ description: |
+ OpenTelemetry is a collection of tools, APIs, and SDKs. Use it to
+ instrument, generate, collect, and export telemetry data (metrics,
+ logs, and traces) to help you analyze your software’s performance
+ and behavior.
+ doc_url: https://opentelemetry.io/docs/instrumentation/cpp/
+ dev_url: https://github.com/open-telemetry/opentelemetry-cpp
+
+extra:
+ recipe-maintainers:
+ - lidavidm
From 9e55cb4549ec12d9c2b271da0c33bf658738d44a Mon Sep 17 00:00:00 2001
From: David Li
Date: Wed, 8 Dec 2021 16:26:43 -0500
Subject: [PATCH 03/13] Add recipe for cpp-opentelemetry-sdk
---
recipes/cpp-opentelemetry-sdk/bld.bat | 21 +++++++++
recipes/cpp-opentelemetry-sdk/build.sh | 26 +++++++++++
recipes/cpp-opentelemetry-sdk/meta.yaml | 57 +++++++++++++++++++++++++
3 files changed, 104 insertions(+)
create mode 100644 recipes/cpp-opentelemetry-sdk/bld.bat
create mode 100644 recipes/cpp-opentelemetry-sdk/build.sh
create mode 100644 recipes/cpp-opentelemetry-sdk/meta.yaml
diff --git a/recipes/cpp-opentelemetry-sdk/bld.bat b/recipes/cpp-opentelemetry-sdk/bld.bat
new file mode 100644
index 0000000000000..8bdcfee11ff28
--- /dev/null
+++ b/recipes/cpp-opentelemetry-sdk/bld.bat
@@ -0,0 +1,21 @@
+@echo on
+
+mkdir build-cpp
+if errorlevel 1 exit 1
+
+cd build-cpp
+cmake .. ^
+ -GNinja %
+ -DCMAKE_BUILD_TYPE=Release %
+ -DCMAKE_CXX_FLAGS="$CXXFLAGS" %
+ -DCMAKE_PREFIX_PATH=%CONDA_PREFIX% %
+ -DCMAKE_INSTALL_PREFIX=%LIBRARY_PREFIX% %
+ -DBUILD_TESTING=OFF %
+ -DWITH_API_ONLY=OFF %
+ -DWITH_ETW=OFF %
+ -DWITH_EXAMPLES=OFF %
+ -DWITH_OTLP=ON %
+ -DWITH_OTLP_GRPC=ON
+
+cmake --build . --config Release --target install
+if errorlevel 1 exit 1
diff --git a/recipes/cpp-opentelemetry-sdk/build.sh b/recipes/cpp-opentelemetry-sdk/build.sh
new file mode 100644
index 0000000000000..e5ebb83050115
--- /dev/null
+++ b/recipes/cpp-opentelemetry-sdk/build.sh
@@ -0,0 +1,26 @@
+#!/bin/bash
+
+set -ex
+
+export CMAKE_ARGS="${CMAKE_ARGS} -DCMAKE_CXX_STANDARD=11"
+
+# Release tarballs do not contain the required Protobuf definitions.
+cp -r $PREFIX/share/opentelemetry/opentelemetry-proto/opentelemetry ./third_party/opentelemetry-proto/
+
+mkdir -p build-cpp
+pushd build-cpp
+
+cmake ${CMAKE_ARGS} .. \
+ -GNinja \
+ -DCMAKE_BUILD_TYPE=Release \
+ -DCMAKE_CXX_FLAGS="$CXXFLAGS" \
+ -DCMAKE_PREFIX_PATH=$PREFIX \
+ -DCMAKE_INSTALL_PREFIX=$PREFIX \
+ -DBUILD_TESTING=OFF \
+ -DWITH_API_ONLY=OFF \
+ -DWITH_EXAMPLES=OFF \
+ -DWITH_OTLP=ON \
+ -DWITH_OTLP_GRPC=ON
+
+ninja install
+popd
diff --git a/recipes/cpp-opentelemetry-sdk/meta.yaml b/recipes/cpp-opentelemetry-sdk/meta.yaml
new file mode 100644
index 0000000000000..14e8b356398fb
--- /dev/null
+++ b/recipes/cpp-opentelemetry-sdk/meta.yaml
@@ -0,0 +1,57 @@
+{% set name = "cpp-opentelemetry-sdk" %}
+{% set version = "1.1.0" %}
+
+package:
+ name: {{ name|lower }}
+ version: {{ version }}
+
+source:
+ url: https://github.com/open-telemetry/opentelemetry-cpp/archive/refs/tags/v{{ version }}.tar.gz
+ sha256: f8fd3adddd47be382dc79c19d7e7efcf86a0dfbb5a237db6e0618dbb7eb8e058
+
+build:
+ number: 0
+
+requirements:
+ build:
+ - {{ compiler('cxx') }}
+ - cmake >=3.1
+ - ninja
+ host:
+ - grpc-cpp
+ - nlohmann_json
+ - proto-opentelemetry-proto
+ - libprotobuf >=3.18
+ - zlib
+ run:
+ - grpc-cpp
+ - libprotobuf >=3.18
+
+test:
+ commands:
+ - test -d $PREFIX/include/opentelemetry/sdk/ # [unix]
+ - test -d $PREFIX/lib/cmake/opentelemetry-cpp/ # [unix]
+ - test -f $PREFIX/lib/libopentelemetry_common.a # [unix]
+ - test -f $PREFIX/lib/libopentelemetry_exporter_otlp_grpc.a # [unix]
+ - if not exist %PREFIX%\\include\\opentelemetry\\sdk exit 1 # [win]
+ - if not exist %PREFIX%\\lib\\opentelemetry\\cmake\\opentelemetry-cpp exit 1 # [win]
+ - if not exist %PREFIX%\\lib\\opentelemetry\\libopentelemetry_common.lib exit 1 # [win]
+ - if not exist %PREFIX%\\lib\\opentelemetry\\libopentelemetry_exporter_otlp_grpc.lib exit 1 # [win]
+
+about:
+ home:
+ license: Apache-2.0
+ license_family: Apache
+ license_file: LICENSE
+ summary: 'The OpenTelemetry C++ Client'
+ description: |
+ OpenTelemetry is a collection of tools, APIs, and SDKs. Use it to
+ instrument, generate, collect, and export telemetry data (metrics,
+ logs, and traces) to help you analyze your software’s performance
+ and behavior.
+ doc_url: https://opentelemetry.io/docs/instrumentation/cpp/
+ dev_url: https://github.com/open-telemetry/opentelemetry-cpp
+
+extra:
+ recipe-maintainers:
+ - lidavidm
From 088055b6ede7796c61ffc192f001b4cf8604dd95 Mon Sep 17 00:00:00 2001
From: David Li
Date: Wed, 8 Dec 2021 16:31:14 -0500
Subject: [PATCH 04/13] Fix license_family
---
recipes/cpp-opentelemetry-api/meta.yaml | 2 +-
recipes/cpp-opentelemetry-sdk/meta.yaml | 2 +-
recipes/proto-opentelemetry-proto/meta.yaml | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/recipes/cpp-opentelemetry-api/meta.yaml b/recipes/cpp-opentelemetry-api/meta.yaml
index bdf83ef3d8f10..272d17cef4287 100644
--- a/recipes/cpp-opentelemetry-api/meta.yaml
+++ b/recipes/cpp-opentelemetry-api/meta.yaml
@@ -26,7 +26,7 @@ test:
about:
home:
license: Apache-2.0
- license_family: Apache
+ license_family: APACHE
license_file: LICENSE
summary: 'The OpenTelemetry C++ Client'
description: |
diff --git a/recipes/cpp-opentelemetry-sdk/meta.yaml b/recipes/cpp-opentelemetry-sdk/meta.yaml
index 14e8b356398fb..7b202603fc041 100644
--- a/recipes/cpp-opentelemetry-sdk/meta.yaml
+++ b/recipes/cpp-opentelemetry-sdk/meta.yaml
@@ -41,7 +41,7 @@ test:
about:
home:
license: Apache-2.0
- license_family: Apache
+ license_family: APACHE
license_file: LICENSE
summary: 'The OpenTelemetry C++ Client'
description: |
diff --git a/recipes/proto-opentelemetry-proto/meta.yaml b/recipes/proto-opentelemetry-proto/meta.yaml
index 3e8854b23cf92..f567e9abcb04c 100644
--- a/recipes/proto-opentelemetry-proto/meta.yaml
+++ b/recipes/proto-opentelemetry-proto/meta.yaml
@@ -28,7 +28,7 @@ test:
about:
home: https://github.com/open-telemetry/opentelemetry-proto
license: Apache-2.0
- license_family: Apache
+ license_family: APACHE
license_file: LICENSE
summary: 'Protobuf definitions for the OpenTelemetry protocol (OTLP)'
description: |
From de1f7eeab17f0a1191c32d7ce7a9f63c262e5d30 Mon Sep 17 00:00:00 2001
From: David Li
Date: Wed, 8 Dec 2021 16:56:12 -0500
Subject: [PATCH 05/13] Fix dependency
---
recipes/cpp-opentelemetry-sdk/meta.yaml | 1 +
1 file changed, 1 insertion(+)
diff --git a/recipes/cpp-opentelemetry-sdk/meta.yaml b/recipes/cpp-opentelemetry-sdk/meta.yaml
index 7b202603fc041..feecea5e590d9 100644
--- a/recipes/cpp-opentelemetry-sdk/meta.yaml
+++ b/recipes/cpp-opentelemetry-sdk/meta.yaml
@@ -18,6 +18,7 @@ requirements:
- cmake >=3.1
- ninja
host:
+ - cpp-opentelemetry-api
- grpc-cpp
- nlohmann_json
- proto-opentelemetry-proto
From 0756666f652b0213500a7edef2756f0a6db5db65 Mon Sep 17 00:00:00 2001
From: David Li
Date: Wed, 8 Dec 2021 16:57:41 -0500
Subject: [PATCH 06/13] Fix bld.bat
---
recipes/cpp-opentelemetry-sdk/bld.bat | 1 -
1 file changed, 1 deletion(-)
diff --git a/recipes/cpp-opentelemetry-sdk/bld.bat b/recipes/cpp-opentelemetry-sdk/bld.bat
index 8bdcfee11ff28..2865f2402f54e 100644
--- a/recipes/cpp-opentelemetry-sdk/bld.bat
+++ b/recipes/cpp-opentelemetry-sdk/bld.bat
@@ -7,7 +7,6 @@ cd build-cpp
cmake .. ^
-GNinja %
-DCMAKE_BUILD_TYPE=Release %
- -DCMAKE_CXX_FLAGS="$CXXFLAGS" %
-DCMAKE_PREFIX_PATH=%CONDA_PREFIX% %
-DCMAKE_INSTALL_PREFIX=%LIBRARY_PREFIX% %
-DBUILD_TESTING=OFF %
From 365aefcab61a989106fde343a17c9d04911d1a5b Mon Sep 17 00:00:00 2001
From: David Li
Date: Wed, 8 Dec 2021 16:59:27 -0500
Subject: [PATCH 07/13] Fix bld.bat
---
recipes/cpp-opentelemetry-sdk/bld.bat | 3 +++
1 file changed, 3 insertions(+)
diff --git a/recipes/cpp-opentelemetry-sdk/bld.bat b/recipes/cpp-opentelemetry-sdk/bld.bat
index 2865f2402f54e..1c3c75d3f40b4 100644
--- a/recipes/cpp-opentelemetry-sdk/bld.bat
+++ b/recipes/cpp-opentelemetry-sdk/bld.bat
@@ -3,6 +3,9 @@
mkdir build-cpp
if errorlevel 1 exit 1
+# Release tarballs do not contain the required Protobuf definitions.
+robocopy /S /E %CONDA_PREFIX%\share\opentelemetry\opentelemetry-proto\opentelemetry .\third_party\opentelemetry-proto\
+
cd build-cpp
cmake .. ^
-GNinja %
From 797f67c2b69c5eeb0a506c05399bb9c0c505e0cc Mon Sep 17 00:00:00 2001
From: David Li
Date: Thu, 9 Dec 2021 09:42:40 -0500
Subject: [PATCH 08/13] Fix typos in Windows build scripts
---
recipes/cpp-opentelemetry-api/bld.bat | 15 +++++++--------
recipes/cpp-opentelemetry-sdk/bld.bat | 18 +++++++++---------
2 files changed, 16 insertions(+), 17 deletions(-)
diff --git a/recipes/cpp-opentelemetry-api/bld.bat b/recipes/cpp-opentelemetry-api/bld.bat
index 3a75510aed8a4..9f3b4dbcf35c2 100644
--- a/recipes/cpp-opentelemetry-api/bld.bat
+++ b/recipes/cpp-opentelemetry-api/bld.bat
@@ -5,14 +5,13 @@ if errorlevel 1 exit 1
cd build-cpp
cmake .. ^
- -GNinja %
- -DCMAKE_BUILD_TYPE=Release %
- -DCMAKE_CXX_FLAGS="$CXXFLAGS" %
- -DCMAKE_PREFIX_PATH=%CONDA_PREFIX% %
- -DCMAKE_INSTALL_PREFIX=%LIBRARY_PREFIX% %
- -DBUILD_TESTING=OFF %
- -DWITH_API_ONLY=ON %
- -DWITH_ETW=OFF %
+ -GNinja ^
+ -DCMAKE_BUILD_TYPE=Release ^
+ -DCMAKE_PREFIX_PATH=%CONDA_PREFIX% ^
+ -DCMAKE_INSTALL_PREFIX=%LIBRARY_PREFIX% ^
+ -DBUILD_TESTING=OFF ^
+ -DWITH_API_ONLY=ON ^
+ -DWITH_ETW=OFF ^
-DWITH_EXAMPLES=OFF
cmake --build . --config Release --target install
diff --git a/recipes/cpp-opentelemetry-sdk/bld.bat b/recipes/cpp-opentelemetry-sdk/bld.bat
index 1c3c75d3f40b4..8314a5524e1e7 100644
--- a/recipes/cpp-opentelemetry-sdk/bld.bat
+++ b/recipes/cpp-opentelemetry-sdk/bld.bat
@@ -8,15 +8,15 @@ robocopy /S /E %CONDA_PREFIX%\share\opentelemetry\opentelemetry-proto\openteleme
cd build-cpp
cmake .. ^
- -GNinja %
- -DCMAKE_BUILD_TYPE=Release %
- -DCMAKE_PREFIX_PATH=%CONDA_PREFIX% %
- -DCMAKE_INSTALL_PREFIX=%LIBRARY_PREFIX% %
- -DBUILD_TESTING=OFF %
- -DWITH_API_ONLY=OFF %
- -DWITH_ETW=OFF %
- -DWITH_EXAMPLES=OFF %
- -DWITH_OTLP=ON %
+ -GNinja ^
+ -DCMAKE_BUILD_TYPE=Release ^
+ -DCMAKE_PREFIX_PATH=%CONDA_PREFIX% ^
+ -DCMAKE_INSTALL_PREFIX=%LIBRARY_PREFIX% ^
+ -DBUILD_TESTING=OFF ^
+ -DWITH_API_ONLY=OFF ^
+ -DWITH_ETW=OFF ^
+ -DWITH_EXAMPLES=OFF ^
+ -DWITH_OTLP=ON ^
-DWITH_OTLP_GRPC=ON
cmake --build . --config Release --target install
From 74956210ea325896f677752d9a82035a9276495c Mon Sep 17 00:00:00 2001
From: David Li
Date: Thu, 9 Dec 2021 09:59:51 -0500
Subject: [PATCH 09/13] Fix proto-opentelemetry-proto build.sh
---
recipes/proto-opentelemetry-proto/build.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/recipes/proto-opentelemetry-proto/build.sh b/recipes/proto-opentelemetry-proto/build.sh
index b64cb82f8bf95..6c7ca9e64f9c6 100644
--- a/recipes/proto-opentelemetry-proto/build.sh
+++ b/recipes/proto-opentelemetry-proto/build.sh
@@ -6,7 +6,7 @@ main() {
local -r dest_dir="$PREFIX/share/opentelemetry/opentelemetry-proto"
mkdir -p "$dest_dir"
cp LICENSE "$dest_dir"
- cp -r opentelemetry/ "$dest_dir"
+ cp -r opentelemetry "$dest_dir/opentelemetry"
}
main
From 71ba40367f9383b1b23f339ad3472c76985a7028 Mon Sep 17 00:00:00 2001
From: David Li
Date: Thu, 9 Dec 2021 10:01:34 -0500
Subject: [PATCH 10/13] Fix lint errors
---
recipes/cpp-opentelemetry-api/meta.yaml | 2 +-
recipes/cpp-opentelemetry-sdk/meta.yaml | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/recipes/cpp-opentelemetry-api/meta.yaml b/recipes/cpp-opentelemetry-api/meta.yaml
index 272d17cef4287..98a871d116681 100644
--- a/recipes/cpp-opentelemetry-api/meta.yaml
+++ b/recipes/cpp-opentelemetry-api/meta.yaml
@@ -24,7 +24,7 @@ test:
- if not exist %PREFIX%\\include\\opentelemetry exit 1 # [win]
about:
- home:
+ home: https://github.com/open-telemetry/opentelemetry-cpp
license: Apache-2.0
license_family: APACHE
license_file: LICENSE
diff --git a/recipes/cpp-opentelemetry-sdk/meta.yaml b/recipes/cpp-opentelemetry-sdk/meta.yaml
index feecea5e590d9..ddc6fb0e76600 100644
--- a/recipes/cpp-opentelemetry-sdk/meta.yaml
+++ b/recipes/cpp-opentelemetry-sdk/meta.yaml
@@ -40,7 +40,7 @@ test:
- if not exist %PREFIX%\\lib\\opentelemetry\\libopentelemetry_exporter_otlp_grpc.lib exit 1 # [win]
about:
- home:
+ home: https://github.com/open-telemetry/opentelemetry-cpp
license: Apache-2.0
license_family: APACHE
license_file: LICENSE
From bb3a518129de19e353893577dd42b3cf88afbf3d Mon Sep 17 00:00:00 2001
From: David Li
Date: Thu, 9 Dec 2021 14:41:30 -0500
Subject: [PATCH 11/13] Try to fix Windows tests again
---
recipes/cpp-opentelemetry-api/meta.yaml | 2 +-
recipes/cpp-opentelemetry-sdk/meta.yaml | 8 ++++----
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/recipes/cpp-opentelemetry-api/meta.yaml b/recipes/cpp-opentelemetry-api/meta.yaml
index 98a871d116681..ec476f93364ae 100644
--- a/recipes/cpp-opentelemetry-api/meta.yaml
+++ b/recipes/cpp-opentelemetry-api/meta.yaml
@@ -21,7 +21,7 @@ requirements:
test:
commands:
- test -d $PREFIX/include/opentelemetry/ # [unix]
- - if not exist %PREFIX%\\include\\opentelemetry exit 1 # [win]
+ - if not exist %LIBRARY_INC%\\opentelemetry exit 1 # [win]
about:
home: https://github.com/open-telemetry/opentelemetry-cpp
diff --git a/recipes/cpp-opentelemetry-sdk/meta.yaml b/recipes/cpp-opentelemetry-sdk/meta.yaml
index ddc6fb0e76600..c3dc3eb526eeb 100644
--- a/recipes/cpp-opentelemetry-sdk/meta.yaml
+++ b/recipes/cpp-opentelemetry-sdk/meta.yaml
@@ -34,10 +34,10 @@ test:
- test -d $PREFIX/lib/cmake/opentelemetry-cpp/ # [unix]
- test -f $PREFIX/lib/libopentelemetry_common.a # [unix]
- test -f $PREFIX/lib/libopentelemetry_exporter_otlp_grpc.a # [unix]
- - if not exist %PREFIX%\\include\\opentelemetry\\sdk exit 1 # [win]
- - if not exist %PREFIX%\\lib\\opentelemetry\\cmake\\opentelemetry-cpp exit 1 # [win]
- - if not exist %PREFIX%\\lib\\opentelemetry\\libopentelemetry_common.lib exit 1 # [win]
- - if not exist %PREFIX%\\lib\\opentelemetry\\libopentelemetry_exporter_otlp_grpc.lib exit 1 # [win]
+ - if not exist %LIBRARY_INC%\\opentelemetry\\sdk exit 1 # [win]
+ - if not exist %LIBRARY_LIB%\\opentelemetry\\cmake\\opentelemetry-cpp exit 1 # [win]
+ - if not exist %LIBRARY_LIB%\\opentelemetry\\libopentelemetry_common.lib exit 1 # [win]
+ - if not exist %LIBRARY_LIB%\\opentelemetry\\libopentelemetry_exporter_otlp_grpc.lib exit 1 # [win]
about:
home: https://github.com/open-telemetry/opentelemetry-cpp
From 3a43efbeac1eb7ba65ac71fa11bf9835c2b7f42a Mon Sep 17 00:00:00 2001
From: David Li
Date: Fri, 10 Dec 2021 09:31:03 -0500
Subject: [PATCH 12/13] Fix Windows paths
---
recipes/cpp-opentelemetry-sdk/bld.bat | 2 +-
recipes/proto-opentelemetry-proto/bld.bat | 3 ++-
recipes/proto-opentelemetry-proto/meta.yaml | 4 ++--
3 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/recipes/cpp-opentelemetry-sdk/bld.bat b/recipes/cpp-opentelemetry-sdk/bld.bat
index 8314a5524e1e7..7ce12c8317cc1 100644
--- a/recipes/cpp-opentelemetry-sdk/bld.bat
+++ b/recipes/cpp-opentelemetry-sdk/bld.bat
@@ -4,7 +4,7 @@ mkdir build-cpp
if errorlevel 1 exit 1
# Release tarballs do not contain the required Protobuf definitions.
-robocopy /S /E %CONDA_PREFIX%\share\opentelemetry\opentelemetry-proto\opentelemetry .\third_party\opentelemetry-proto\
+robocopy /S /E %LIBRARY_PREFIX%\share\opentelemetry\opentelemetry-proto\opentelemetry .\third_party\opentelemetry-proto\opentelemetry
cd build-cpp
cmake .. ^
diff --git a/recipes/proto-opentelemetry-proto/bld.bat b/recipes/proto-opentelemetry-proto/bld.bat
index c47e9ef9ca1c4..c4c1c5f25b8c0 100644
--- a/recipes/proto-opentelemetry-proto/bld.bat
+++ b/recipes/proto-opentelemetry-proto/bld.bat
@@ -7,5 +7,6 @@ if %ERRORLEVEL% NEQ 0 exit 1
copy LICENSE %DEST_DIR%
if %ERRORLEVEL% NEQ 0 exit 1
+REM robocopy returns non-zero exit codes on success
robocopy /S /E opentelemetry\ %DEST_DIR%\
-if %ERRORLEVEL% NEQ 0 exit 1
+if %ERRORLEVEL% GEQ 8 exit 1
diff --git a/recipes/proto-opentelemetry-proto/meta.yaml b/recipes/proto-opentelemetry-proto/meta.yaml
index f567e9abcb04c..4b75a0d1869cf 100644
--- a/recipes/proto-opentelemetry-proto/meta.yaml
+++ b/recipes/proto-opentelemetry-proto/meta.yaml
@@ -22,8 +22,8 @@ test:
commands:
- test -f $PREFIX/share/opentelemetry/opentelemetry-proto/LICENSE # [unix]
- test -f $PREFIX/share/opentelemetry/opentelemetry-proto/opentelemetry/proto/common/v1/common.proto # [unix]
- - if not exist %PREFIX%\\share\\opentelemetry\\opentelemetry-proto\\LICENSE exit 1 # [win]
- - if not exist %PREFIX%\\share\\opentelemetry\\opentelemetry-proto\\opentelemetry\\proto\\common\\v1\\common.proto exit 1 # [win]
+ - if not exist %PREFIX%\\Library\\share\\opentelemetry\\opentelemetry-proto\\LICENSE exit 1 # [win]
+ - if not exist %PREFIX%\\Library\\share\\opentelemetry\\opentelemetry-proto\\opentelemetry\\proto\\common\\v1\\common.proto exit 1 # [win]
about:
home: https://github.com/open-telemetry/opentelemetry-proto
From 777e443b58fe0e41aa92aef89b9fac7128c9f858 Mon Sep 17 00:00:00 2001
From: David Li
Date: Fri, 10 Dec 2021 09:59:57 -0500
Subject: [PATCH 13/13] Fix more Windows paths
---
recipes/cpp-opentelemetry-api/meta.yaml | 2 +-
recipes/cpp-opentelemetry-sdk/bld.bat | 4 +++-
recipes/cpp-opentelemetry-sdk/build.sh | 2 ++
recipes/cpp-opentelemetry-sdk/meta.yaml | 8 ++++----
recipes/proto-opentelemetry-proto/bld.bat | 2 +-
recipes/proto-opentelemetry-proto/meta.yaml | 4 ++--
6 files changed, 13 insertions(+), 9 deletions(-)
diff --git a/recipes/cpp-opentelemetry-api/meta.yaml b/recipes/cpp-opentelemetry-api/meta.yaml
index ec476f93364ae..530852621bbc6 100644
--- a/recipes/cpp-opentelemetry-api/meta.yaml
+++ b/recipes/cpp-opentelemetry-api/meta.yaml
@@ -21,7 +21,7 @@ requirements:
test:
commands:
- test -d $PREFIX/include/opentelemetry/ # [unix]
- - if not exist %LIBRARY_INC%\\opentelemetry exit 1 # [win]
+ - if not exist %LIBRARY_INC%\opentelemetry exit 1 # [win]
about:
home: https://github.com/open-telemetry/opentelemetry-cpp
diff --git a/recipes/cpp-opentelemetry-sdk/bld.bat b/recipes/cpp-opentelemetry-sdk/bld.bat
index 7ce12c8317cc1..2d8c53d5fd31b 100644
--- a/recipes/cpp-opentelemetry-sdk/bld.bat
+++ b/recipes/cpp-opentelemetry-sdk/bld.bat
@@ -3,8 +3,10 @@
mkdir build-cpp
if errorlevel 1 exit 1
-# Release tarballs do not contain the required Protobuf definitions.
+REM Release tarballs do not contain the required Protobuf definitions.
robocopy /S /E %LIBRARY_PREFIX%\share\opentelemetry\opentelemetry-proto\opentelemetry .\third_party\opentelemetry-proto\opentelemetry
+REM Stop CMake from trying to git clone the Protobuf definitions.
+mkdir .\third_party\opentelemetry-proto\.git
cd build-cpp
cmake .. ^
diff --git a/recipes/cpp-opentelemetry-sdk/build.sh b/recipes/cpp-opentelemetry-sdk/build.sh
index e5ebb83050115..53f422c7be894 100644
--- a/recipes/cpp-opentelemetry-sdk/build.sh
+++ b/recipes/cpp-opentelemetry-sdk/build.sh
@@ -6,6 +6,8 @@ export CMAKE_ARGS="${CMAKE_ARGS} -DCMAKE_CXX_STANDARD=11"
# Release tarballs do not contain the required Protobuf definitions.
cp -r $PREFIX/share/opentelemetry/opentelemetry-proto/opentelemetry ./third_party/opentelemetry-proto/
+# Stop CMake from trying to git clone the Protobuf definitions.
+mkdir ./third_party/opentelemetry-proto/.git
mkdir -p build-cpp
pushd build-cpp
diff --git a/recipes/cpp-opentelemetry-sdk/meta.yaml b/recipes/cpp-opentelemetry-sdk/meta.yaml
index c3dc3eb526eeb..18c3ddadb3c53 100644
--- a/recipes/cpp-opentelemetry-sdk/meta.yaml
+++ b/recipes/cpp-opentelemetry-sdk/meta.yaml
@@ -34,10 +34,10 @@ test:
- test -d $PREFIX/lib/cmake/opentelemetry-cpp/ # [unix]
- test -f $PREFIX/lib/libopentelemetry_common.a # [unix]
- test -f $PREFIX/lib/libopentelemetry_exporter_otlp_grpc.a # [unix]
- - if not exist %LIBRARY_INC%\\opentelemetry\\sdk exit 1 # [win]
- - if not exist %LIBRARY_LIB%\\opentelemetry\\cmake\\opentelemetry-cpp exit 1 # [win]
- - if not exist %LIBRARY_LIB%\\opentelemetry\\libopentelemetry_common.lib exit 1 # [win]
- - if not exist %LIBRARY_LIB%\\opentelemetry\\libopentelemetry_exporter_otlp_grpc.lib exit 1 # [win]
+ - if not exist %LIBRARY_INC%\opentelemetry\sdk exit 1 # [win]
+ - if not exist %LIBRARY_LIB%\cmake\opentelemetry-cpp exit 1 # [win]
+ - if not exist %LIBRARY_LIB%\opentelemetry_common.lib exit 1 # [win]
+ - if not exist %LIBRARY_LIB%\opentelemetry_exporter_otlp_grpc.lib exit 1 # [win]
about:
home: https://github.com/open-telemetry/opentelemetry-cpp
diff --git a/recipes/proto-opentelemetry-proto/bld.bat b/recipes/proto-opentelemetry-proto/bld.bat
index c4c1c5f25b8c0..9355e1d676b96 100644
--- a/recipes/proto-opentelemetry-proto/bld.bat
+++ b/recipes/proto-opentelemetry-proto/bld.bat
@@ -8,5 +8,5 @@ copy LICENSE %DEST_DIR%
if %ERRORLEVEL% NEQ 0 exit 1
REM robocopy returns non-zero exit codes on success
-robocopy /S /E opentelemetry\ %DEST_DIR%\
+robocopy /S /E opentelemetry\ %DEST_DIR%\opentelemetry
if %ERRORLEVEL% GEQ 8 exit 1
diff --git a/recipes/proto-opentelemetry-proto/meta.yaml b/recipes/proto-opentelemetry-proto/meta.yaml
index 4b75a0d1869cf..f28ea481b777f 100644
--- a/recipes/proto-opentelemetry-proto/meta.yaml
+++ b/recipes/proto-opentelemetry-proto/meta.yaml
@@ -22,8 +22,8 @@ test:
commands:
- test -f $PREFIX/share/opentelemetry/opentelemetry-proto/LICENSE # [unix]
- test -f $PREFIX/share/opentelemetry/opentelemetry-proto/opentelemetry/proto/common/v1/common.proto # [unix]
- - if not exist %PREFIX%\\Library\\share\\opentelemetry\\opentelemetry-proto\\LICENSE exit 1 # [win]
- - if not exist %PREFIX%\\Library\\share\\opentelemetry\\opentelemetry-proto\\opentelemetry\\proto\\common\\v1\\common.proto exit 1 # [win]
+ - if not exist %PREFIX%\Library\share\opentelemetry\opentelemetry-proto\LICENSE exit 1 # [win]
+ - if not exist %PREFIX%\Library\share\opentelemetry\opentelemetry-proto\opentelemetry\proto\common\v1\common.proto exit 1 # [win]
about:
home: https://github.com/open-telemetry/opentelemetry-proto