public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* Newbie: Getting Ovmf built
@ 2018-11-23 22:44 Peter Wiehe
  2018-11-24  0:40 ` stephano
  0 siblings, 1 reply; 11+ messages in thread
From: Peter Wiehe @ 2018-11-23 22:44 UTC (permalink / raw)
  To: edk2-devel

Hello, I'm a total newbie to Tianocore/EDK2/OVMF.
(My coding is at high school level I think, not university level. I
have some (small) experience writing in Assembler, C, C++. I wrote a
little bootloader, so I know something about filesystem in general and
ext2 and pre-kernel "environment".)

I use xubuntu 18.04 on an AMD 64bit PC.

I'm currently trying to
1.) build OVMF from source
2.) and then want to run it in/with Qemu.
3.) Later I would like to try to write a simple ext2 "driver". Can't
guarantee I will succeed, but let's see.

So far I have
1.) downloaded the whole edk2 zip/tar-ball
2.) have installed nasm and ASL (iasl)
3.) Run "EmulatorPkg/build.sh"
4.) Run "OvmfPkg/build.sh -a X64"
5.) Run "OvmfPkg/build.sh -a X64 qemu"

Then I get the error message "qemu-system-x86_64: -pflash
/home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin:
Could not open '/home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin':
No such file or directory"

So my first question is how to deal with this error.

Kind regards
Peter Wiehe


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Newbie: Getting Ovmf built
  2018-11-23 22:44 Newbie: Getting Ovmf built Peter Wiehe
@ 2018-11-24  0:40 ` stephano
  2018-11-24 17:23   ` Peter Wiehe
  2018-11-25  5:59   ` Rebecca Cran
  0 siblings, 2 replies; 11+ messages in thread
From: stephano @ 2018-11-24  0:40 UTC (permalink / raw)
  To: edk2-devel

Hello Peter,

Thanks for giving EDK2 a try!

We have a set of simple instructions for folks building on standard 
Linux distros. Please have a look at this page:

https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions

Note: Be sure the TARGET_ARCH is set correctly. (E.g. TARGET_ARCH = x64)

Once you have built the BaseTools and MdeModulePkg without any errors, 
you can try building and running in OVMF:

https://github.com/tianocore/tianocore.github.io/wiki/How-to-build-OVMF

Tip: Add the -j option so that you can grep through the log easily for 
any errors (build -j /path/to/log/file.txt).

Hopefully those links help get you started. Let me know if you run into 
any other issues.

Cheers,
Stephano

Stephano Cetola
TianoCore Community Manager

On 11/23/2018 2:44 PM, Peter Wiehe wrote:
> Hello, I'm a total newbie to Tianocore/EDK2/OVMF.
> (My coding is at high school level I think, not university level. I
> have some (small) experience writing in Assembler, C, C++. I wrote a
> little bootloader, so I know something about filesystem in general and
> ext2 and pre-kernel "environment".)
> 
> I use xubuntu 18.04 on an AMD 64bit PC.
> 
> I'm currently trying to
> 1.) build OVMF from source
> 2.) and then want to run it in/with Qemu.
> 3.) Later I would like to try to write a simple ext2 "driver". Can't
> guarantee I will succeed, but let's see.
> 
> So far I have
> 1.) downloaded the whole edk2 zip/tar-ball
> 2.) have installed nasm and ASL (iasl)
> 3.) Run "EmulatorPkg/build.sh"
> 4.) Run "OvmfPkg/build.sh -a X64"
> 5.) Run "OvmfPkg/build.sh -a X64 qemu"
> 
> Then I get the error message "qemu-system-x86_64: -pflash
> /home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin:
> Could not open '/home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin':
> No such file or directory"
> 
> So my first question is how to deal with this error.
> 
> Kind regards
> Peter Wiehe
> _______________________________________________
> edk2-devel mailing list
> edk2-devel@lists.01.org
> https://lists.01.org/mailman/listinfo/edk2-devel
> 


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Newbie: Getting Ovmf built
  2018-11-24  0:40 ` stephano
@ 2018-11-24 17:23   ` Peter Wiehe
  2018-11-24 17:57     ` stephano
  2018-11-26 14:09     ` Gao, Liming
  2018-11-25  5:59   ` Rebecca Cran
  1 sibling, 2 replies; 11+ messages in thread
From: Peter Wiehe @ 2018-11-24 17:23 UTC (permalink / raw)
  To: edk2-devel

OK

Building went well to a certain point. I successfully git cloned. I
built the BaseTools.

I (seemingly successfully) setup the build shell environment. (I got no errors.)

In the target conf file I chose "IA32 X64" and ELFGCC (since I habe
gcc 7.3.0 installed).
When I type "build", there comes an error like "Command build not found".

I thought that maybe it's because of the shell environment variable
$PATH. $PATH does NOT contain the edk2 source directory in any way
(despite the fact that I entered "export EDK_TOOLS_PATH...").

What can I do?

Greetings
Peter

2018-11-24 1:40 GMT+01:00, stephano <stephano.cetola@linux.intel.com>:
> Hello Peter,
>
> Thanks for giving EDK2 a try!
>
> We have a set of simple instructions for folks building on standard
> Linux distros. Please have a look at this page:
>
> https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions
>
> Note: Be sure the TARGET_ARCH is set correctly. (E.g. TARGET_ARCH = x64)
>
> Once you have built the BaseTools and MdeModulePkg without any errors,
> you can try building and running in OVMF:
>
> https://github.com/tianocore/tianocore.github.io/wiki/How-to-build-OVMF
>
> Tip: Add the -j option so that you can grep through the log easily for
> any errors (build -j /path/to/log/file.txt).
>
> Hopefully those links help get you started. Let me know if you run into
> any other issues.
>
> Cheers,
> Stephano
>
> Stephano Cetola
> TianoCore Community Manager
>
> On 11/23/2018 2:44 PM, Peter Wiehe wrote:
>> Hello, I'm a total newbie to Tianocore/EDK2/OVMF.
>> (My coding is at high school level I think, not university level. I
>> have some (small) experience writing in Assembler, C, C++. I wrote a
>> little bootloader, so I know something about filesystem in general and
>> ext2 and pre-kernel "environment".)
>>
>> I use xubuntu 18.04 on an AMD 64bit PC.
>>
>> I'm currently trying to
>> 1.) build OVMF from source
>> 2.) and then want to run it in/with Qemu.
>> 3.) Later I would like to try to write a simple ext2 "driver". Can't
>> guarantee I will succeed, but let's see.
>>
>> So far I have
>> 1.) downloaded the whole edk2 zip/tar-ball
>> 2.) have installed nasm and ASL (iasl)
>> 3.) Run "EmulatorPkg/build.sh"
>> 4.) Run "OvmfPkg/build.sh -a X64"
>> 5.) Run "OvmfPkg/build.sh -a X64 qemu"
>>
>> Then I get the error message "qemu-system-x86_64: -pflash
>> /home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin:
>> Could not open
>> '/home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin':
>> No such file or directory"
>>
>> So my first question is how to deal with this error.
>>
>> Kind regards
>> Peter Wiehe
>> _______________________________________________
>> edk2-devel mailing list
>> edk2-devel@lists.01.org
>> https://lists.01.org/mailman/listinfo/edk2-devel
>>
>


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Newbie: Getting Ovmf built
  2018-11-24 17:23   ` Peter Wiehe
@ 2018-11-24 17:57     ` stephano
  2018-11-24 18:03       ` Peter Wiehe
  2018-11-26 14:09     ` Gao, Liming
  1 sibling, 1 reply; 11+ messages in thread
From: stephano @ 2018-11-24 17:57 UTC (permalink / raw)
  To: Peter Wiehe; +Cc: edk2-devel

Hey Peter,

We're still using GCC5 for most of our testing. Try building with that 
release:

apt install gcc-5

Then in Conf/target.txt:
TOOL_CHAIN_TAG = GCC5

Cheers,
Stephano

On 11/24/2018 9:23 AM, Peter Wiehe wrote:
> OK
> 
> Building went well to a certain point. I successfully git cloned. I
> built the BaseTools.
> 
> I (seemingly successfully) setup the build shell environment. (I got no errors.)
> 
> In the target conf file I chose "IA32 X64" and ELFGCC (since I habe
> gcc 7.3.0 installed).
> When I type "build", there comes an error like "Command build not found".
> 
> I thought that maybe it's because of the shell environment variable
> $PATH. $PATH does NOT contain the edk2 source directory in any way
> (despite the fact that I entered "export EDK_TOOLS_PATH...").
> 
> What can I do?
> 
> Greetings
> Peter
> 
> 2018-11-24 1:40 GMT+01:00, stephano <stephano.cetola@linux.intel.com>:
>> Hello Peter,
>>
>> Thanks for giving EDK2 a try!
>>
>> We have a set of simple instructions for folks building on standard
>> Linux distros. Please have a look at this page:
>>
>> https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions
>>
>> Note: Be sure the TARGET_ARCH is set correctly. (E.g. TARGET_ARCH = x64)
>>
>> Once you have built the BaseTools and MdeModulePkg without any errors,
>> you can try building and running in OVMF:
>>
>> https://github.com/tianocore/tianocore.github.io/wiki/How-to-build-OVMF
>>
>> Tip: Add the -j option so that you can grep through the log easily for
>> any errors (build -j /path/to/log/file.txt).
>>
>> Hopefully those links help get you started. Let me know if you run into
>> any other issues.
>>
>> Cheers,
>> Stephano
>>
>> Stephano Cetola
>> TianoCore Community Manager
>>
>> On 11/23/2018 2:44 PM, Peter Wiehe wrote:
>>> Hello, I'm a total newbie to Tianocore/EDK2/OVMF.
>>> (My coding is at high school level I think, not university level. I
>>> have some (small) experience writing in Assembler, C, C++. I wrote a
>>> little bootloader, so I know something about filesystem in general and
>>> ext2 and pre-kernel "environment".)
>>>
>>> I use xubuntu 18.04 on an AMD 64bit PC.
>>>
>>> I'm currently trying to
>>> 1.) build OVMF from source
>>> 2.) and then want to run it in/with Qemu.
>>> 3.) Later I would like to try to write a simple ext2 "driver". Can't
>>> guarantee I will succeed, but let's see.
>>>
>>> So far I have
>>> 1.) downloaded the whole edk2 zip/tar-ball
>>> 2.) have installed nasm and ASL (iasl)
>>> 3.) Run "EmulatorPkg/build.sh"
>>> 4.) Run "OvmfPkg/build.sh -a X64"
>>> 5.) Run "OvmfPkg/build.sh -a X64 qemu"
>>>
>>> Then I get the error message "qemu-system-x86_64: -pflash
>>> /home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin:
>>> Could not open
>>> '/home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin':
>>> No such file or directory"
>>>
>>> So my first question is how to deal with this error.
>>>
>>> Kind regards
>>> Peter Wiehe
>>> _______________________________________________
>>> edk2-devel mailing list
>>> edk2-devel@lists.01.org
>>> https://lists.01.org/mailman/listinfo/edk2-devel
>>>
>>
> _______________________________________________
> edk2-devel mailing list
> edk2-devel@lists.01.org
> https://lists.01.org/mailman/listinfo/edk2-devel
> 


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Newbie: Getting Ovmf built
  2018-11-24 17:57     ` stephano
@ 2018-11-24 18:03       ` Peter Wiehe
  2018-11-24 19:45         ` Andrew Fish
  0 siblings, 1 reply; 11+ messages in thread
From: Peter Wiehe @ 2018-11-24 18:03 UTC (permalink / raw)
  To: edk2-devel

OK, thanks! Done that.

But how do I get to build the MdeModulePkg? I did setup as mentioned
in https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions

Peter

2018-11-24 18:57 GMT+01:00, stephano <stephano.cetola@linux.intel.com>:
> Hey Peter,
>
> We're still using GCC5 for most of our testing. Try building with that
> release:
>
> apt install gcc-5
>
> Then in Conf/target.txt:
> TOOL_CHAIN_TAG = GCC5
>
> Cheers,
> Stephano
>
> On 11/24/2018 9:23 AM, Peter Wiehe wrote:
>> OK
>>
>> Building went well to a certain point. I successfully git cloned. I
>> built the BaseTools.
>>
>> I (seemingly successfully) setup the build shell environment. (I got no
>> errors.)
>>
>> In the target conf file I chose "IA32 X64" and ELFGCC (since I habe
>> gcc 7.3.0 installed).
>> When I type "build", there comes an error like "Command build not found".
>>
>> I thought that maybe it's because of the shell environment variable
>> $PATH. $PATH does NOT contain the edk2 source directory in any way
>> (despite the fact that I entered "export EDK_TOOLS_PATH...").
>>
>> What can I do?
>>
>> Greetings
>> Peter
>>
>> 2018-11-24 1:40 GMT+01:00, stephano <stephano.cetola@linux.intel.com>:
>>> Hello Peter,
>>>
>>> Thanks for giving EDK2 a try!
>>>
>>> We have a set of simple instructions for folks building on standard
>>> Linux distros. Please have a look at this page:
>>>
>>> https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions
>>>
>>> Note: Be sure the TARGET_ARCH is set correctly. (E.g. TARGET_ARCH = x64)
>>>
>>> Once you have built the BaseTools and MdeModulePkg without any errors,
>>> you can try building and running in OVMF:
>>>
>>> https://github.com/tianocore/tianocore.github.io/wiki/How-to-build-OVMF
>>>
>>> Tip: Add the -j option so that you can grep through the log easily for
>>> any errors (build -j /path/to/log/file.txt).
>>>
>>> Hopefully those links help get you started. Let me know if you run into
>>> any other issues.
>>>
>>> Cheers,
>>> Stephano
>>>
>>> Stephano Cetola
>>> TianoCore Community Manager
>>>
>>> On 11/23/2018 2:44 PM, Peter Wiehe wrote:
>>>> Hello, I'm a total newbie to Tianocore/EDK2/OVMF.
>>>> (My coding is at high school level I think, not university level. I
>>>> have some (small) experience writing in Assembler, C, C++. I wrote a
>>>> little bootloader, so I know something about filesystem in general and
>>>> ext2 and pre-kernel "environment".)
>>>>
>>>> I use xubuntu 18.04 on an AMD 64bit PC.
>>>>
>>>> I'm currently trying to
>>>> 1.) build OVMF from source
>>>> 2.) and then want to run it in/with Qemu.
>>>> 3.) Later I would like to try to write a simple ext2 "driver". Can't
>>>> guarantee I will succeed, but let's see.
>>>>
>>>> So far I have
>>>> 1.) downloaded the whole edk2 zip/tar-ball
>>>> 2.) have installed nasm and ASL (iasl)
>>>> 3.) Run "EmulatorPkg/build.sh"
>>>> 4.) Run "OvmfPkg/build.sh -a X64"
>>>> 5.) Run "OvmfPkg/build.sh -a X64 qemu"
>>>>
>>>> Then I get the error message "qemu-system-x86_64: -pflash
>>>> /home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin:
>>>> Could not open
>>>> '/home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin':
>>>> No such file or directory"
>>>>
>>>> So my first question is how to deal with this error.
>>>>
>>>> Kind regards
>>>> Peter Wiehe
>>>> _______________________________________________
>>>> edk2-devel mailing list
>>>> edk2-devel@lists.01.org
>>>> https://lists.01.org/mailman/listinfo/edk2-devel
>>>>
>>>
>> _______________________________________________
>> edk2-devel mailing list
>> edk2-devel@lists.01.org
>> https://lists.01.org/mailman/listinfo/edk2-devel
>>
>


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Newbie: Getting Ovmf built
  2018-11-24 18:03       ` Peter Wiehe
@ 2018-11-24 19:45         ` Andrew Fish
  2018-11-24 19:46           ` Peter Wiehe
  0 siblings, 1 reply; 11+ messages in thread
From: Andrew Fish @ 2018-11-24 19:45 UTC (permalink / raw)
  To: Peter Wiehe; +Cc: edk2-devel

Run the build command. Conf/target.txt controls the default arguments passed to build.

Sourcing edksetup.sh should set your path. Did you miss the “.” or get an error?
. edksetup.sh BaseTools
> On Nov 24, 2018, at 10:03 AM, Peter Wiehe <peter.wiehe2@gmail.com> wrote:
> 
> OK, thanks! Done that.
> 
> But how do I get to build the MdeModulePkg? I did setup as mentioned
> in https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions
> 
> Peter
> 
> 2018-11-24 18:57 GMT+01:00, stephano <stephano.cetola@linux.intel.com>:
>> Hey Peter,
>> 
>> We're still using GCC5 for most of our testing. Try building with that
>> release:
>> 
>> apt install gcc-5
>> 
>> Then in Conf/target.txt:
>> TOOL_CHAIN_TAG = GCC5
>> 
>> Cheers,
>> Stephano
>> 
>>> On 11/24/2018 9:23 AM, Peter Wiehe wrote:
>>> OK
>>> 
>>> Building went well to a certain point. I successfully git cloned. I
>>> built the BaseTools.
>>> 
>>> I (seemingly successfully) setup the build shell environment. (I got no
>>> errors.)
>>> 
>>> In the target conf file I chose "IA32 X64" and ELFGCC (since I habe
>>> gcc 7.3.0 installed).
>>> When I type "build", there comes an error like "Command build not found".
>>> 
>>> I thought that maybe it's because of the shell environment variable
>>> $PATH. $PATH does NOT contain the edk2 source directory in any way
>>> (despite the fact that I entered "export EDK_TOOLS_PATH...").
>>> 
>>> What can I do?
>>> 
>>> Greetings
>>> Peter
>>> 
>>> 2018-11-24 1:40 GMT+01:00, stephano <stephano.cetola@linux.intel.com>:
>>>> Hello Peter,
>>>> 
>>>> Thanks for giving EDK2 a try!
>>>> 
>>>> We have a set of simple instructions for folks building on standard
>>>> Linux distros. Please have a look at this page:
>>>> 
>>>> https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions
>>>> 
>>>> Note: Be sure the TARGET_ARCH is set correctly. (E.g. TARGET_ARCH = x64)
>>>> 
>>>> Once you have built the BaseTools and MdeModulePkg without any errors,
>>>> you can try building and running in OVMF:
>>>> 
>>>> https://github.com/tianocore/tianocore.github.io/wiki/How-to-build-OVMF
>>>> 
>>>> Tip: Add the -j option so that you can grep through the log easily for
>>>> any errors (build -j /path/to/log/file.txt).
>>>> 
>>>> Hopefully those links help get you started. Let me know if you run into
>>>> any other issues.
>>>> 
>>>> Cheers,
>>>> Stephano
>>>> 
>>>> Stephano Cetola
>>>> TianoCore Community Manager
>>>> 
>>>>> On 11/23/2018 2:44 PM, Peter Wiehe wrote:
>>>>> Hello, I'm a total newbie to Tianocore/EDK2/OVMF.
>>>>> (My coding is at high school level I think, not university level. I
>>>>> have some (small) experience writing in Assembler, C, C++. I wrote a
>>>>> little bootloader, so I know something about filesystem in general and
>>>>> ext2 and pre-kernel "environment".)
>>>>> 
>>>>> I use xubuntu 18.04 on an AMD 64bit PC.
>>>>> 
>>>>> I'm currently trying to
>>>>> 1.) build OVMF from source
>>>>> 2.) and then want to run it in/with Qemu.
>>>>> 3.) Later I would like to try to write a simple ext2 "driver". Can't
>>>>> guarantee I will succeed, but let's see.
>>>>> 
>>>>> So far I have
>>>>> 1.) downloaded the whole edk2 zip/tar-ball
>>>>> 2.) have installed nasm and ASL (iasl)
>>>>> 3.) Run "EmulatorPkg/build.sh"
>>>>> 4.) Run "OvmfPkg/build.sh -a X64"
>>>>> 5.) Run "OvmfPkg/build.sh -a X64 qemu"
>>>>> 
>>>>> Then I get the error message "qemu-system-x86_64: -pflash
>>>>> /home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin:
>>>>> Could not open
>>>>> '/home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin':
>>>>> No such file or directory"
>>>>> 
>>>>> So my first question is how to deal with this error.
>>>>> 
>>>>> Kind regards
>>>>> Peter Wiehe
>>>>> _______________________________________________
>>>>> edk2-devel mailing list
>>>>> edk2-devel@lists.01.org
>>>>> https://lists.01.org/mailman/listinfo/edk2-devel
>>>>> 
>>>> 
>>> _______________________________________________
>>> edk2-devel mailing list
>>> edk2-devel@lists.01.org
>>> https://lists.01.org/mailman/listinfo/edk2-devel
>>> 
>> 
> _______________________________________________
> edk2-devel mailing list
> edk2-devel@lists.01.org
> https://lists.01.org/mailman/listinfo/edk2-devel


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Newbie: Getting Ovmf built
  2018-11-24 19:45         ` Andrew Fish
@ 2018-11-24 19:46           ` Peter Wiehe
  2018-11-24 20:44             ` Andrew Fish
  0 siblings, 1 reply; 11+ messages in thread
From: Peter Wiehe @ 2018-11-24 19:46 UTC (permalink / raw)
  To: Andrew Fish; +Cc: edk2-devel

As I said: I can't run "build". That command is unkown.

Peter

Andrew Fish <afish@apple.com> schrieb am Sa., 24. Nov. 2018 20:45:

> Run the build command. Conf/target.txt controls the default arguments
> passed to build.
>
> Sourcing edksetup.sh should set your path. Did you miss the “.” or get an
> error?
> . edksetup.sh BaseTools
>
> Sent from my iPad
>
> > On Nov 24, 2018, at 10:03 AM, Peter Wiehe <peter.wiehe2@gmail.com>
> wrote:
> >
> > OK, thanks! Done that.
> >
> > But how do I get to build the MdeModulePkg? I did setup as mentioned
> > in
> https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions
> >
> > Peter
> >
> > 2018-11-24 18:57 GMT+01:00, stephano <stephano.cetola@linux.intel.com>:
> >> Hey Peter,
> >>
> >> We're still using GCC5 for most of our testing. Try building with that
> >> release:
> >>
> >> apt install gcc-5
> >>
> >> Then in Conf/target.txt:
> >> TOOL_CHAIN_TAG = GCC5
> >>
> >> Cheers,
> >> Stephano
> >>
> >>> On 11/24/2018 9:23 AM, Peter Wiehe wrote:
> >>> OK
> >>>
> >>> Building went well to a certain point. I successfully git cloned. I
> >>> built the BaseTools.
> >>>
> >>> I (seemingly successfully) setup the build shell environment. (I got no
> >>> errors.)
> >>>
> >>> In the target conf file I chose "IA32 X64" and ELFGCC (since I habe
> >>> gcc 7.3.0 installed).
> >>> When I type "build", there comes an error like "Command build not
> found".
> >>>
> >>> I thought that maybe it's because of the shell environment variable
> >>> $PATH. $PATH does NOT contain the edk2 source directory in any way
> >>> (despite the fact that I entered "export EDK_TOOLS_PATH...").
> >>>
> >>> What can I do?
> >>>
> >>> Greetings
> >>> Peter
> >>>
> >>> 2018-11-24 1:40 GMT+01:00, stephano <stephano.cetola@linux.intel.com>:
> >>>> Hello Peter,
> >>>>
> >>>> Thanks for giving EDK2 a try!
> >>>>
> >>>> We have a set of simple instructions for folks building on standard
> >>>> Linux distros. Please have a look at this page:
> >>>>
> >>>>
> https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions
> >>>>
> >>>> Note: Be sure the TARGET_ARCH is set correctly. (E.g. TARGET_ARCH =
> x64)
> >>>>
> >>>> Once you have built the BaseTools and MdeModulePkg without any errors,
> >>>> you can try building and running in OVMF:
> >>>>
> >>>>
> https://github.com/tianocore/tianocore.github.io/wiki/How-to-build-OVMF
> >>>>
> >>>> Tip: Add the -j option so that you can grep through the log easily for
> >>>> any errors (build -j /path/to/log/file.txt).
> >>>>
> >>>> Hopefully those links help get you started. Let me know if you run
> into
> >>>> any other issues.
> >>>>
> >>>> Cheers,
> >>>> Stephano
> >>>>
> >>>> Stephano Cetola
> >>>> TianoCore Community Manager
> >>>>
> >>>>> On 11/23/2018 2:44 PM, Peter Wiehe wrote:
> >>>>> Hello, I'm a total newbie to Tianocore/EDK2/OVMF.
> >>>>> (My coding is at high school level I think, not university level. I
> >>>>> have some (small) experience writing in Assembler, C, C++. I wrote a
> >>>>> little bootloader, so I know something about filesystem in general
> and
> >>>>> ext2 and pre-kernel "environment".)
> >>>>>
> >>>>> I use xubuntu 18.04 on an AMD 64bit PC.
> >>>>>
> >>>>> I'm currently trying to
> >>>>> 1.) build OVMF from source
> >>>>> 2.) and then want to run it in/with Qemu.
> >>>>> 3.) Later I would like to try to write a simple ext2 "driver". Can't
> >>>>> guarantee I will succeed, but let's see.
> >>>>>
> >>>>> So far I have
> >>>>> 1.) downloaded the whole edk2 zip/tar-ball
> >>>>> 2.) have installed nasm and ASL (iasl)
> >>>>> 3.) Run "EmulatorPkg/build.sh"
> >>>>> 4.) Run "OvmfPkg/build.sh -a X64"
> >>>>> 5.) Run "OvmfPkg/build.sh -a X64 qemu"
> >>>>>
> >>>>> Then I get the error message "qemu-system-x86_64: -pflash
> >>>>>
> /home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin:
> >>>>> Could not open
> >>>>>
> '/home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin':
> >>>>> No such file or directory"
> >>>>>
> >>>>> So my first question is how to deal with this error.
> >>>>>
> >>>>> Kind regards
> >>>>> Peter Wiehe
> >>>>> _______________________________________________
> >>>>> edk2-devel mailing list
> >>>>> edk2-devel@lists.01.org
> >>>>> https://lists.01.org/mailman/listinfo/edk2-devel
> >>>>>
> >>>>
> >>> _______________________________________________
> >>> edk2-devel mailing list
> >>> edk2-devel@lists.01.org
> >>> https://lists.01.org/mailman/listinfo/edk2-devel
> >>>
> >>
> > _______________________________________________
> > edk2-devel mailing list
> > edk2-devel@lists.01.org
> > https://lists.01.org/mailman/listinfo/edk2-devel
>


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Newbie: Getting Ovmf built
  2018-11-24 19:46           ` Peter Wiehe
@ 2018-11-24 20:44             ` Andrew Fish
  0 siblings, 0 replies; 11+ messages in thread
From: Andrew Fish @ 2018-11-24 20:44 UTC (permalink / raw)
  To: Peter Wiehe; +Cc: edk2-devel



> On Nov 24, 2018, at 11:46 AM, Peter Wiehe <peter.wiehe2@gmail.com> wrote:
> 
> As I said: I can't run "build". That command is unkown.
> 

Peter,

The build command is what is required to build the firmware. 

Sourcing the edksetup.sh should set your path so build can be found. 

I'm on macOS and it looks like this to me:
/Volumes/Case/UDK2018(vUDK2018)>echo $PATH
/opt/local/bin:/opt/local/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Applications/VMware Fusion.app/Contents/Public:/opt/appleinternal/bin:/opt/apple/bin:/opt/X11/bin:/Applications/Araxis\ Merge.app/Contents/Utilities
/Volumes/Case/UDK2018(vUDK2018)>. edksetup.sh BaseTools
WORKSPACE: /Volumes/Case/UDK2018
EDK_TOOLS_PATH: /Volumes/Case/UDK2018/BaseTools
CONF_PATH: /Volumes/Case/UDK2018/Conf
/Volumes/Case/UDK2018(vUDK2018)>echo $PATH
/Volumes/Case/UDK2018/BaseTools/Bin/Darwin-x86_64:/Volumes/Case/UDK2018/BaseTools/BinWrappers/PosixLike:/opt/local/bin:/opt/local/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Applications/VMware Fusion.app/Contents/Public:/opt/appleinternal/bin:/opt/apple/bin:/opt/X11/bin:/Applications/Araxis\ Merge.app/Contents/Utilities
/Volumes/Case/UDK2018(vUDK2018)>which build
/Volumes/Case/UDK2018/BaseTools/BinWrappers/PosixLike/build
/Volumes/Case/UDK2018(vUDK2018)>cat /Volumes/Case/UDK2018/BaseTools/BinWrappers/PosixLike/build
#!/usr/bin/env bash
#python `dirname $0`/RunToolFromSource.py `basename $0` $*

# If a python2 command is available, use it in preference to python
if command -v python2 >/dev/null 2>&1; then
    python_exe=python2
fi

full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for a discussion of why $0 is not a good choice here
dir=$(dirname "$full_cmd")
cmd=${full_cmd##*/}

export PYTHONPATH="$dir/../../Source/Python"
exec "${python_exe:-python}" "$dir/../../Source/Python/$cmd/$cmd.py" "$@"

As you can see sourcing edksetup.sh should update your path to point to a location for build. What happens on your system? 

Thanks,

Andrew Fish

> Peter
> 
> Andrew Fish <afish@apple.com <mailto:afish@apple.com>> schrieb am Sa., 24. Nov. 2018 20:45:
> Run the build command. Conf/target.txt controls the default arguments passed to build.
> 
> Sourcing edksetup.sh should set your path. Did you miss the “.” or get an error?
> . edksetup.sh BaseTools
> 
> Sent from my iPad
> 
> > On Nov 24, 2018, at 10:03 AM, Peter Wiehe <peter.wiehe2@gmail.com <mailto:peter.wiehe2@gmail.com>> wrote:
> > 
> > OK, thanks! Done that.
> > 
> > But how do I get to build the MdeModulePkg? I did setup as mentioned
> > in https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions <https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions>
> > 
> > Peter
> > 
> > 2018-11-24 18:57 GMT+01:00, stephano <stephano.cetola@linux.intel.com <mailto:stephano.cetola@linux.intel.com>>:
> >> Hey Peter,
> >> 
> >> We're still using GCC5 for most of our testing. Try building with that
> >> release:
> >> 
> >> apt install gcc-5
> >> 
> >> Then in Conf/target.txt:
> >> TOOL_CHAIN_TAG = GCC5
> >> 
> >> Cheers,
> >> Stephano
> >> 
> >>> On 11/24/2018 9:23 AM, Peter Wiehe wrote:
> >>> OK
> >>> 
> >>> Building went well to a certain point. I successfully git cloned. I
> >>> built the BaseTools.
> >>> 
> >>> I (seemingly successfully) setup the build shell environment. (I got no
> >>> errors.)
> >>> 
> >>> In the target conf file I chose "IA32 X64" and ELFGCC (since I habe
> >>> gcc 7.3.0 installed).
> >>> When I type "build", there comes an error like "Command build not found".
> >>> 
> >>> I thought that maybe it's because of the shell environment variable
> >>> $PATH. $PATH does NOT contain the edk2 source directory in any way
> >>> (despite the fact that I entered "export EDK_TOOLS_PATH...").
> >>> 
> >>> What can I do?
> >>> 
> >>> Greetings
> >>> Peter
> >>> 
> >>> 2018-11-24 1:40 GMT+01:00, stephano <stephano.cetola@linux.intel.com <mailto:stephano.cetola@linux.intel.com>>:
> >>>> Hello Peter,
> >>>> 
> >>>> Thanks for giving EDK2 a try!
> >>>> 
> >>>> We have a set of simple instructions for folks building on standard
> >>>> Linux distros. Please have a look at this page:
> >>>> 
> >>>> https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions <https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions>
> >>>> 
> >>>> Note: Be sure the TARGET_ARCH is set correctly. (E.g. TARGET_ARCH = x64)
> >>>> 
> >>>> Once you have built the BaseTools and MdeModulePkg without any errors,
> >>>> you can try building and running in OVMF:
> >>>> 
> >>>> https://github.com/tianocore/tianocore.github.io/wiki/How-to-build-OVMF <https://github.com/tianocore/tianocore.github.io/wiki/How-to-build-OVMF>
> >>>> 
> >>>> Tip: Add the -j option so that you can grep through the log easily for
> >>>> any errors (build -j /path/to/log/file.txt).
> >>>> 
> >>>> Hopefully those links help get you started. Let me know if you run into
> >>>> any other issues.
> >>>> 
> >>>> Cheers,
> >>>> Stephano
> >>>> 
> >>>> Stephano Cetola
> >>>> TianoCore Community Manager
> >>>> 
> >>>>> On 11/23/2018 2:44 PM, Peter Wiehe wrote:
> >>>>> Hello, I'm a total newbie to Tianocore/EDK2/OVMF.
> >>>>> (My coding is at high school level I think, not university level. I
> >>>>> have some (small) experience writing in Assembler, C, C++. I wrote a
> >>>>> little bootloader, so I know something about filesystem in general and
> >>>>> ext2 and pre-kernel "environment".)
> >>>>> 
> >>>>> I use xubuntu 18.04 on an AMD 64bit PC.
> >>>>> 
> >>>>> I'm currently trying to
> >>>>> 1.) build OVMF from source
> >>>>> 2.) and then want to run it in/with Qemu.
> >>>>> 3.) Later I would like to try to write a simple ext2 "driver". Can't
> >>>>> guarantee I will succeed, but let's see.
> >>>>> 
> >>>>> So far I have
> >>>>> 1.) downloaded the whole edk2 zip/tar-ball
> >>>>> 2.) have installed nasm and ASL (iasl)
> >>>>> 3.) Run "EmulatorPkg/build.sh"
> >>>>> 4.) Run "OvmfPkg/build.sh -a X64"
> >>>>> 5.) Run "OvmfPkg/build.sh -a X64 qemu"
> >>>>> 
> >>>>> Then I get the error message "qemu-system-x86_64: -pflash
> >>>>> /home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin:
> >>>>> Could not open
> >>>>> '/home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin':
> >>>>> No such file or directory"
> >>>>> 
> >>>>> So my first question is how to deal with this error.
> >>>>> 
> >>>>> Kind regards
> >>>>> Peter Wiehe
> >>>>> _______________________________________________
> >>>>> edk2-devel mailing list
> >>>>> edk2-devel@lists.01.org <mailto:edk2-devel@lists.01.org>
> >>>>> https://lists.01.org/mailman/listinfo/edk2-devel <https://lists.01.org/mailman/listinfo/edk2-devel>
> >>>>> 
> >>>> 
> >>> _______________________________________________
> >>> edk2-devel mailing list
> >>> edk2-devel@lists.01.org <mailto:edk2-devel@lists.01.org>
> >>> https://lists.01.org/mailman/listinfo/edk2-devel <https://lists.01.org/mailman/listinfo/edk2-devel>
> >>> 
> >> 
> > _______________________________________________
> > edk2-devel mailing list
> > edk2-devel@lists.01.org <mailto:edk2-devel@lists.01.org>
> > https://lists.01.org/mailman/listinfo/edk2-devel <https://lists.01.org/mailman/listinfo/edk2-devel>



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Newbie: Getting Ovmf built
@ 2018-11-24 21:18 Peter Wiehe
  0 siblings, 0 replies; 11+ messages in thread
From: Peter Wiehe @ 2018-11-24 21:18 UTC (permalink / raw)
  To: edk2-devel

OK I simply re-did what I have done and now it works.
It was probably a typo of ". edksetup.sh BaseTools" or of the "export
..." command.

Kind regards
Peter

2018-11-24 21:44 GMT+01:00, Andrew Fish <afish@apple.com>:
>
>
>> On Nov 24, 2018, at 11:46 AM, Peter Wiehe <peter.wiehe2@gmail.com> wrote:
>>
>> As I said: I can't run "build". That command is unkown.
>>
>
> Peter,
>
> The build command is what is required to build the firmware.
>
> Sourcing the edksetup.sh should set your path so build can be found.
>
> I'm on macOS and it looks like this to me:
> /Volumes/Case/UDK2018(vUDK2018)>echo $PATH
> /opt/local/bin:/opt/local/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Applications/VMware
> Fusion.app/Contents/Public:/opt/appleinternal/bin:/opt/apple/bin:/opt/X11/bin:/Applications/Araxis\
> Merge.app/Contents/Utilities
> /Volumes/Case/UDK2018(vUDK2018)>. edksetup.sh BaseTools
> WORKSPACE: /Volumes/Case/UDK2018
> EDK_TOOLS_PATH: /Volumes/Case/UDK2018/BaseTools
> CONF_PATH: /Volumes/Case/UDK2018/Conf
> /Volumes/Case/UDK2018(vUDK2018)>echo $PATH
> /Volumes/Case/UDK2018/BaseTools/Bin/Darwin-x86_64:/Volumes/Case/UDK2018/BaseTools/BinWrappers/PosixLike:/opt/local/bin:/opt/local/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Applications/VMware
> Fusion.app/Contents/Public:/opt/appleinternal/bin:/opt/apple/bin:/opt/X11/bin:/Applications/Araxis\
> Merge.app/Contents/Utilities
> /Volumes/Case/UDK2018(vUDK2018)>which build
> /Volumes/Case/UDK2018/BaseTools/BinWrappers/PosixLike/build
> /Volumes/Case/UDK2018(vUDK2018)>cat
> /Volumes/Case/UDK2018/BaseTools/BinWrappers/PosixLike/build
> #!/usr/bin/env bash
> #python `dirname $0`/RunToolFromSource.py `basename $0` $*
>
> # If a python2 command is available, use it in preference to python
> if command -v python2 >/dev/null 2>&1; then
>     python_exe=python2
> fi
>
> full_cmd=${BASH_SOURCE:-$0} # see http://mywiki.wooledge.org/BashFAQ/028 for
> a discussion of why $0 is not a good choice here
> dir=$(dirname "$full_cmd")
> cmd=${full_cmd##*/}
>
> export PYTHONPATH="$dir/../../Source/Python"
> exec "${python_exe:-python}" "$dir/../../Source/Python/$cmd/$cmd.py" "$@"
>
> As you can see sourcing edksetup.sh should update your path to point to a
> location for build. What happens on your system?
>
> Thanks,
>
> Andrew Fish
>
>> Peter
>>
>> Andrew Fish <afish@apple.com <mailto:afish@apple.com>> schrieb am Sa., 24.
>> Nov. 2018 20:45:
>> Run the build command. Conf/target.txt controls the default arguments
>> passed to build.
>>
>> Sourcing edksetup.sh should set your path. Did you miss the “.” or get an
>> error?
>> . edksetup.sh BaseTools
>>
>> Sent from my iPad
>>
>> > On Nov 24, 2018, at 10:03 AM, Peter Wiehe <peter.wiehe2@gmail.com
>> > <mailto:peter.wiehe2@gmail.com>> wrote:
>> >
>> > OK, thanks! Done that.
>> >
>> > But how do I get to build the MdeModulePkg? I did setup as mentioned
>> > in
>> > https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions
>> > <https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions>
>> >
>> > Peter
>> >
>> > 2018-11-24 18:57 GMT+01:00, stephano <stephano.cetola@linux.intel.com
>> > <mailto:stephano.cetola@linux.intel.com>>:
>> >> Hey Peter,
>> >>
>> >> We're still using GCC5 for most of our testing. Try building with that
>> >> release:
>> >>
>> >> apt install gcc-5
>> >>
>> >> Then in Conf/target.txt:
>> >> TOOL_CHAIN_TAG = GCC5
>> >>
>> >> Cheers,
>> >> Stephano
>> >>
>> >>> On 11/24/2018 9:23 AM, Peter Wiehe wrote:
>> >>> OK
>> >>>
>> >>> Building went well to a certain point. I successfully git cloned. I
>> >>> built the BaseTools.
>> >>>
>> >>> I (seemingly successfully) setup the build shell environment. (I got
>> >>> no
>> >>> errors.)
>> >>>
>> >>> In the target conf file I chose "IA32 X64" and ELFGCC (since I habe
>> >>> gcc 7.3.0 installed).
>> >>> When I type "build", there comes an error like "Command build not
>> >>> found".
>> >>>
>> >>> I thought that maybe it's because of the shell environment variable
>> >>> $PATH. $PATH does NOT contain the edk2 source directory in any way
>> >>> (despite the fact that I entered "export EDK_TOOLS_PATH...").
>> >>>
>> >>> What can I do?
>> >>>
>> >>> Greetings
>> >>> Peter
>> >>>
>> >>> 2018-11-24 1:40 GMT+01:00, stephano <stephano.cetola@linux.intel.com
>> >>> <mailto:stephano.cetola@linux.intel.com>>:
>> >>>> Hello Peter,
>> >>>>
>> >>>> Thanks for giving EDK2 a try!
>> >>>>
>> >>>> We have a set of simple instructions for folks building on standard
>> >>>> Linux distros. Please have a look at this page:
>> >>>>
>> >>>> https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions
>> >>>> <https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions>
>> >>>>
>> >>>> Note: Be sure the TARGET_ARCH is set correctly. (E.g. TARGET_ARCH =
>> >>>> x64)
>> >>>>
>> >>>> Once you have built the BaseTools and MdeModulePkg without any
>> >>>> errors,
>> >>>> you can try building and running in OVMF:
>> >>>>
>> >>>> https://github.com/tianocore/tianocore.github.io/wiki/How-to-build-OVMF
>> >>>> <https://github.com/tianocore/tianocore.github.io/wiki/How-to-build-OVMF>
>> >>>>
>> >>>> Tip: Add the -j option so that you can grep through the log easily
>> >>>> for
>> >>>> any errors (build -j /path/to/log/file.txt).
>> >>>>
>> >>>> Hopefully those links help get you started. Let me know if you run
>> >>>> into
>> >>>> any other issues.
>> >>>>
>> >>>> Cheers,
>> >>>> Stephano
>> >>>>
>> >>>> Stephano Cetola
>> >>>> TianoCore Community Manager
>> >>>>
>> >>>>> On 11/23/2018 2:44 PM, Peter Wiehe wrote:
>> >>>>> Hello, I'm a total newbie to Tianocore/EDK2/OVMF.
>> >>>>> (My coding is at high school level I think, not university level. I
>> >>>>> have some (small) experience writing in Assembler, C, C++. I wrote
>> >>>>> a
>> >>>>> little bootloader, so I know something about filesystem in general
>> >>>>> and
>> >>>>> ext2 and pre-kernel "environment".)
>> >>>>>
>> >>>>> I use xubuntu 18.04 on an AMD 64bit PC.
>> >>>>>
>> >>>>> I'm currently trying to
>> >>>>> 1.) build OVMF from source
>> >>>>> 2.) and then want to run it in/with Qemu.
>> >>>>> 3.) Later I would like to try to write a simple ext2 "driver".
>> >>>>> Can't
>> >>>>> guarantee I will succeed, but let's see.
>> >>>>>
>> >>>>> So far I have
>> >>>>> 1.) downloaded the whole edk2 zip/tar-ball
>> >>>>> 2.) have installed nasm and ASL (iasl)
>> >>>>> 3.) Run "EmulatorPkg/build.sh"
>> >>>>> 4.) Run "OvmfPkg/build.sh -a X64"
>> >>>>> 5.) Run "OvmfPkg/build.sh -a X64 qemu"
>> >>>>>
>> >>>>> Then I get the error message "qemu-system-x86_64: -pflash
>> >>>>> /home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin:
>> >>>>> Could not open
>> >>>>> '/home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin':
>> >>>>> No such file or directory"
>> >>>>>
>> >>>>> So my first question is how to deal with this error.
>> >>>>>
>> >>>>> Kind regards
>> >>>>> Peter Wiehe
>> >>>>> _______________________________________________
>> >>>>> edk2-devel mailing list
>> >>>>> edk2-devel@lists.01.org <mailto:edk2-devel@lists.01.org>
>> >>>>> https://lists.01.org/mailman/listinfo/edk2-devel
>> >>>>> <https://lists.01.org/mailman/listinfo/edk2-devel>
>> >>>>>
>> >>>>
>> >>> _______________________________________________
>> >>> edk2-devel mailing list
>> >>> edk2-devel@lists.01.org <mailto:edk2-devel@lists.01.org>
>> >>> https://lists.01.org/mailman/listinfo/edk2-devel
>> >>> <https://lists.01.org/mailman/listinfo/edk2-devel>
>> >>>
>> >>
>> > _______________________________________________
>> > edk2-devel mailing list
>> > edk2-devel@lists.01.org <mailto:edk2-devel@lists.01.org>
>> > https://lists.01.org/mailman/listinfo/edk2-devel
>> > <https://lists.01.org/mailman/listinfo/edk2-devel>
>
>


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Newbie: Getting Ovmf built
  2018-11-24  0:40 ` stephano
  2018-11-24 17:23   ` Peter Wiehe
@ 2018-11-25  5:59   ` Rebecca Cran
  1 sibling, 0 replies; 11+ messages in thread
From: Rebecca Cran @ 2018-11-25  5:59 UTC (permalink / raw)
  To: edk2-devel

On Friday, 23 November 2018 17:40:15 MST stephano wrote:

> We have a set of simple instructions for folks building on standard
> Linux distros. Please have a look at this page:
> 
> https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions
> 
> Note: Be sure the TARGET_ARCH is set correctly. (E.g. TARGET_ARCH = x64)

If you just want to build OVMF, there's a simpler way. After cloning, and 
assuming you're running bash, just:

cd edk2
. ./edksetup.sh
./OvmfPkg/build.sh -a X64 -t GCC5 -b RELEASE

If the build succeeds you'll end up with Build/OvmfX64/RELEASE_GCC5/FV/OVMF.fd 
which is the 'BIOS' image to pass to Qemu, e.g.:

qemu-system-x86_64 -m 4g -drive if=pflash,format=raw,readonly,file=Build/
OvmfX64/RELEASE_GCC5/FV/OVMF.fd \
        -nodefaults \
        -drive format=raw,file=/hda.img -monitor stdio \
        -vga std -sdl -drive format=raw,file=Install.iso

-- 
Rebecca




^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Newbie: Getting Ovmf built
  2018-11-24 17:23   ` Peter Wiehe
  2018-11-24 17:57     ` stephano
@ 2018-11-26 14:09     ` Gao, Liming
  1 sibling, 0 replies; 11+ messages in thread
From: Gao, Liming @ 2018-11-26 14:09 UTC (permalink / raw)
  To: Peter Wiehe, edk2-devel

Do you type ". edksetup.bat BaseTools" in Edk2 directory? What output of this command? This script will add edk2 BaseTools path into system PATH, then build can be used. 

And, you can use GCC5 as the default tool chain. It supports GCC 5.0 or the above version. 

> -----Original Message-----
> From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Peter Wiehe
> Sent: Sunday, November 25, 2018 1:24 AM
> To: edk2-devel <edk2-devel@lists.01.org>
> Subject: Re: [edk2] Newbie: Getting Ovmf built
> 
> OK
> 
> Building went well to a certain point. I successfully git cloned. I
> built the BaseTools.
> 
> I (seemingly successfully) setup the build shell environment. (I got no errors.)
> 
> In the target conf file I chose "IA32 X64" and ELFGCC (since I habe
> gcc 7.3.0 installed).
> When I type "build", there comes an error like "Command build not found".
> 
> I thought that maybe it's because of the shell environment variable
> $PATH. $PATH does NOT contain the edk2 source directory in any way
> (despite the fact that I entered "export EDK_TOOLS_PATH...").
> 
> What can I do?
> 
> Greetings
> Peter
> 
> 2018-11-24 1:40 GMT+01:00, stephano <stephano.cetola@linux.intel.com>:
> > Hello Peter,
> >
> > Thanks for giving EDK2 a try!
> >
> > We have a set of simple instructions for folks building on standard
> > Linux distros. Please have a look at this page:
> >
> > https://github.com/tianocore/tianocore.github.io/wiki/Common-instructions
> >
> > Note: Be sure the TARGET_ARCH is set correctly. (E.g. TARGET_ARCH = x64)
> >
> > Once you have built the BaseTools and MdeModulePkg without any errors,
> > you can try building and running in OVMF:
> >
> > https://github.com/tianocore/tianocore.github.io/wiki/How-to-build-OVMF
> >
> > Tip: Add the -j option so that you can grep through the log easily for
> > any errors (build -j /path/to/log/file.txt).
> >
> > Hopefully those links help get you started. Let me know if you run into
> > any other issues.
> >
> > Cheers,
> > Stephano
> >
> > Stephano Cetola
> > TianoCore Community Manager
> >
> > On 11/23/2018 2:44 PM, Peter Wiehe wrote:
> >> Hello, I'm a total newbie to Tianocore/EDK2/OVMF.
> >> (My coding is at high school level I think, not university level. I
> >> have some (small) experience writing in Assembler, C, C++. I wrote a
> >> little bootloader, so I know something about filesystem in general and
> >> ext2 and pre-kernel "environment".)
> >>
> >> I use xubuntu 18.04 on an AMD 64bit PC.
> >>
> >> I'm currently trying to
> >> 1.) build OVMF from source
> >> 2.) and then want to run it in/with Qemu.
> >> 3.) Later I would like to try to write a simple ext2 "driver". Can't
> >> guarantee I will succeed, but let's see.
> >>
> >> So far I have
> >> 1.) downloaded the whole edk2 zip/tar-ball
> >> 2.) have installed nasm and ASL (iasl)
> >> 3.) Run "EmulatorPkg/build.sh"
> >> 4.) Run "OvmfPkg/build.sh -a X64"
> >> 5.) Run "OvmfPkg/build.sh -a X64 qemu"
> >>
> >> Then I get the error message "qemu-system-x86_64: -pflash
> >> /home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin:
> >> Could not open
> >> '/home/peter/Schreibtisch/edk2-master/Build/OvmfX64/DEBUG_GCC5/QEMU/bios.bin':
> >> No such file or directory"
> >>
> >> So my first question is how to deal with this error.
> >>
> >> Kind regards
> >> Peter Wiehe
> >> _______________________________________________
> >> edk2-devel mailing list
> >> edk2-devel@lists.01.org
> >> https://lists.01.org/mailman/listinfo/edk2-devel
> >>
> >
> _______________________________________________
> edk2-devel mailing list
> edk2-devel@lists.01.org
> https://lists.01.org/mailman/listinfo/edk2-devel


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2018-11-26 14:09 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-11-23 22:44 Newbie: Getting Ovmf built Peter Wiehe
2018-11-24  0:40 ` stephano
2018-11-24 17:23   ` Peter Wiehe
2018-11-24 17:57     ` stephano
2018-11-24 18:03       ` Peter Wiehe
2018-11-24 19:45         ` Andrew Fish
2018-11-24 19:46           ` Peter Wiehe
2018-11-24 20:44             ` Andrew Fish
2018-11-26 14:09     ` Gao, Liming
2018-11-25  5:59   ` Rebecca Cran
  -- strict thread matches above, loose matches on Subject: below --
2018-11-24 21:18 Peter Wiehe

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox