[oe] patcher changes - quilt patching breakage?

cyril Romain c.romain at laposte.net
Wed Aug 30 18:08:46 UTC 2006


Koen Kooi wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Jamie Lenehan schreef:
>   
>> On Tue, Aug 29, 2006 at 09:59:51AM +1000, Jamie Lenehan wrote:
>>     
>>> I've got huge amounts of breakage from quilt due to the patching
>>> related changs. Is anyone else seeing this. It looks like I can't
>>> apply any patches more than one.. which is rather wierd.
>>>       
>> The problem is that my build directory is:
>>
>>  /data/oe/build/titan-glibc-24
>>
>> and I have a directory called:
>>
>>  /data/oe/patches
>>
>> It appears that quilt searches throught he path for a directory
>> called "patches" and uses that for all it's patches. So the patches
>> are being stored in my /data/oe/patches directory instead of in the
>> package itself.
>>
>> The patch command used to mkdir the patches directory, but this is no
>> longer happening. The following patch appears to make things work
>> again - does this look correct to people who understand this patch
>> class?
>>     
>
> That patch isn't quite right yet, consider this recipe:
>
> - --------
> MAINTAINER = "Koen Kooi <koen at linuxtogo.org>"
> PV = ${DISTRO_VERSION}
>
> do_compile() {
>         mkdir -p ${D}${sysconfdir}
>         echo "Angstrom ${DISTRO_VERSION}" > ${D}${sysconfdir}/angstrom-version
>
> }
> - ---------
>
>
> that blows up. Does python have an os.mkdirhier?
>
>   
For that, python has os.makedirs(dir)

*makedirs*( 	path[, mode])

    Recursive directory creation function. Like mkdir(), but makes all
    intermediate-level directories needed to contain the leaf directory.
    Throws an error exception if the leaf directory already exists or
    cannot be created. The default mode is |0777| (octal). On some
    systems, mode is ignored. Where it is used, the current umask value
    is first masked out. *Note:* makedirs() will become confused if the
    path elements to create include os.pardir. New in version 1.5.2.
    Changed in version 2.3: This function now handles UNC paths correctly.

You you may also use bb.mkdirhier(dir)
____
def mkdirhier(dir):
    """Create a directory like 'mkdir -p', but does not complain if
    directory already exists like os.makedirs
    """

    debug(3, "mkdirhier(%s)" % dir)
    try:
        os.makedirs(dir)
        debug(2, "created " + dir)
    except OSError, e:
        if e.errno != 17: raise e
____


Regards,

  Cyril




More information about the Openembedded-devel mailing list