Re: [edk2] using PCDs in ASL, try 2 [was: QEMU debug port]

Subject: Re: [edk2] using PCDs in ASL, try 2 [was: QEMU debug port]

From: Ifan Llwyd <>

To: Laszlo Ersek <>, "" <>

Date: 2012-07-31 21:57:03

Hi Laszlo.
I've been looking at
It has interesting code to strip out some struct stuff from preprocessed fi=
les, and modify Hex numbers, etc.
Unfortunately, this is not currently done for .ASL, or would be wrong were =
it done (via options).

I assume the tool is intended for this sort of thing, but has not got the f=
unctionality we would like yet.
I'm told=A0there is a seperate mailing group for edk2 tools, but I can't fi=
nd it via SourceForge.
I assume you could suggest changes, or even submit patches to get Trim to d=
o what you need.

I'd quite like to do that myself, but I'm caught up in other things right n=

One thing you could try is to=A0have the .ASL in its own directory with its=
 own .INF file, so only the required PCDs appear in AutoGen.h.


PS: I top posted to save everyone the nause of reading the back story, 'cos=
 I'm considerate.=A0 :-)
=A0=A0=A0=A0=A0 =

----- Original Message -----
From: Laszlo Ersek 
Cc: Jordan Justen ; Paolo Bonzini =
Sent: Tuesday, 31 July 2012, 13:22
Subject: Re: [edk2] using PCDs in ASL, try 2 [was: QEMU debug port]

On 07/30/12 12:16, Laszlo Ersek wrote:

> I tried to do it after consulting
>  again
> (kudos Ifan); please see the first patch. The build failed.
> =

> I figured perhaps including AutoGen.h would help (second patch). It didn'=

"BaseTools/Conf/tools_def.template" defines

DEFINE MSFT_ASLPP_FLAGS=A0 =A0 =A0 =A0 =3D /nologo /E /C /FIAutoGen.h
DEFINE ICC_WIN_ASLPP_FLAGS=A0 =A0 =3D /nologo /E /C /FIAutoGen.h
DEFINE GCC_ASLPP_FLAGS=A0 =A0 =A0 =A0 =A0 =A0 =3D -x c -E -P

If I add "-include AutoGen.h" to GCC_ASLPP_FLAGS (also in
"Conf/tools_def.txt"), then I don't have to #include the header
manually, but the resultant source fails the same to compile with iasl.


Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and =

threat landscape has changed and how IT managers can respond. Discussions =

will include endpoint security, mobile security and the latest in malware =

edk2-devel mailing list