All of lore.kernel.org
 help / color / mirror / Atom feed
* patcher changes - quilt patching breakage?
@ 2006-08-28 23:59 Jamie Lenehan
  2006-08-29  0:41 ` Jamie Lenehan
  0 siblings, 1 reply; 5+ messages in thread
From: Jamie Lenehan @ 2006-08-28 23:59 UTC (permalink / raw)
  To: openembedded-devel

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.

Example:

[nynaeve][ 9:41AM]/data/oe/build/titan-glibc-24%> ./bb -b packages/iputils/iputils_20020927.bb
NOTE: package iputils-20020927: started
NOTE: package iputils-20020927-r4: task do_fetch: started
NOTE: package iputils-20020927-r4: task do_fetch: completed
Updating /data/oe/build/titan-glibc-24/tmp/stamps/iputils-20020927-r4.do_fetch
NOTE: package iputils-20020927-r4: task do_unpack: started
NOTE: Unpacking /data/oe/sources/iputils-ss020927.tar.gz to /data/oe/build/titan-glibc-24/tmp/work/iputils-20020927-r4/
NOTE: package iputils-20020927-r4: task do_unpack: completed
Updating /data/oe/build/titan-glibc-24/tmp/stamps/iputils-20020927-r4.do_unpack
NOTE: package iputils-20020927-r4: task do_patch: started
NOTE: Applying patch 'debian-fixes.patch'
ERROR: Error in executing: /data/oe/build/titan-glibc-24/packages/iputils/iputils_20020927.bb
ERROR: Exception:exceptions.IOError Message:[Errno 2] No such file or directory: '/data/oe/build/titan-glibc-24/tmp/work/iputils-20020927-r4/iputils/patches/debian-fixes.patch'
ERROR: Printing the environment of the function
ERROR:  0003:   import bb.fetch
ERROR:  0004:
ERROR:  0005:   patch_init(d)
ERROR:  0006:
ERROR:  0007:   src_uri = (bb.data.getVar('SRC_URI', d, 1) or '').split()
ERROR:  0008:   if not src_uri:
ERROR:  0009:           return
ERROR:  0010:
ERROR:  0011:   patchsetmap = {
ERROR: Error in executing: /data/oe/build/titan-glibc-24/packages/iputils/iputils_20020927.bb
ERROR: Exception:exceptions.IOError Message:[Errno 2] No such file or directory: '/data/oe/build/titan-glibc-24/tmp/work/iputils-20020927-r4/iputils/patches/debian-fixes.patch'
ERROR: Printing the environment of the function
ERROR:  0003:
ERROR: Error in executing: /data/oe/build/titan-glibc-24/packages/iputils/iputils_20020927.bb
ERROR: Exception:exceptions.IOError Message:[Errno 2] No such file or directory: '/data/oe/build/titan-glibc-24/tmp/work/iputils-20020927-r4/iputils/patches/debian-fixes.patch'
ERROR: Printing the environment of the function
ERROR:  0003:
Traceback (most recent call last):
  File "/data/oe/src/bitbake/latest/bin/bitbake", line 1161, in ?
    main()
  File "/data/oe/src/bitbake/latest/bin/bitbake", line 1156, in main
    cooker.cook( BBConfiguration( options ), args[1:] )
  File "/data/oe/src/bitbake/latest/bin/bitbake", line 899, in cook
    self.tryBuildPackage( bf, item, bbfile_data )
  File "/data/oe/src/bitbake/latest/bin/bitbake", line 233, in tryBuildPackage
    bb.build.exec_task('do_%s' % self.configuration.cmd, the_data)
  File "/data/oe/src/bitbake/bitbake-1.6.0/lib/bb/build.py", line 285, in exec_task
    task_graph.walkdown(task, execute)
  File "/usr/lib64/python2.4/site-packages/PIL/__init__.py", line 1193, in walkdown

  File "/usr/lib64/python2.4/site-packages/PIL/__init__.py", line 1193, in walkdown

  File "/usr/lib64/python2.4/site-packages/PIL/__init__.py", line 1193, in walkdown

  File "/usr/lib64/python2.4/site-packages/PIL/__init__.py", line 1193, in walkdown

  File "/usr/lib64/python2.4/site-packages/PIL/__init__.py", line 1193, in walkdown

  File "/usr/lib64/python2.4/site-packages/PIL/__init__.py", line 1193, in walkdown

  File "/usr/lib64/python2.4/site-packages/PIL/__init__.py", line 1198, in walkdown

  File "/data/oe/src/bitbake/bitbake-1.6.0/lib/bb/build.py", line 264, in execute
    exec_task(item, d)
  File "/data/oe/src/bitbake/bitbake-1.6.0/lib/bb/build.py", line 285, in exec_task
    task_graph.walkdown(task, execute)
  File "/usr/lib64/python2.4/site-packages/PIL/__init__.py", line 1198, in walkdown

  File "/data/oe/src/bitbake/bitbake-1.6.0/lib/bb/build.py", line 274, in execute
    exec_func(item, localdata)
  File "/data/oe/src/bitbake/bitbake-1.6.0/lib/bb/build.py", line 98, in exec_func
    exec_func_python(func, d)
  File "/data/oe/src/bitbake/bitbake-1.6.0/lib/bb/build.py", line 117, in exec_func_python
    utils.better_exec(comp,g,tmp, bb.data.getVar('FILE',d,1))
  File "./lib/bb/utils.py", line 142, in better_exec
  File "do_patch", line 4, in ?
  File "do_patch", line 2, in do_patch
  File "/data/oe/src/bitbake/bitbake-1.6.0/lib/bb/build.py", line 98, in exec_func
    exec_func_python(func, d)
  File "/data/oe/src/bitbake/bitbake-1.6.0/lib/bb/build.py", line 117, in exec_func_python
    utils.better_exec(comp,g,tmp, bb.data.getVar('FILE',d,1))
  File "./lib/bb/utils.py", line 142, in better_exec
  File "base_do_patch", line 4, in ?
  File "base_do_patch", line 2, in base_do_patch
  File "/data/oe/src/bitbake/bitbake-1.6.0/lib/bb/build.py", line 98, in exec_func
    exec_func_python(func, d)
  File "/data/oe/src/bitbake/bitbake-1.6.0/lib/bb/build.py", line 117, in exec_func_python
    utils.better_exec(comp,g,tmp, bb.data.getVar('FILE',d,1))
  File "./lib/bb/utils.py", line 142, in better_exec
  File "patch_do_patch", line 97, in ?
  File "patch_do_patch", line 91, in patch_do_patch
  File "<bb>", line 230, in Import
  File "<bb>", line 7, in md5sum
IOError: [Errno 2] No such file or directory: '/data/oe/build/titan-glibc-24/tmp/work/iputils-20020927-r4/iputils/patches/debian-fixes.patch'
[nynaeve][ 9:41AM]/data/oe/build/titan-glibc-24%>

-- 
 Jamie Lenehan <lenehan@twibble.org>



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: patcher changes - quilt patching breakage?
  2006-08-28 23:59 patcher changes - quilt patching breakage? Jamie Lenehan
@ 2006-08-29  0:41 ` Jamie Lenehan
  2006-08-30  8:21   ` Koen Kooi
  0 siblings, 1 reply; 5+ messages in thread
From: Jamie Lenehan @ 2006-08-29  0:41 UTC (permalink / raw)
  To: openembedded-devel

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?

#
# old_revision [14917049ca38865d541726340df4e735749d9fc9]
#
# patch "classes/patch.bbclass"
#  from [06bfa04274235a178643633deba99054024b741c]
#    to [43a7cdac0d459f62c68c6d258f001d3b06688906]
#
============================================================
--- classes/patch.bbclass       06bfa04274235a178643633deba99054024b741c
+++ classes/patch.bbclass       43a7cdac0d459f62c68c6d258f001d3b06688906
@@ -174,6 +174,9 @@ def patch_init(d):
                def __init__(self, dir, d):
                        PatchSet.__init__(self, dir, d)
                        self.initialized = False
+                       p = os.path.join(self.dir, 'patches')
+                       if not os.path.exists(p):
+                               os.mkdir(p)

                def Clean(self):
                        try:

-- 
 Jamie Lenehan <lenehan@twibble.org>



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: patcher changes - quilt patching breakage?
  2006-08-29  0:41 ` Jamie Lenehan
@ 2006-08-30  8:21   ` Koen Kooi
  2006-08-30 18:08     ` cyril Romain
  2006-09-01  1:43     ` Jamie Lenehan
  0 siblings, 2 replies; 5+ messages in thread
From: Koen Kooi @ 2006-08-30  8:21 UTC (permalink / raw)
  To: Using the OpenEmbedded metadata to build Linux Distributions

-----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@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?

regards,

Koen




> 
> #
> # old_revision [14917049ca38865d541726340df4e735749d9fc9]
> #
> # patch "classes/patch.bbclass"
> #  from [06bfa04274235a178643633deba99054024b741c]
> #    to [43a7cdac0d459f62c68c6d258f001d3b06688906]
> #
> ============================================================
> --- classes/patch.bbclass       06bfa04274235a178643633deba99054024b741c
> +++ classes/patch.bbclass       43a7cdac0d459f62c68c6d258f001d3b06688906
> @@ -174,6 +174,9 @@ def patch_init(d):
>                 def __init__(self, dir, d):
>                         PatchSet.__init__(self, dir, d)
>                         self.initialized = False
> +                       p = os.path.join(self.dir, 'patches')
> +                       if not os.path.exists(p):
> +                               os.mkdir(p)
> 
>                 def Clean(self):
>                         try:
> 

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (Darwin)

iD8DBQFE9UqgMkyGM64RGpERAtF9AJ9TjBGT+SZdmguS6RPAzdX4MF5jdACaA3u6
QrDSmbsuEdffrUIvI7aUUWo=
=EYCl
-----END PGP SIGNATURE-----



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: patcher changes - quilt patching breakage?
  2006-08-30  8:21   ` Koen Kooi
@ 2006-08-30 18:08     ` cyril Romain
  2006-09-01  1:43     ` Jamie Lenehan
  1 sibling, 0 replies; 5+ messages in thread
From: cyril Romain @ 2006-08-30 18:08 UTC (permalink / raw)
  To: Using the OpenEmbedded metadata to build Linux Distributions
  Cc: Using the OpenEmbedded metadata to build Linux Distributions

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@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



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: patcher changes - quilt patching breakage?
  2006-08-30  8:21   ` Koen Kooi
  2006-08-30 18:08     ` cyril Romain
@ 2006-09-01  1:43     ` Jamie Lenehan
  1 sibling, 0 replies; 5+ messages in thread
From: Jamie Lenehan @ 2006-09-01  1:43 UTC (permalink / raw)
  To: openembedded-devel

On Wed, Aug 30, 2006 at 10:21:52AM +0200, Koen Kooi wrote:
> Jamie Lenehan schreef:
[...]
> > 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:

Yeah, I'd assumed if quilt was being called all the required
directories it needed had been created... which, as your point out,
is obviously not always true.

[...]
> that blows up. Does python have an os.mkdirhier?

It apparently does (as the followup by Cyril shows) and it was fixed
by Chris shortly after I submitted my change.

Thanks.

-- 
 Jamie Lenehan <lenehan@twibble.org>



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2006-09-01  1:46 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-08-28 23:59 patcher changes - quilt patching breakage? Jamie Lenehan
2006-08-29  0:41 ` Jamie Lenehan
2006-08-30  8:21   ` Koen Kooi
2006-08-30 18:08     ` cyril Romain
2006-09-01  1:43     ` Jamie Lenehan

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.