On Sat, 2008-07-19 at 15:10 -0500, Jeremy Rosengren wrote:
> "cobbler buildiso" recently failed for me because it couldn't find 
> /usr/lib/syslinux/isolinux.bin.  Remembering that RPMforge had recently 
> released an updated version of the syslinux package, it was easy to find 
> out that the new syslinux 3.7 package moves isolinux.bin from 
> /usr/lib/syslinux to /usr/share/syslinux.
> 
> I've created a simple patch that looks for isolinux.bin in both 
> locations and throws a more generic error if it can't find either of 
> them.  This patch is against the master branch.
> 
> Also, while building to test this patch, I noticed that the master 
> branch version had been incremented to 1.0.4, but the cobbler.spec file 
> hadn't been updated.  I've also attached the patch to fix that - even 
> though it's probably easier for you to just edit your copy of the file :)
> 
> Thanks!
> 
> -- jeremy
> 
> diff --git a/cobbler/action_buildiso.py b/cobbler/action_buildiso.py
> index 639bd6b..38a968b 100644
> --- a/cobbler/action_buildiso.py
> +++ b/cobbler/action_buildiso.py
> @@ -76,9 +76,12 @@ class BuildIso:
>         if iso is None:
>             iso = "kickstart.iso"
> 
> -        isolinuxbin = "/usr/lib/syslinux/isolinux.bin"
> -        if not os.path.exists(isolinuxbin):
> -            raise CX(_("Required file not found: %s") % isolinuxbin)
> +        if os.path.exists("/usr/lib/syslinux/isolinux.bin"):
> +            isolinuxbin = "/usr/lib/syslinux/isolinux.bin"
> +        elif os.path.exists("/usr/share/syslinux/isolinux.bin"):
> +            isolinuxbin = "/usr/share/syslinux/isolinux.bin"
> +        else:
> +            raise CX(_("Required file not found: isolinux.bin"))
> 
>         # if iso is none, create it in . as "cobbler.iso"
>         if tempdir is None:
> 
> 
> 
> diff --git a/cobbler.spec b/cobbler.spec
> index f651452..27053ad 100644
> --- a/cobbler.spec
> +++ b/cobbler.spec
> @@ -2,8 +2,8 @@
> Summary: Boot server configurator
> Name: cobbler
> AutoReq: no
> -Version: 1.0.3
> -Release: 1%{?dist}
> +Version: 1.0.4
> +Release: 1%{?dist}
> Source0: %{name}-%{version}.tar.gz
> License: GPLv2+
> Group: Applications/System
> 
> 
> _______________________________________________
> cobbler mailing list
> [email protected]
> https://fedorahosted.org/mailman/listinfo/cobbler


I am applying this fix here in case this eventually happens in Fedora or
another distro (which is fair), though I would caution you against usage
of DAG's repo in general (or at least, not without EPEL) -- cobbler and
koan can be dated.  

I have also encountered cases of certain packages like syslinux being
installed in /usr/lib64, which is pretty weird :)

--Michael


_______________________________________________
cobbler mailing list
[email protected]
https://fedorahosted.org/mailman/listinfo/cobbler

Reply via email to