ltib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Ltib] Special tag localdir_nobuild causes LTIB to go to the confi


From: Peter Barada
Subject: Re: [Ltib] Special tag localdir_nobuild causes LTIB to go to the config screen.
Date: Fri, 30 Oct 2009 00:21:15 -0400

On Thu, 2009-10-29 at 15:46 -0500, address@hidden wrote:
Hi Stuart.

I can understand why the configuration thing is a one-shot, but I don't
understand the source thing all that well.  I'm trying to think of a
situation in which having the LEAVESRC variable as a one-shot would be
useful.  Also, I don't understand why the kernel has this option, and
possibly the boot loader, but not the other packages.  I guess I just
don't understand how this variable is applied.  It's much easier for me to
think about the configuration as a one-shot.  You want to configure the
kernel, add a driver, and build.  The next time you run `ltib` you do it
because you want to add the tcpdump package to your target image, but you
don't want to reconfigure the kernel this time.  Maybe in trying to
understand the LEAVESRC variable I'm overlooking some way of developing
using the LTIB where this could be a shortcut.

One to thik about is a seperate package that builds a kernel module (like PKG_HELLO_WORLD_MOD).  It needs the kernel source to remain so it can use the kernel build structure/headers to create a module that is loadable by the kernel....

Actually, when I started working with the LTIB I was hoping it would have
a flag to keep the sources for all of the target packages unpacked.  I
guess you can do it on an individual package basis with the --leavesrc
option...or does that work for all packages?  I tried it here and it
seemed to leave some packages unpacked (busybox, ncurses, zlib, etc.),
while getting rid of others (termcap).  I deleted the .rpm files to force
it to rebuild multiple packages.

The patch to fix the two main.lkc files is attached.


Thanks for all your help,

Aaron

> Hi Aaron,
>
> Yes, any config symbols *WANT_CF and *LEAVESRC are transient one-shots.
>
> 'Leave the sources after building' is a one-shot option (like 'Configure
> the kernel').  The main reason is because otherwise manually turning it
> off would be detected as a config change and cause the kernel package to
> try to rebuild.  This does not mean the kernel source will be removed.
> As always, once source is blown out, the only way to remove it is
> manually (with rm), this is intentional.
>
> You are right that PKG_KERNEL_WANT_CF should not be selected by
> LEAVESRC.  Please send a patch.
>
> Regards, Stuart
>
>
> address@hidden wrote:
>> Hi Stuart.  Actually, your previous attempt to fix this by avoiding the
>> call to `./ltib -m clean` in the case of localdir_nobuild in the
>> bin/Ltibrelease.pm script was necessary as well.  The way it was before
>> caused my config/platform/mpc8349itx/.config file to be copied to
>> config/platform/mpc8349itx/.config.bak, and the new .config file had
>>
>> # CONFIG_PKG_KERNEL_LEAVESRC is not set
>>
>> instead of
>>
>> CONFIG_PKG_KERNEL_LEAVESRC=y
>>
>> Without your fix my "localdir_nobuild" iso test release wouldn't have
>> worked right because my kernel module package expects that the kernel
>> source is unpacked in the BUILD directory so that it can utilize its
>> kbuild infrastructure.  So, I needed that part of the fix too.  It
>> appears
>> that this CONFIG_PKG_KERNEL_LEAVESRC variable gets cleared every time
>> you
>> run the LTIB.  Is this correct?  Why does the variable get cleared every
>> time?
>>
>> Also, I think I've found one more bug.  In most of the
>> config/platform/%{ARHC}/main.lkc files, selecting
>> CONFIG_PKG_KERNEL_LEAVESRC does not imply selecting PKG_KERNEL_WANT_CF.
>> However, for the platforms mpc8349itx and ep93xx the main.lkc files look
>> like:
>>
>> config PKG_KERNEL_LEAVESRC
>>     depends ! KERNEL_NONE
>>     select PKG_KERNEL_WANT_CF
>>     bool "Leave the sources after building"
>>     default n
>>     help
>>       This is a one shot option that can be used to build the kernel and
>>       leave the build source tree in rpm/BUILD in place
>>
>> I think the line "select PKG_KERNEL_WANT_CF" should be removed for
>> correct
>> functionality and to match the majority of the other main.lkc files.
>>
>>
>> Thanks,
>>
>> Aaron
>>
>>> Hi Aaron,
>>>
>>> Agreed, after looking into this I'm going the change you suggest.
>>>
>>> Regards, Stuart
>>>
>>>
>>> address@hidden wrote:
>>>> The platform I'm using is mpc8349itx.  If I remove the file
>>>>
>>>> config/platform/mpc8349itx/.config
>>>>
>>>> then typing `./ltib` drops me to the configuration menu
>>>>
>>>> "LTIB: Freescale MPC8349E-mITX board"
>>>>
>>>> If I have the config file, `./ltib` proceeds with the build without
>>>> going
>>>> to the configuration menu.
>>>>
>>>> At first glance it seems like the config file you say should not be
>>>> created needs to be present to avoid the menu.  The patch I submitted
>>>> was
>>>> working for the localdir_nobuild special tag when applied to CVS
>>>> revision
>>>> 1.5 of bin/Ltibrelease.pm.
>>>>
>>>> Aaron
>>>>
>>>>> Hi Aaron,
>>>>>
>>>>> Please keep messages on the list.
>>>>>
>>>>> I agree that a platform should be pre-chosen, so the top level
>>>>> .config
>>>>> should be there.  I'll look at fixing this, but not sure when (feel
>>>>> free
>>>>> to submit another patch).  The reason your patch is not quite right
>>>>> is
>>>>> that the platform config should not be created (the one in
>>>>> config/platform/_target_).
>>>>>
>>>>> Regards, Stuart
>>>>>
>>>>> address@hidden wrote:
>>>>>> Hi Stuart, how's everything?
>>>>>>
>>>>>> I think I liked the old way or my modified version better, because
>>>>>> at
>>>>>> least I would have an iso that I could mount, run `install`, change
>>>>>> directory to non-distributable-*, then run `ltib` to build the
>>>>>> entire
>>>>>> release.
>>>>>>
>>>>>> With your newest modifications the iso is bundled without a .config
>>>>>> in
>>>>>> the
>>>>>> base non-distributable-* directory, and running `ltib` only builds
>>>>>> the
>>>>>> host packages, then drops me to the configuration menu.  This is
>>>>>> less
>>>>>> like
>>>>>> a BSP, because it's not specific to my platform, and more like the
>>>>>> LTIB
>>>>>> itself, which can be used for lots of platforms.  I don't think the
>>>>>> configuration menu should be invoked at all, either in producing the
>>>>>> iso
>>>>>> with the localdir_nobuild tag, or when installing the BSP from the
>>>>>> iso
>>>>>> onto another machine.
>>>>>>
>>>>>> Thanks,
>>>>>>
>>>>>> Aaron
>>>>>>
>>>>>>> Hi Aaron,
>>>>>>>
>>>>>>> That's not quite right, you don't want to do any building for
>>>>>>> "localdir_nobuild".  I've checked in a fix that I think addresses
>>>>>>> this.
>>>>>>>
>>>>>>> Regards, Stuart
>>>>>>>
>>>>>>> address@hidden wrote:
>>>>>>>> I would recommend the patch following the diff command for the
>>>>>>>> test
>>>>>>>> release mode with the localdir_nobuild tag.  Instead of dropping
>>>>>>>> the
>>>>>>>> user
>>>>>>>> to the configure screen, the LTIB should be using the preconfig
>>>>>>>> file
>>>>>>>> config/platform/${ARCH}/defconfig to produce the test release iso
>>>>>>>> file.
>>>>>>>>
>>>>>>>>
>>>>>>>> $ diff -aur Ltibrelease.pm Ltibrelease.pm.noconfigscr
>>>>>>>> --- Ltibrelease.pm	2009-10-26 14:15:37.898242755 -0400
>>>>>>>> +++ Ltibrelease.pm.noconfigscr	2009-10-26 14:17:03.037301396 -0400
>>>>>>>> @@ -399,6 +399,8 @@
>>>>>>>>  if [  "$tag" != "localdir_nobuild" ]
>>>>>>>>  then
>>>>>>>>      ./ltib --preconfig $cf->{plat_dir} --configure --batch
>>>>>>>> +else
>>>>>>>> +    ./ltib --preconfig $cf->{plat_dir} -m config --batch
>>>>>>>>  fi
>>>>>>>>
>>>>>>>>  # copy the pre-built images if any to the iso so usable without
>>>>>>>> ltib
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> _______________________________________________
>>>>>>>> LTIB home page: http://ltib.org
>>>>>>>>
>>>>>>>> Ltib mailing list
>>>>>>>> address@hidden
>>>>>>>> http://lists.nongnu.org/mailman/listinfo/ltib
>>>>>>>>
>>>>>>
>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> LTIB home page: http://ltib.org
>>>>
>>>> Ltib mailing list
>>>> address@hidden
>>>> http://lists.nongnu.org/mailman/listinfo/ltib
>>>>
>>
>>
>>
>>
>> _______________________________________________
>> LTIB home page: http://ltib.org
>>
>> Ltib mailing list
>> address@hidden
>> http://lists.nongnu.org/mailman/listinfo/ltib
>>
>
_______________________________________________
LTIB home page: http://ltib.org

Ltib mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/ltib
--
Peter Barada <address@hidden>
Logic Product Development, Inc.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]