From 9babc9e51f7756f86f1108db4dfa6dff524330ea Mon Sep 17 00:00:00 2001 From: Stan Bondi Date: Wed, 7 Sep 2022 14:33:42 +0400 Subject: [PATCH] fix: exclude libtor from windows build --- .github/workflows/base_node_binaries.json | 3 ++- .github/workflows/base_node_binaries.yml | 2 +- infrastructure/libtor/Cargo.toml | 5 +---- infrastructure/libtor/src/lib.rs | 3 ++- 4 files changed, 6 insertions(+), 7 deletions(-) diff --git a/.github/workflows/base_node_binaries.json b/.github/workflows/base_node_binaries.json index 68641b79525..f3a72d7ae52 100644 --- a/.github/workflows/base_node_binaries.json +++ b/.github/workflows/base_node_binaries.json @@ -43,7 +43,8 @@ "target": "x86_64-pc-windows-msvc", "cross": false, "target_cpu": "x86-64", - "features": "safe" + "features": "safe", + "flags": "--workspace --exclude tari_libtor" }, { "name": "windows-arm64", diff --git a/.github/workflows/base_node_binaries.yml b/.github/workflows/base_node_binaries.yml index 7904f73ae42..01ce9f71014 100644 --- a/.github/workflows/base_node_binaries.yml +++ b/.github/workflows/base_node_binaries.yml @@ -187,7 +187,7 @@ jobs: with: use-cross: ${{ matrix.builds.cross }} command: build - args: --release --target ${{ matrix.builds.target }} --features ${{ matrix.builds.features }} ${{ matrix.builds.target_bins }} --locked + args: --release --target ${{ matrix.builds.target }} --features ${{ matrix.builds.features }} ${{ matrix.builds.target_bins }} ${{ matrix.builds.flags }} --locked - name: Copy binaries to folder for zipping shell: bash diff --git a/infrastructure/libtor/Cargo.toml b/infrastructure/libtor/Cargo.toml index f03dad5b624..eb625febe2d 100644 --- a/infrastructure/libtor/Cargo.toml +++ b/infrastructure/libtor/Cargo.toml @@ -16,7 +16,4 @@ multiaddr = { version = "0.14.0" } rand = "0.8" tempfile = "3.1.0" tor-hash-passwd = "1.0.1" - -[target.'cfg(unix)'.dependencies] -tari_shutdown = { version = "^0.38", path = "../shutdown"} -libtor = { version = "46.9.0", optional = true } +libtor = "46.9.0" diff --git a/infrastructure/libtor/src/lib.rs b/infrastructure/libtor/src/lib.rs index ee78b8179cd..cd762e3ec3f 100644 --- a/infrastructure/libtor/src/lib.rs +++ b/infrastructure/libtor/src/lib.rs @@ -20,5 +20,6 @@ // WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE // USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -#[cfg(unix)] +extern crate libtor; + pub mod tor;