bbahnsen | b9e16a8 | 2006-04-24 16:38:10 +0000 | [diff] [blame] | 1 | # |
hhtian | 92063c4 | 2011-02-16 12:21:31 +0000 | [diff] [blame] | 2 | # Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> |
hhtian | 24542fb | 2010-04-29 15:17:20 +0000 | [diff] [blame] | 3 | # This program and the accompanying materials |
bbahnsen | b9e16a8 | 2006-04-24 16:38:10 +0000 | [diff] [blame] | 4 | # are licensed and made available under the terms and conditions of the BSD License |
| 5 | # which accompanies this distribution. The full text of the license may be found at |
| 6 | # http://opensource.org/licenses/bsd-license.php |
| 7 | # |
| 8 | # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, |
| 9 | # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. |
klu2 | 2b1473c | 2009-07-08 05:54:53 +0000 | [diff] [blame] | 10 | # |
| 11 | # In *inux environment, the build tools's source is required and need to be compiled |
| 12 | # firstly, please reference https://edk2.tianocore.org/unix-getting-started.html to |
| 13 | # to get how to setup build tool. |
| 14 | # |
| 15 | # After build tool is downloaded and compiled, a soft symbol linker need to be created |
| 16 | # at <workspace>/Conf. For example: ln -s /work/BaseTools /work/edk2/Conf/BaseToolsSource. |
| 17 | # |
bbahnsen | b9e16a8 | 2006-04-24 16:38:10 +0000 | [diff] [blame] | 18 | # Setup the environment for unix-like systems running a bash-like shell. |
bbahnsen | 6dbea97 | 2006-11-14 17:57:07 +0000 | [diff] [blame] | 19 | # This file must be "sourced" not merely executed. For example: ". edksetup.sh" |
klu2 | 2b1473c | 2009-07-08 05:54:53 +0000 | [diff] [blame] | 20 | # |
bbahnsen | 6dbea97 | 2006-11-14 17:57:07 +0000 | [diff] [blame] | 21 | # CYGWIN users: Your path and filename related environment variables should be |
| 22 | # set up in the unix style. This script will make the necessary conversions to |
| 23 | # windows style. |
klu2 | 2b1473c | 2009-07-08 05:54:53 +0000 | [diff] [blame] | 24 | # |
| 25 | # Please reference edk2 user manual for more detail descriptions at https://edk2.tianocore.org/files/documents/64/494/EDKII_UserManual.pdf |
| 26 | # |
bbahnsen | b9e16a8 | 2006-04-24 16:38:10 +0000 | [diff] [blame] | 27 | |
bbahnsen | 4818627 | 2006-07-14 08:02:04 +0000 | [diff] [blame] | 28 | if [ \ |
jljusten | a310886 | 2007-10-16 20:52:46 +0000 | [diff] [blame] | 29 | "$1" = "-?" -o \ |
| 30 | "$1" = "-h" -o \ |
| 31 | "$1" = "--help" \ |
| 32 | ] |
bbahnsen | 4818627 | 2006-07-14 08:02:04 +0000 | [diff] [blame] | 33 | then |
lhauch | 3a6b455 | 2008-12-31 16:57:24 +0000 | [diff] [blame] | 34 | echo BaseTools Usage: \'. edksetup.sh\' |
jljusten | a310886 | 2007-10-16 20:52:46 +0000 | [diff] [blame] | 35 | echo |
| 36 | echo Please note: This script must be \'sourced\' so the environment can be changed. |
| 37 | echo \(Either \'. edksetup.sh\' or \'source edksetup.sh\'\) |
| 38 | return |
bbahnsen | 4818627 | 2006-07-14 08:02:04 +0000 | [diff] [blame] | 39 | fi |
jljusten | a310886 | 2007-10-16 20:52:46 +0000 | [diff] [blame] | 40 | |
lhauch | 3a6b455 | 2008-12-31 16:57:24 +0000 | [diff] [blame] | 41 | if [ -z "$WORKSPACE" ] |
jljusten | a310886 | 2007-10-16 20:52:46 +0000 | [diff] [blame] | 42 | then |
lhauch | 3a6b455 | 2008-12-31 16:57:24 +0000 | [diff] [blame] | 43 | . BaseTools/BuildEnv $* |
jljusten | a310886 | 2007-10-16 20:52:46 +0000 | [diff] [blame] | 44 | else |
lhauch | 3a6b455 | 2008-12-31 16:57:24 +0000 | [diff] [blame] | 45 | . $WORKSPACE/BaseTools/BuildEnv $* |
bbahnsen | b9e16a8 | 2006-04-24 16:38:10 +0000 | [diff] [blame] | 46 | fi |
jljusten | a310886 | 2007-10-16 20:52:46 +0000 | [diff] [blame] | 47 | |
| 48 | |