[edk2] Reply: compiled UnixPkg with Ubuntu 11.10

Subject: [edk2] Reply: compiled UnixPkg with Ubuntu 11.10

From: <TigerLiu@viatech.com.cn>

To: <edk2-devel@lists.sourceforge.net>

Date: 2011-11-17 03:26:24

Hi, Jordan:
I tried to revise tools_def.txt , and added GCC46 definition, but still failed .
The error message is listed as below:
Initializing workspace
/home/tigerliu/tiger-edk2/edk2/BaseTools
Loading previous configuration from $WORKSPACE/Conf/BuildEnv.sh
WORKSPACE: /home/tigerliu/tiger-edk2/edk2
EDK_TOOLS_PATH: /home/tigerliu/tiger-edk2/edk2/BaseTools
using prebuilt tools
19:18:54, Nov.16 2011 [Linux-3.0.0-12-generic-x86_64-with-Ubuntu-11.10-oneiric]

WORKSPACE                = /home/tigerliu/tiger-edk2/edk2
ECP_SOURCE               = /home/tigerliu/tiger-edk2/edk2/EdkCompatibilityPkg
EDK_SOURCE               = /home/tigerliu/tiger-edk2/edk2/EdkCompatibilityPkg
EFI_SOURCE               = /home/tigerliu/tiger-edk2/edk2/EdkCompatibilityPkg
EDK_TOOLS_PATH           = /home/tigerliu/tiger-edk2/edk2/BaseTools

TARGET_ARCH              = X64
TARGET                   = DEBUG
TOOL_CHAIN_TAG           = GCC46

Active Platform          = /home/tigerliu/tiger-edk2/edk2/EmulatorPkg/EmulatorPkg.dsc
Flash Image Definition   = /home/tigerliu/tiger-edk2/edk2/EmulatorPkg/EmulatorPkg.fdf

Processing meta-data ..... done!
Building ... /home/tigerliu/tiger-edk2/edk2/MdePkg/Library/BaseLib/BaseLib.inf [X64]
Building ... /home/tigerliu/tiger-edk2/edk2/MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf [X64]
Building ... /home/tigerliu/tiger-edk2/edk2/MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf [X64]
"cc"  -o /home/tigerliu/tiger-edk2/edk2/Build/Emulator/DEBUG_GCC46/X64/MdePkg/Library/BaseLib/BaseLib/OUTPUT/./CheckSum.obj ......
/home/tigerliu/tiger-edk2/edk2/MdePkg/Library/BasePcdLibNull/PcdLib.c
/usr/lib/gcc/x86_64-linux-gnu/4.6.1/../../../x86_64-linux-gnu/crt1.o: In function `_start':
(.text+0x20): undefined reference to `main'
collect2: ld returned 1 exit status
make: *** [/home/tigerliu/tiger-edk2/edk2/Build/Emulator/DEBUG_GCC46/X64/MdePkg/Library/BaseMemoryLib/BaseMemoryLib/OUTPUT/SetMem.obj] Error 1


build.py...
 : error 7000: Failed to execute command
	make tbuild [/home/tigerliu/tiger-edk2/edk2/Build/Emulator/DEBUG_GCC46/X64/MdePkg/Library/BaseMemoryLib/BaseMemoryLib]


build.py...
 : error 7000: Failed to execute command
	make tbuild [/home/tigerliu/tiger-edk2/edk2/Build/Emulator/DEBUG_GCC46/X64/MdePkg/Library/BaseLib/BaseLib]


build.py...
 : error 7000: Failed to execute command
	make tbuild [/home/tigerliu/tiger-edk2/edk2/Build/Emulator/DEBUG_GCC46/X64/MdePkg/Library/BasePcdLibNull/BasePcdLibNull]


build.py...
 : error 7000: Failed to execute command
	make tbuild [/home/tigerliu/tiger-edk2/edk2/Build/Emulator/DEBUG_GCC46/X64/MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull]


build.py...
 : error F002: Failed to build module
	/home/tigerliu/tiger-edk2/edk2/MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf [X64, GCC46, DEBUG]

- Failed -
19:19:01, Nov.16 2011 [00:07]

Best wishes,
----------
: Jordan Justen [mailto:jljusten@gmail.com] 
: 20111116 15:45
: edk2-devel@lists.sourceforge.net
: Re: [edk2] : Reply: compiled UnixPkg with Ubuntu 11.10

2011/11/15  :
> I compiled EmulatorPkg with GCC44.
> "Gcc -v" displays:
> Gcc version 4.4.6

Did you use EmulatorPkg/build.sh to build?  If you just build with the
edk2 'build' command, it will not not create the Host program.

It should just require these two commands if all the prerequisites are
installed:
$ EmulatorPkg/build.sh
$ EmulatorPkg/build.sh run

The first will build everything, and the second will run it.

I think it should work with GCC 4.4, like you are using, but I tested
this most recently on 11.10 with GCC 4.6.  (After adding the GCC46
toolchain to tools_def.txt.)

-Jordan

------------------------------------------------------------------------------
RSA(R) Conference 2012
Save $700 by Nov 18
Register now
http://p.sf.net/sfu/rsa-sfdev2dev1
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel

------------------------------------------------------------------------------
RSA(R) Conference 2012
Save $700 by Nov 18
Register now
http://p.sf.net/sfu/rsa-sfdev2dev1
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel