On 02/06/13 12:06, David Woodhouse wrote:
> On Tue, 2013-02-05 at 23:14 -0500, Kevin O'Connor wrote:
>>  I still need to get an OVMF environment up to test this - I'll do
>> that tomorrow. 

(Sorry for not having yet begun the review, working on other stuff...
But certainly don't wait for my review; I skimmed the series last night,
and whatever I managed to understand at first glance didn't set off any
alarms for me.)

> Should go something like this...
> 
> git clone git://git.infradead.org/users/dwmw2/edk2.git
> cd edk2
> make -C BaseTools
> . edksetup.sh
> ln -sf /where/your/seabios/out/bios.bin OvmfPkg/Csm/Csm16/Csm16.bin
> sed s/-melf_x86_64// -i Conf/tools_def.txt

If you're doing this for gcc-4.7, then please see
<http://sourceforge.net/mailarchive/forum.php?thread_name=1341995918-22888-1-git-send-email-pbonzini%40redhat.com&forum_name=edk2-buildtools-devel>.
The patch should be applied before running (sourcing) edksetup.sh, and
then the sed command should not be necessary.

The patch has already been picked up by the edk2-buildtools project,
which is expected to be synced into edk2 in 2013q1;
<http://sourceforge.net/mailarchive/forum.php?thread_name=cafe8ug_blmvkiuasqu4g7_lcw-rxz5ryvvfphkwmt-7ean_...@mail.gmail.com&forum_name=edk2-devel>.


> sed -e s%^ACTIVE_PLATFORM.*%ACTIVE_PLATFORM=OvmfPkg/OvmfPkgX64.dsc% \
>     -e s/^TARGET_ARCH.*/TARGET_ARCH=X64/ \
>     -e s/^TOOL_CHAIN_TAG.*/TOOL_CHAIN_TAG=GCC46/ \
>     -i Conf/target.txt

These can all be passed to the "build" utility (see build -h):

-p OvmfPkg/OvmfPkgX64.dsc \
-a X64 \
-t GCC47

(assuming you have the gcc47 patch from above).

I'd also recommend the following option, for a parallel build, 50%
oversubscription:

-n $(( $(getconf _NPROCESSORS_ONLN) * 3 / 2 ))

> build -D CSM_ENABLE -DDEBUG_ON_SERIAL_PORT

Finally, there's a wrapper script in "OvmfPkg/build.sh"; it accepts
"-n", and sets up / detects the rest of the above for you. Using that
(with the gcc47 patch), it should be only

  git clone git://git.infradead.org/users/dwmw2/edk2.git
  cd edk2
  # apply gcc47 patch if not yet in David's tree
  ln -sf /where/your/seabios/out/bios.bin OvmfPkg/Csm/Csm16/Csm16.bin
  OvmfPkg/build.sh \
      -D CSM_ENABLE -D DEBUG_ON_SERIAL_PORT \
      -n $(( $(getconf _NPROCESSORS_ONLN) * 3 / 2 ))

Thanks
Laszlo

_______________________________________________
SeaBIOS mailing list
SeaBIOS@seabios.org
http://www.seabios.org/mailman/listinfo/seabios

Reply via email to