diff options
author | Mark Hatle <mhatle@windriver.com> | 2010-08-23 09:12:54 -0700 |
---|---|---|
committer | Richard Purdie <rpurdie@linux.intel.com> | 2010-08-23 20:52:45 +0100 |
commit | f29f9364a3f14203d5883a9e95f38afa5926249f (patch) | |
tree | 76a86b4111df6f479fde374113ce10bda70eab8d /meta/classes/package.bbclass | |
parent | e37ee511575ef628d1591c4231e37ee0b456a76f (diff) | |
download | openembedded-core-f29f9364a3f14203d5883a9e95f38afa5926249f.tar.gz openembedded-core-f29f9364a3f14203d5883a9e95f38afa5926249f.tar.bz2 openembedded-core-f29f9364a3f14203d5883a9e95f38afa5926249f.zip |
package.bbclass: Fix per-file dependency generation
The overall file list was being constructed with the wrong variable, it
should have had FLIST in the name.
Also it was possible to construct the system with some illegal variable
names. Names that would have include "[]". So translate these away...
Finally fix an issues where a filename with an _ could cause a package
variable conflict. Again translate this away..
Signed-off-by: Mark Hatle <mhatle@windriver.com>
Diffstat (limited to 'meta/classes/package.bbclass')
-rw-r--r-- | meta/classes/package.bbclass | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/meta/classes/package.bbclass b/meta/classes/package.bbclass index 8d22d0fa8f..9ae7ecca0c 100644 --- a/meta/classes/package.bbclass +++ b/meta/classes/package.bbclass @@ -508,6 +508,7 @@ python emit_pkgdata() { for pkg in packages.split(): subdata_file = pkgdatadir + "/runtime/%s" % pkg + sf = open(subdata_file, 'w') write_if_exists(sf, pkg, 'PN') write_if_exists(sf, pkg, 'PV') @@ -580,22 +581,26 @@ python package_do_filedeps() { def process_deps(pipe, pkg, varname): dep_files = "" for line in pipe: - key = ""; - value = ""; + key = "" + value = "" # We expect two items on each line # 1 - filepath # 2 - dep list - line_list = line.split(None,1); + line_list = line.rstrip().split(None,1); if len(line_list) <= 0 or len(line_list) > 2: bb.error("deps list length error! " + len(line_list)); if len(line_list) == 2: file = line_list[0]; value = line_list[1] file = file.replace(pkgdest + "/" + pkg, "") + file = file.replace("@", "@at@") + file = file.replace("[", "@openbrace@") + file = file.replace("]", "@closebrace@") + file = file.replace("_", "@underscore@") dep_files = dep_files + " " + file key = "FILE" + varname + "_" + file + "_" + pkg bb.data.setVar(key, value, d) - bb.data.setVar("FILE" + varname + "_" + pkg, dep_files, d) + bb.data.setVar("FILE" + varname + "FLIST_" + pkg, dep_files, d) # Determine dependencies for pkg in packages.split(): |