-
Notifications
You must be signed in to change notification settings - Fork 126
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from ament/windows
Windows Support
- Loading branch information
Showing
13 changed files
with
147 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 7 additions & 2 deletions
9
ament_cmake_core/cmake/environment_hooks/ament_cmake_environment_hooks_package_hook.cmake
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
ament_cmake_core/cmake/environment_hooks/environment/ament_prefix_path.bat
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
:: copied from | ||
:: ament_cmake_core/cmake/environment_hooks/environment/ament_prefix_path.sh | ||
|
||
call:ament_prepend_unique_value AMENT_PREFIX_PATH "%AMENT_CURRENT_PREFIX%" | ||
|
||
|
||
goto:eof | ||
|
||
:: function to prepend non-duplicate values to environment variables | ||
:: using colons as separators and avoiding trailing separators | ||
:ament_prepend_unique_value | ||
setlocal enabledelayedexpansion | ||
:: arguments | ||
set "_listname=%~1" | ||
set "_value=%~2" | ||
:: expand the list variable | ||
set "_list=!%_listname%!" | ||
:: check if the list contains the value | ||
set "_is_duplicate=" | ||
if "%_list%" NEQ "" ( | ||
for %%a in ("%_list:;=";"%") do ( | ||
if "%%~a" == "%_value%" set "_is_duplicate=1" | ||
) | ||
) | ||
:: if it is not a duplicate prepend it | ||
if "%_is_duplicate%" == "" ( | ||
:: produces a trailing semicolon when the list empty, but that's ok | ||
set "_list=%_value%;%_list%" | ||
) | ||
(endlocal | ||
set "%~1=%_list%" | ||
) | ||
goto:eof |
31 changes: 31 additions & 0 deletions
31
ament_cmake_core/cmake/environment_hooks/environment/path.bat
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
:: copied from ament_cmake_core/cmake/environment_hooks/environment/path.bat | ||
|
||
call:ament_prepend_unique_value PATH "%AMENT_CURRENT_PREFIX%\bin" | ||
|
||
goto:eof | ||
|
||
:: function to prepend non-duplicate values to environment variables | ||
:: using colons as separators and avoiding trailing separators | ||
:ament_prepend_unique_value | ||
setlocal enabledelayedexpansion | ||
:: arguments | ||
set "_listname=%~1" | ||
set "_value=%~2" | ||
:: expand the list variable | ||
set "_list=!%_listname%!" | ||
:: check if the list contains the value | ||
set "_is_duplicate=" | ||
if "%_list%" NEQ "" ( | ||
for %%a in ("%_list:;=";"%") do ( | ||
if "%%~a" == "%_value%" set "_is_duplicate=1" | ||
) | ||
) | ||
:: if it is not a duplicate prepend it | ||
if "%_is_duplicate%" == "" ( | ||
:: produces a trailing semicolon when the list empty, but that's ok | ||
set "_list=%_value%;%_list%" | ||
) | ||
(endlocal | ||
set "%~1=%_list%" | ||
) | ||
goto:eof |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 34 additions & 0 deletions
34
ament_cmake_export_libraries/cmake/environment/library_path.bat.in
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
:: generated from ament_cmake_export_libraries/cmake/environment/library_path.sh.in | ||
if defined AMENT_TRACE_SETUP_FILES echo Inside %~0 | ||
|
||
call:ament_prepend_unique_value PATH "%AMENT_CURRENT_PREFIX%\lib" | ||
|
||
if defined AMENT_TRACE_SETUP_FILES echo Leaving %~0 | ||
goto:eof | ||
|
||
:: function to prepend non-duplicate values to environment variables | ||
:: using colons as separators and avoiding trailing separators | ||
:ament_prepend_unique_value | ||
setlocal enabledelayedexpansion | ||
:: arguments | ||
set "_listname=%~1" | ||
set "_value=%~2" | ||
:: expand the list variable | ||
set "_list=!%_listname%!" | ||
:: check if the list contains the value | ||
set "_is_duplicate=" | ||
if "%_list%" NEQ "" ( | ||
for %%a in ("%_list:;=";"%") do ( | ||
if "%%~a" == "%_value%" set "_is_duplicate=1" | ||
) | ||
) | ||
:: if it is not a duplicate prepend it | ||
if "%_is_duplicate%" == "" ( | ||
:: produces a trailing semicolon when the list empty, but that's ok | ||
set "_list=%_value%;%_list%" | ||
) | ||
(endlocal | ||
set "%~1=%_list%" | ||
) | ||
goto:eof | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters