has now been tagged, pushed and built. Images available in:
http://snapshots.linaro.org/components/kernel/linaro-edk2/28
Changes since 2014.09:
- All platforms build successfully.
- QEMU platforms added, both aarch32 and aarch64.
- Some bugfixes in core code.
Known issues:
- The VExpress A9 topic branch was broken, so only the upstream
support was included. This builds correctly, but results in the image
being built in a different directory, so it was not copied into the
release.
arm64:Add multiboot support (via fdt) for Xen boot
- This multiboot support is built into linux module for aarch64.
- The implementation for Xen is following <Multiboot on ARM Specification>:
http://wiki.xen.org/wiki/Xen_ARM_with_Virtualization_Extensions/Multiboot
and xen/docs/misc/arm/device-tree/booting.txt in Xen source code.
- The example of this support is <How to boot Xen with GRUB on AArch64 the Foundation FVP model>
https://wiki.linaro.org/LEG/Engineering/Grub2/Xen_booting_on_Foundation_FVP…
- This adds support for the Xen Multiboot on ARM specification for arm64,
enabling config file portability across the architectures.
- The multiboot command is currently x86-only, so reusing these command names
should not conflict with any future additions of ARM support to multiboot2.
- The reason of adding this functionality to the existing "linux" module
rather than "multiboot(2)"
(1)multiboot is x86 only
(2)Multiboot is added to "linux" module because it reuses existing code.
- Some changes in original linux module code
Move some #define from grub-core/loader/arm64/linux.c to include/grub/arm64/linux.h
Reason: (1)make code more orderly
(2)these #define can be used by other files which includs include/grub/arm64/linux.h
Share some functions and variables for multiboot.c
- Add grub_fdt_set_reg64 macro into fdt.h header file for inserting "reg" properiy,
while #address-cells = <0x2> and #size-cells = <0x2>
This multiboot support will be built in linux module for aarch64,
and can not be used alone.
Signed-off-by: Fu Wei <fu.wei(a)linaro.org>
Hi all,
I managed to build it in the end. My solution is:
Use Python 2.7.2.
Don't use GCC 4.9 14.09 but GCC 4.9 14.07.
It was just a matter of version but I can't understand wy it does not work with 14.09 when on the Linaro Website those vesions are under components/toolchain for the release I want to use which is the 14.09.
Well anyway, thanks for your support.
Regards,
Olivier BRUNEL
-----Original Message-----
From: Olivier Martin [mailto:olivier.martin@arm.com]
Sent: Monday, October 20, 2014 4:33 PM
To: 'Leif Lindholm'; Linaro UEFI; Olivier Brunel
Subject: RE: [Linaro-uefi] Fwd: Building UEFI (14.09)
It's likely to be a python version issue.
I have 'Python 2.6.5' on my Linux distribution.
Leif, I think you add a similar issue once on your system. Maybe you were using Python 3.x.
> -----Original Message-----
> From: linaro-uefi-bounces(a)lists.linaro.org [mailto:linaro-uefi-
> bounces(a)lists.linaro.org] On Behalf Of Leif Lindholm
> Sent: 20 October 2014 16:09
> To: Linaro UEFI; Olivier Brunel
> Subject: [Linaro-uefi] Fwd: Building UEFI (14.09)
>
> Hi Olivier,
>
> Not sure.
> What is your build environment?
>
> And what did you do to be able to build BaseTools?
>
> /
> Leif
>
> ---------- Forwarded message ----------
> From: Olivier Brunel <Olivier.Brunel(a)synopsys.com>
> Date: 17 October 2014 17:11
> Subject: RE: Building UEFI (14.09)
> To: Leif Lindholm <leif.lindholm(a)linaro.org>
>
>
> Hi,
> Well OK now I manage to build using this command:
> make -C BaseTools
>
> Now the problem I have is that it cannot compile Tests. This directory
> is added to SUBDIRS in GNUmakefile under BaseTools and I can't compile
> it.
>
> I am using the tag 'linaro-edk2-2014.09'.
>
> I have traces like:
> FAIL: test_build_build (CheckPythonSyntax.Tests)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
> File "/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-
> base/software/Vanilla-Cortex-Test/uefi-image-linaro-edk2-
> 2014.09/BaseTools/Tests/CheckPythonSyntax.py",
> line 55, in <lambda>
> newmethod = lambda self: self.SingleFileTest(filename)
> File "/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-
> base/software/Vanilla-Cortex-Test/uefi-image-linaro-edk2-
> 2014.09/BaseTools/Tests/CheckPythonSyntax.py",
> line 33, in SingleFileTest
> self.fail('syntax error: %s, Error is %s' % (filename, str(e)))
> AssertionError: syntax error:
> /localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-
> base/software/Vanilla-Cortex-Test/uefi-image-linaro-edk2-
> 2014.09/BaseTools/Source/Python/build/build.py,
> Error is File
> "/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-
> base/software/Vanilla-Cortex-Test/uefi-image-linaro-edk2-
> 2014.09/BaseTools/Source/Python/build/build.py",
> line 677
> class PeImageInfo():
> ^
> SyntaxError: invalid syntax
>
>
> ----------------------------------------------------------------------
> Ran 247 tests in 0.950s
>
> FAILED (failures=37)
> make[1]: Leaving directory
> `/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-
> base/software/Vanilla-Cortex-Test/uefi-image-linaro-edk2-
> 2014.09/BaseTools/Tests'
> make: Leaving directory
> `/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-
> base/software/Vanilla-Cortex-Test/uefi-image-linaro-edk2-
> 2014.09/BaseTools'
> -build/uefi-image> build -a ARM -b DEBUG -t GCC48 -p
> ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA5s.dsc -D
> EDK2_ARMVE_STANDALONE=1
> File "/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-
> base/software/Vanilla-Cortex-Test/uefi-image-linaro-edk2-
> 2014.09/BaseTools/BinWrappers/PosixLike/../../Source/Python/build/buil
> d
> .py",
> line 677
> class PeImageInfo():
> ^
> SyntaxError: invalid syntax
>
> Any idea where this could come from? I have made some research on the
> internet but nothing maybe I miss something...
>
> Thanks,
> Olivier
>
> -----Original Message-----
> From: Leif Lindholm [mailto:leif.lindholm@linaro.org]
> Sent: Thursday, October 16, 2014 5:11 PM
> To: Olivier Brunel
> Subject: Re: Building UEFI (14.09)
>
> Hi Olivier,
>
> Adding linaro-uefi list to cc. Comments inline.
>
> On 16 October 2014 16:03, Olivier Brunel <Olivier.Brunel(a)synopsys.com>
> wrote:
> > Hi there,
> >
> > I have been on this page:
> >
> > https://wiki.linaro.org/LEG/Engineering/Kernel/UEFI/build
> >
> > and tried to build the hard way UEFI:
> >
> > # Get Linaro UEFI sources from git.
> >
> > $ git clone git://git.linaro.org/uefi/linaro-edk2.git
> >
> > $ cd linaro-edk2
> >
> > $ git checkout master
> >
> > # Set up UEFI build environment.
> >
> > $. edksetup.sh
> >
> > $ make -C BaseTools
> >
> >
> >
> > When I try the last line of this $ make -C BaseTools I have the
> > following
> > trace:
> >
> > sh-3.2$ make -C BaseTools/
> >
> > make: Entering directory
> > `/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-
> base/software/Vanilla-Cortex-Test/linaro-edk2/edk2-linaro-edk2-
> 0.1+git26+20140926+9e6f69e/BaseTools'
> >
> > make -C Source/C
> >
> > Attempting to detect ARCH from 'uname -m': x86_64
> >
> > Detected ARCH of X64 using uname.
> >
> > make[1]: Entering directory
> > `/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-
> base/software/Vanilla-Cortex-Test/linaro-edk2/edk2-linaro-edk2-
> 0.1+git26+20140926+9e6f69e/BaseTools/Source/C'
> >
> > mkdir -p .
> >
> > make -C Common
> >
> > make[2]: Entering directory
> > `/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-
> base/software/Vanilla-Cortex-Test/linaro-edk2/edk2-linaro-edk2-
> 0.1+git26+20140926+9e6f69e/BaseTools/Source/C/Common'
> >
> > mkdir ../libs
> >
> > gcc -c -MD -fshort-wchar -fno-strict-aliasing -Wall -Werror
> > -Wno-deprecated-declarations -nostdlib -c -g -I .. -I
> > ../Include/Common -I ../Include/ -I ../Include/IndustryStandard -I
> > ../Common/ -I .. -I . -I ../Include/X64/ BasePeCoff.c -o
> BasePeCoff.o
> >
> > BasePeCoff.c: In function 'PeCoffLoaderGetPeHeader':
> >
> > BasePeCoff.c:149:49: error: cast from pointer to integer of
> > different size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:149:12: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c: In function 'PeCoffLoaderImageAddress':
> >
> > BasePeCoff.c:581:10: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c: In function 'PeCoffLoaderRelocateImage':
> >
> > BasePeCoff.c:647:13: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:700:25: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:709:17: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:715:51: error: cast from pointer to integer of
> > different size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:715:20: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:729:19: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:736:30: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:737:30: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:775:35: error: cast from pointer to integer of
> > different size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:775:35: error: cast from pointer to integer of
> > different size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:775:35: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c: In function 'PeCoffLoaderLoadImage':
> >
> > BasePeCoff.c:942:29: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:945:13: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:950:20: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:963:29: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:966:25: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:968:20: error: cast to pointer from integer of
> > different size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:1006:26: error: cast from pointer to integer of
> different
> > size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:1006:15: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:1007:26: error: cast from pointer to integer of
> different
> > size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:1007:15: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:1063:51: error: cast from pointer to integer of
> different
> > size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:1121:20: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:1144:36: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c: In function 'PeCoffLoaderGetPdbPointer':
> >
> > BasePeCoff.c:1264:43: error: cast from pointer to integer of
> different
> > size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:1264:16: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:1285:60: error: cast from pointer to integer of
> different
> > size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:1285:24: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:1355:24: error: cast from pointer to integer of
> different
> > size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:1354:24: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:1385:37: error: cast from pointer to integer of
> different
> > size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:1384:36: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c: In function 'PeCoffLoaderGetEntryPoint':
> >
> > BasePeCoff.c:1433:43: error: cast from pointer to integer of
> different
> > size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:1433:16: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:1446:20: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:1447:28: error: cast from pointer to integer of
> different
> > size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:1447:19: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:1450:19: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:1452:22: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:1454:22: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > BasePeCoff.c:1456:35: error: cast from pointer to integer of
> different
> > size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:1456:56: error: cast from pointer to integer of
> different
> > size [-Werror=pointer-to-int-cast]
> >
> > BasePeCoff.c:1456:19: error: cast to pointer from integer of
> different
> > size [-Werror=int-to-pointer-cast]
> >
> > cc1: all warnings being treated as errors
> >
> > make[2]: *** [BasePeCoff.o] Error 1
> >
> > make[2]: Leaving directory
> > `/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-
> base/software/Vanilla-Cortex-Test/linaro-edk2/edk2-linaro-edk2-
> 0.1+git26+20140926+9e6f69e/BaseTools/Source/C/Common'
> >
> > make[1]: *** [Common] Error 2
> >
> > make[1]: Leaving directory
> > `/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-
> base/software/Vanilla-Cortex-Test/linaro-edk2/edk2-linaro-edk2-
> 0.1+git26+20140926+9e6f69e/BaseTools/Source/C'
> >
> > make: *** [Source/C] Error 2
> >
> > make: Leaving directory
> > `/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-
> base/software/Vanilla-Cortex-Test/linaro-edk2/edk2-linaro-edk2-
> 0.1+git26+20140926+9e6f69e/BaseTools'
> >
> >
> >
> > I have noticed that you have edited the document last, can you tell
> me
> > if you have had this kind of error as well?
>
> So, I think I might have seen this at some point, but I'm not getting
> it now.
> Could your gcc be defaulting to 32-bit or something?
>
> /
> Leif
>
> _______________________________________________
> Linaro-uefi mailing list
> Linaro-uefi(a)lists.linaro.org
> http://lists.linaro.org/mailman/listinfo/linaro-uefi
I started out tweaking some things for kexec, and then things got out of hand...
Anyway, there is hopefully some stuff here that we will reuse, but I am not
getting my hopes up that this will land upstream unmodified.
The main premise of these patches is that, in order to support kexec, we need
to add code to the kernel that is able to deal with the state of the firmware
after SetVirtualAddressMap() has been called. However, if we are going to deal
with that anyway, why not make that the default state, and have only a single
code path for both cases.
This means SVAM() needs to move to the stub, and hence the code that invents
the layout needs to move with it. The result is that the kernel proper is
entered with the virt_addr members of all EFI_MEMORY_RUNTIME regions assigned,
and the mapping installled in UEFI. The kernel proper needs to set up the page
tables, and switch to them while performing the runtime services calls. Note
that there is also an efi_to_phys() to translate the values of the fw_vendor
and tables fields of the EFI system table. Again, this is something we need
to do anyway under kexec, or we end up handing over state between one kernel
and the next, which implies different code paths between non-kexec and kexec.
One thing that may stand out is the reordering of the memory map. The reason
for doing this is that we can use the same memory map as input to SVAM(). The
alternative is allocating memory for it using boot services, but that clutters
up the existing logic a bit between getting the memory map, populating the fdt,
and loop again if it didn't fit. The current code works perfectly fine, but
I am aware that it is an acquired taste :-)
The first 2 patches are stuff that is missing from Matt Fleming's efi-next
branch, which is what these patches are based on, so I included them for
completeness. The meat is in patch #9, everything before that is groundwork
and/or fixes, after that is dropping stuff that we don't need any longer.
Ard Biesheuvel (9):
arm64/efi: reserve regions of type ACPI_MEMORY_NVS
arm64/efi: drop redundant set_bit(EFI_CONFIG_TABLES)
arm64/efi: use UEFI memory map unconditionally if available
arm64/mm: add explicit struct_mm argument to __create_mapping()
arm64/mm: add create_pgd_mapping() to create private page tables
efi: split off remapping code from efi_config_init()
arm64/efi: move SetVirtualAddressMap() to UEFI stub
arm64/efi: remove free_boot_services() and friends
arm64/efi: remove idmap manipulations from UEFI code
Leif Lindholm (1):
arm64: ignore DT memreserve entries when booting in UEFI mode
Semen Protsenko (1):
efi/arm64: Store Runtime Services revision
arch/arm64/include/asm/efi.h | 23 ++-
arch/arm64/include/asm/mmu.h | 12 +-
arch/arm64/kernel/efi.c | 368 +++++++++++++------------------------
arch/arm64/kernel/setup.c | 2 +-
arch/arm64/mm/init.c | 4 +-
arch/arm64/mm/mmu.c | 57 +++---
drivers/firmware/efi/efi.c | 49 +++--
drivers/firmware/efi/libstub/fdt.c | 110 ++++++++++-
include/linux/efi.h | 2 +
9 files changed, 328 insertions(+), 299 deletions(-)
--
1.8.3.2
From: Semen Protsenko <semen.protsenko(a)linaro.org>
"efi" global data structure contains "runtime_version" field which must
be assigned in order to use it later in Runtime Services virtual calls
(virt_efi_* functions).
Before this patch "runtime_version" was unassigned (0), so each
Runtime Service virtual call that checks revision would fail.
Signed-off-by: Semen Protsenko <semen.protsenko(a)linaro.org>
Acked-by: Ard Biesheuvel <ard.biesheuvel(a)linaro.org>
Cc: <stable(a)vger.kernel.org>
Signed-off-by: Matt Fleming <matt.fleming(a)intel.com>
---
arch/arm64/kernel/efi.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/arch/arm64/kernel/efi.c b/arch/arm64/kernel/efi.c
index 865fdf5c7344..219a59f2ae97 100644
--- a/arch/arm64/kernel/efi.c
+++ b/arch/arm64/kernel/efi.c
@@ -455,6 +455,8 @@ static int __init arm64_enter_virtual_mode(void)
efi_native_runtime_setup();
set_bit(EFI_RUNTIME_SERVICES, &efi.flags);
+ efi.runtime_version = efi.systab->hdr.revision;
+
return 0;
err_unmap:
--
1.8.3.2
Hi Olivier,
Not sure.
What is your build environment?
And what did you do to be able to build BaseTools?
/
Leif
---------- Forwarded message ----------
From: Olivier Brunel <Olivier.Brunel(a)synopsys.com>
Date: 17 October 2014 17:11
Subject: RE: Building UEFI (14.09)
To: Leif Lindholm <leif.lindholm(a)linaro.org>
Hi,
Well OK now I manage to build using this command:
make -C BaseTools
Now the problem I have is that it cannot compile Tests. This directory
is added to SUBDIRS in GNUmakefile under BaseTools and I can't compile
it.
I am using the tag 'linaro-edk2-2014.09'.
I have traces like:
FAIL: test_build_build (CheckPythonSyntax.Tests)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-base/software/Vanilla-Cortex-Test/uefi-image-linaro-edk2-2014.09/BaseTools/Tests/CheckPythonSyntax.py",
line 55, in <lambda>
newmethod = lambda self: self.SingleFileTest(filename)
File "/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-base/software/Vanilla-Cortex-Test/uefi-image-linaro-edk2-2014.09/BaseTools/Tests/CheckPythonSyntax.py",
line 33, in SingleFileTest
self.fail('syntax error: %s, Error is %s' % (filename, str(e)))
AssertionError: syntax error:
/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-base/software/Vanilla-Cortex-Test/uefi-image-linaro-edk2-2014.09/BaseTools/Source/Python/build/build.py,
Error is File
"/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-base/software/Vanilla-Cortex-Test/uefi-image-linaro-edk2-2014.09/BaseTools/Source/Python/build/build.py",
line 677
class PeImageInfo():
^
SyntaxError: invalid syntax
----------------------------------------------------------------------
Ran 247 tests in 0.950s
FAILED (failures=37)
make[1]: Leaving directory
`/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-base/software/Vanilla-Cortex-Test/uefi-image-linaro-edk2-2014.09/BaseTools/Tests'
make: Leaving directory
`/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-base/software/Vanilla-Cortex-Test/uefi-image-linaro-edk2-2014.09/BaseTools'
-build/uefi-image> build -a ARM -b DEBUG -t GCC48 -p
ArmPlatformPkg/ArmVExpressPkg/ArmVExpress-CTA5s.dsc -D
EDK2_ARMVE_STANDALONE=1
File "/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-base/software/Vanilla-Cortex-Test/uefi-image-linaro-edk2-2014.09/BaseTools/BinWrappers/PosixLike/../../Source/Python/build/build.py",
line 677
class PeImageInfo():
^
SyntaxError: invalid syntax
Any idea where this could come from? I have made some research on the
internet but nothing maybe I miss something...
Thanks,
Olivier
-----Original Message-----
From: Leif Lindholm [mailto:leif.lindholm@linaro.org]
Sent: Thursday, October 16, 2014 5:11 PM
To: Olivier Brunel
Subject: Re: Building UEFI (14.09)
Hi Olivier,
Adding linaro-uefi list to cc. Comments inline.
On 16 October 2014 16:03, Olivier Brunel <Olivier.Brunel(a)synopsys.com> wrote:
> Hi there,
>
> I have been on this page:
>
> https://wiki.linaro.org/LEG/Engineering/Kernel/UEFI/build
>
> and tried to build the hard way UEFI:
>
> # Get Linaro UEFI sources from git.
>
> $ git clone git://git.linaro.org/uefi/linaro-edk2.git
>
> $ cd linaro-edk2
>
> $ git checkout master
>
> # Set up UEFI build environment.
>
> $. edksetup.sh
>
> $ make -C BaseTools
>
>
>
> When I try the last line of this $ make -C BaseTools I have the
> following
> trace:
>
> sh-3.2$ make -C BaseTools/
>
> make: Entering directory
> `/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-base/software/Vanilla-Cortex-Test/linaro-edk2/edk2-linaro-edk2-0.1+git26+20140926+9e6f69e/BaseTools'
>
> make -C Source/C
>
> Attempting to detect ARCH from 'uname -m': x86_64
>
> Detected ARCH of X64 using uname.
>
> make[1]: Entering directory
> `/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-base/software/Vanilla-Cortex-Test/linaro-edk2/edk2-linaro-edk2-0.1+git26+20140926+9e6f69e/BaseTools/Source/C'
>
> mkdir -p .
>
> make -C Common
>
> make[2]: Entering directory
> `/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-base/software/Vanilla-Cortex-Test/linaro-edk2/edk2-linaro-edk2-0.1+git26+20140926+9e6f69e/BaseTools/Source/C/Common'
>
> mkdir ../libs
>
> gcc -c -MD -fshort-wchar -fno-strict-aliasing -Wall -Werror
> -Wno-deprecated-declarations -nostdlib -c -g -I .. -I
> ../Include/Common -I ../Include/ -I ../Include/IndustryStandard -I
> ../Common/ -I .. -I . -I ../Include/X64/ BasePeCoff.c -o BasePeCoff.o
>
> BasePeCoff.c: In function 'PeCoffLoaderGetPeHeader':
>
> BasePeCoff.c:149:49: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:149:12: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c: In function 'PeCoffLoaderImageAddress':
>
> BasePeCoff.c:581:10: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c: In function 'PeCoffLoaderRelocateImage':
>
> BasePeCoff.c:647:13: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:700:25: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:709:17: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:715:51: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:715:20: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:729:19: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:736:30: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:737:30: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:775:35: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:775:35: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:775:35: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c: In function 'PeCoffLoaderLoadImage':
>
> BasePeCoff.c:942:29: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:945:13: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:950:20: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:963:29: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:966:25: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:968:20: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:1006:26: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:1006:15: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:1007:26: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:1007:15: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:1063:51: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:1121:20: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:1144:36: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c: In function 'PeCoffLoaderGetPdbPointer':
>
> BasePeCoff.c:1264:43: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:1264:16: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:1285:60: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:1285:24: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:1355:24: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:1354:24: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:1385:37: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:1384:36: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c: In function 'PeCoffLoaderGetEntryPoint':
>
> BasePeCoff.c:1433:43: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:1433:16: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:1446:20: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:1447:28: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:1447:19: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:1450:19: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:1452:22: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:1454:22: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> BasePeCoff.c:1456:35: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:1456:56: error: cast from pointer to integer of different
> size [-Werror=pointer-to-int-cast]
>
> BasePeCoff.c:1456:19: error: cast to pointer from integer of different
> size [-Werror=int-to-pointer-cast]
>
> cc1: all warnings being treated as errors
>
> make[2]: *** [BasePeCoff.o] Error 1
>
> make[2]: Leaving directory
> `/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-base/software/Vanilla-Cortex-Test/linaro-edk2/edk2-linaro-edk2-0.1+git26+20140926+9e6f69e/BaseTools/Source/C/Common'
>
> make[1]: *** [Common] Error 2
>
> make[1]: Leaving directory
> `/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-base/software/Vanilla-Cortex-Test/linaro-edk2/edk2-linaro-edk2-0.1+git26+20140926+9e6f69e/BaseTools/Source/C'
>
> make: *** [Source/C] Error 2
>
> make: Leaving directory
> `/localdev/obrunel/obrunel_armvdk_stormcs315/j-liv-arm-base/software/Vanilla-Cortex-Test/linaro-edk2/edk2-linaro-edk2-0.1+git26+20140926+9e6f69e/BaseTools'
>
>
>
> I have noticed that you have edited the document last, can you tell me
> if you have had this kind of error as well?
So, I think I might have seen this at some point, but I'm not getting it now.
Could your gcc be defaulting to 32-bit or something?
/
Leif