Re: [edk2] [PATCH v2 1/2] edksetup.sh: Look for BuildEnv under EDK_TOOLS_PATH

Subject: Re: [edk2] [PATCH v2 1/2] edksetup.sh: Look for BuildEnv under EDK_TOOLS_PATH

From: Paolo Bonzini <pbonzini@redhat.com>

To: Jordan Justen <jljusten@gmail.com>

Date: 2014-06-26 05:17:51

Il 25/06/2014 20:34, Jordan Justen ha scritto:
> If both EDK_TOOLS_PATH and WORKSPACE are set, then wouldn't it be
> better to run $EDK_TOOLS_PATH/BuildEnv?

I was trying to change as little as possible in this patch.  The next 
patch starts "changing the rules" by using $EDK_TOOLS_PATH/BuildEnv if 
there are no BaseTools inside $WORKSPACE.

What you are saying makes sense, but I was not sure of how people are 
using these scripts.  If you say it's okay, I can change it to look at 
EDK_TOOLS_PATH first.

Paolo

>
> -Jordan
>
> On Wed, Jun 25, 2014 at 1:37 AM, Paolo Bonzini  wrote:
>> EDK_TOOLS_PATH is basically a replacement for $WORKSPACE/BaseTools.
>>
>> It makes sense to check for BuildEnv there, then, if $WORKSPACE
>> is absent but $EDK_TOOLS_PATH is present.
>>
>> With this patch, it is possible to separately package tools in
>> /usr and use them compile EDK2 (doing "rm -rf BaseTools" in the
>> EDK2 tree).  This is desirable for OS distributions that need to
>> distribute the tools in a "free software" repository and OVMF in
>> a "non-free software" repository; bundling the same code in two
>> different packages causes confusion.  It is also simpler for distros
>> because the build process for BaseTools and OVMF is completely
>> different.
>>
>> Contributed-under: TianoCore Contribution Agreement 1.0
>> Reviewed-by: Laszlo Ersek 
>> Signed-off-by: Paolo Bonzini 
>> ---
>>  edksetup.sh | 9 ++++++---
>>  1 file changed, 6 insertions(+), 3 deletions(-)
>>
>> diff --git a/edksetup.sh b/edksetup.sh
>> index 0b7e33f..5b4d37e 100755
>> --- a/edksetup.sh
>> +++ b/edksetup.sh
>> @@ -35,11 +35,14 @@ function HelpMsg()
>>
>>  function SetupEnv()
>>  {
>> -  if [ -z "$WORKSPACE" ]
>> +  if [ -n "$WORKSPACE" ]
>>    then
>> -    . BaseTools/BuildEnv $*
>> -  else
>>      . $WORKSPACE/BaseTools/BuildEnv $*
>> +  elif [ -n "$EDK_TOOLS_PATH" ]
>> +  then
>> +    . $EDK_TOOLS_PATH/BuildEnv $*
>> +  else
>> +    . BaseTools/BuildEnv $*
>>    fi
>>  }
>>
>> --
>> 1.9.3
>>
>>


------------------------------------------------------------------------------
Open source business process management suite built on Java and Eclipse
Turn processes into business applications with Bonita BPM Community Edition
Quickly connect people, data, and systems into organized workflows
Winner of BOSSIE, CODIE, OW2 and Gartner awards
http://p.sf.net/sfu/Bonitasoft
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel