]> code.ossystems Code Review - openembedded-core.git/commitdiff
bitbake: Fix a bug where changed files weren't getting spotted and an invalid cache...
authorRichard Purdie <richard@openedhand.com>
Fri, 28 Mar 2008 17:19:49 +0000 (17:19 +0000)
committerRichard Purdie <richard@openedhand.com>
Fri, 28 Mar 2008 17:19:49 +0000 (17:19 +0000)
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@4148 311d38ba-8fff-0310-9ca6-ca027cbcb966

bitbake/lib/bb/cache.py
bitbake/lib/bb/fetch/git.py

index 9acd301f52e9063a09688c80203b9d6ee0e6a980..fe38ea0aeec72f419e099ed8e426b94c84e09a39 100644 (file)
@@ -208,7 +208,7 @@ class Cache:
             return False
 
         # Check the file's timestamp
-        if mtime > self.getVar("CACHETIMESTAMP", fn, True):
+        if mtime != self.getVar("CACHETIMESTAMP", fn, True):
             bb.msg.debug(2, bb.msg.domain.Cache, "Cache: %s changed" % fn)
             self.remove(fn)
             return False
@@ -223,7 +223,7 @@ class Cache:
                     self.remove(fn)
                     return False
 
-                if (fmtime > old_mtime):
+                if (fmtime != old_mtime):
                     bb.msg.debug(2, bb.msg.domain.Cache, "Cache: %s's dependency %s changed" % (fn, f))
                     self.remove(fn)
                     return False
index 0c708e3516d60ba16818749b01a056a5226eec81..f4ae724f87865bf1479f0e606a4ba140077101fa 100644 (file)
@@ -50,7 +50,7 @@ class Git(Fetch):
         if 'protocol' in ud.parm:
             ud.proto = ud.parm['protocol']
 
-        ud.branch = ud.parm.get("branch", "")
+        ud.branch = ud.parm.get("branch", "master")
 
         tag = Fetch.srcrev_internal_helper(ud, d)
         if tag is True:
@@ -95,7 +95,7 @@ class Git(Fetch):
         os.chdir(repodir)
         # Remove all but the .git directory
         runfetchcmd("rm * -Rf", d)
-        runfetchcmd("git fetch %s://%s%s" % (ud.proto, ud.host, ud.path), d)
+        runfetchcmd("git fetch %s://%s%s %s" % (ud.proto, ud.host, ud.path, ud.branch), d)
         runfetchcmd("git fetch --tags %s://%s%s" % (ud.proto, ud.host, ud.path), d)
         runfetchcmd("git prune-packed", d)
         runfetchcmd("git pack-redundant --all | xargs -r rm", d)