FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Fedora Development

 
 
LinkBack Thread Tools
 
Old 06-07-2011, 02:23 PM
Martin Langhoff
 
Default Trivial macro not expanded in kernel spec file %build

I am hacking on a slighly modified kernel spec file for an OLPC arm
test kernel. While chasing strange build errors, I find that
%{image_install_path} isn't always being expanded.

The resulting build script looks like

http://fpaste.org/LQwR/#82

where %{image_install_path}, defined earlier as 'boot' hasn't been expanded.

Any debugging hints?


m
--
*martin.langhoff@gmail.com
*martin@laptop.org -- Software Architect - OLPC
*- ask interesting questions
*- don't get distracted with shiny stuff* - working code first
*- http://wiki.laptop.org/go/User:Martinlanghoff
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 06-07-2011, 03:46 PM
Panu Matilainen
 
Default Trivial macro not expanded in kernel spec file %build

On 06/07/2011 05:23 PM, Martin Langhoff wrote:
> I am hacking on a slighly modified kernel spec file for an OLPC arm
> test kernel. While chasing strange build errors, I find that
> %{image_install_path} isn't always being expanded.
>
> The resulting build script looks like
>
> http://fpaste.org/LQwR/#82
>
> where %{image_install_path}, defined earlier as 'boot' hasn't been expanded.
>
> Any debugging hints?

Hard to say without the entire spec, but one typical cause of "sometimes
works sometimes doesn't" issues with macros are %define's inside macro
{} blocks, which "work" until the first parametrized macro is called,
and after that it doesn't (due to an ancient flaw in the macro engine).
Replacing the %define inside {} with %global helps in this case.

Another possibility that comes to mind is funny side-effects from
BuildArch which can cause similar effects, but this time use of %global
being the problem: https://bugzilla.redhat.com/show_bug.cgi?id=593363

- Panu -
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 
Old 06-07-2011, 08:14 PM
Martin Langhoff
 
Default Trivial macro not expanded in kernel spec file %build

On Tue, Jun 7, 2011 at 11:46 AM, Panu Matilainen
<pmatilai@laiskiainen.org> wrote:
> Hard to say without the entire spec, but one typical cause of "sometimes
> works sometimes doesn't" issues with macros are %define's inside macro
> {} blocks, which "work" until the first parametrized macro is called,
> and after that it doesn't (due to an ancient flaw in the macro engine).
> Replacing the %define inside {} with %global helps in this case.

Ouch! that sounds extra painful.

After a few more attempts I found that the macro was being initialized
per arch, and my arch wasn't setting it properly.

Didn't spot any 'undefined macro' warning in the output, but then
again I only tried with one '-v' param.

thanks!



m
--
*martin.langhoff@gmail.com
*martin@laptop.org -- Software Architect - OLPC
*- ask interesting questions
*- don't get distracted with shiny stuff* - working code first
*- http://wiki.laptop.org/go/User:Martinlanghoff
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
 

Thread Tools




All times are GMT. The time now is 06:41 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org