Advertisement
tasuku

Untitled

May 27th, 2013
321
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Diff 2.09 KB | None | 0 0
  1. diff --git a/cerbero/bootstrap/linux.py b/cerbero/bootstrap/linux.py
  2. index 127543d..df02757 100644
  3. --- a/cerbero/bootstrap/linux.py
  4. +++ b/cerbero/bootstrap/linux.py
  5. @@ -102,7 +102,14 @@ class OpenSuseBootstraper (UnixBootstraper):
  6.              'docbook-utils', 'glib-networking']
  7.  
  8.  
  9. +class GentooBootstraper (UnixBootstraper):
  10. +
  11. +    tool = 'sudo emerge -uavt %s'
  12. +    packages = ['gcc']
  13. +
  14. +
  15.  def register_all():
  16.      register_bootstraper(Distro.DEBIAN, DebianBootstraper)
  17.      register_bootstraper(Distro.REDHAT, RedHatBootstraper)
  18.      register_bootstraper(Distro.SUSE, OpenSuseBootstraper)
  19. +    register_bootstraper(Distro.GENTOO, GentooBootstraper)
  20. diff --git a/cerbero/enums.py b/cerbero/enums.py
  21. index 40d51c4..4da1e20 100644
  22. --- a/cerbero/enums.py
  23. +++ b/cerbero/enums.py
  24. @@ -41,6 +41,7 @@ class Distro:
  25.      DEBIAN = 'debian'
  26.      REDHAT = 'redhat'
  27.      SUSE = 'suse'
  28. +    GENTOO = 'gentoo'
  29.      WINDOWS = 'windows'
  30.      OS_X = 'osx'
  31.      IOS = 'ios'
  32. @@ -67,6 +68,7 @@ class DistroVersion:
  33.      OPENSUSE_12_1 = 'opensuse_12_1'
  34.      OPENSUSE_12_2 = 'opensuse_12_2'
  35.      OPENSUSE_12_3 = 'opensuse_12_3'
  36. +    GENTOO_2_2 = 'gentoo_2_2'
  37.      WINDOWS_XP = 'windows_xp'
  38.      WINDOWS_VISTA = 'windows_vista'
  39.      WINDOWS_7 = 'windows_7'
  40. diff --git a/cerbero/utils/__init__.py b/cerbero/utils/__init__.py
  41. index 030e946..754e803 100644
  42. --- a/cerbero/utils/__init__.py
  43. +++ b/cerbero/utils/__init__.py
  44. @@ -177,6 +177,14 @@ def system_info():
  45.                  # FIXME Fill this
  46.                  raise FatalError("Distribution OpenSuse '%s' "
  47.                                   "not supported" % str(d))
  48. +        elif d[0].strip() in ['Gentoo Base System']:
  49. +            distro = Distro.GENTOO
  50. +            if d[1] == '2.2':
  51. +                distro_version = DistroVersion.GENTOO_2_2
  52. +            else:
  53. +                # FIXME Fill this
  54. +                raise FatalError("Distribution OpenSuse '%s' "
  55. +                                 "not supported" % str(d))
  56.          else:
  57.              raise FatalError("Distribution '%s' not supported" % str(d))
  58.      elif platform == Platform.WINDOWS:
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement