]> xenbits.xensource.com Git - libvirt.git/commitdiff
docs: apibuild: remove old code paths
authorPavel Hrdina <phrdina@redhat.com>
Fri, 18 Oct 2019 15:20:30 +0000 (17:20 +0200)
committerPavel Hrdina <phrdina@redhat.com>
Wed, 23 Oct 2019 12:46:26 +0000 (14:46 +0200)
There is no need to keep old compatibility code around as it it will
never be used in our current source tree.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
docs/apibuild.py

index e79ead0b53d4aee26b53b19996b61209c814b9bf..d3d0be2d836918daf24a9cd42424da4e2055f1ae 100755 (executable)
@@ -2543,25 +2543,15 @@ class app:
         builder = None
         srcdir = os.path.abspath((os.environ["srcdir"]))
         builddir = os.path.abspath((os.environ["builddir"]))
-        if srcdir == builddir:
-            builddir = None
         if glob.glob(srcdir + "/../src/libvirt.c") != []:
             if not quiet:
                 print("Rebuilding API description for %s" % name)
             dirs = [srcdir + "/../src",
                     srcdir + "/../src/admin",
                     srcdir + "/../src/util",
-                    srcdir + "/../include/libvirt"]
-            if (builddir and
-                not os.path.exists(srcdir + "/../include/libvirt/libvirt-common.h")):
-                dirs.append(builddir + "/../include/libvirt")
+                    srcdir + "/../include/libvirt",
+                    builddir + "/../include/libvirt"]
             builder = docBuilder(name, srcdir, dirs, [])
-        elif glob.glob("src/libvirt.c") != []:
-            if not quiet:
-                print("Rebuilding API description for %s" % name)
-            builder = docBuilder(name, srcdir,
-                                 ["src", "src/util", "include/libvirt"],
-                                 [])
         else:
             self.warning("rebuild() failed, unable to guess the module")
             return None