Skip to content

Commit

Permalink
build: Only for Unix systems
Browse files Browse the repository at this point in the history
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
  • Loading branch information
jjerphan committed Jan 6, 2025
1 parent b81f865 commit 2045b78
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 0 deletions.
32 changes: 32 additions & 0 deletions recipe/0002-build-Only-for-Unix-systems.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
From 33713ee0b44fea3d4ee78ab40d403bebb0e75daf Mon Sep 17 00:00:00 2001
From: Julien Jerphanion <git@jjerphan.xyz>
Date: Mon, 6 Jan 2025 13:17:03 +0100
Subject: [PATCH] build: Only for Unix systems

Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>

Co-authored-by: Klaim <Klaim@users.noreply.github.com>
---
micromamba/CMakeLists.txt | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/micromamba/CMakeLists.txt b/micromamba/CMakeLists.txt
index 4d313644..a75d436d 100644
--- a/micromamba/CMakeLists.txt
+++ b/micromamba/CMakeLists.txt
@@ -105,9 +105,9 @@ endif()
# Installation
# ============

-# The script are only needed for mamba and not for micromamba
-
-if(BUILD_SHARED)
+# This profile script is only needed for mamba on Unix systems.
+if(BUILD_SHARED AND UNIX)
+ message(STATUS "Generating profile script for mamba (i.e. `etc/profile.d/mamba.sh`)")
configure_file(
"${CMAKE_CURRENT_SOURCE_DIR}/etc/profile.d/mamba.sh.in"
"${CMAKE_CURRENT_BINARY_DIR}/etc/profile.d/mamba.sh"
--
2.47.1

1 change: 1 addition & 0 deletions recipe/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ source:
sha256: 4960fc5aa617310fb45e309a1bcfeae74085d70782443b1d2882de4400ac6a48
patches:
- 0001-build-Generate-and-install-etc-profile.d-mamba.sh-fo.patch
- 0002-build-Only-for-Unix-systems.patch

build:
number: 2
Expand Down

0 comments on commit 2045b78

Please sign in to comment.