Patch for Bug #227013 - /boot not mounted
[moblin-image-creator.eeepc.git] / libs / moblin_pkgbase.py
blob5fa8c3e029fec2fa2d02303ae3d61fa451e8223e
1 #!/usr/bin/python -tt
2 # vim: ai ts=4 sts=4 et sw=4
4 # Copyright (c) 2007 Intel Corporation
6 # This program is free software; you can redistribute it and/or modify it
7 # under the terms of the GNU General Public License as published by the Free
8 # Software Foundation; version 2 of the License
10 # This program is distributed in the hope that it will be useful, but
11 # WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
12 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
13 # for more details.
15 # You should have received a copy of the GNU General Public License along
16 # with this program; if not, write to the Free Software Foundation, Inc., 59
17 # Temple Place - Suite 330, Boston, MA 02111-1307, USA.
19 # The purpose of this library is to provide an abstraction layer to the package
20 # management functionality. This will provide the base class. This way the
21 # image-creator will not care if you are using apt or yum or whatever package
22 # management system you want to use.
24 class PackageManager(object):
25 """Base class for the package management classes"""
27 def __init__(self):
28 raise NotImplementedError
30 def installPackages(self, chroot_dir, package_list):
31 """Install the list of packages in the chroot environment"""
32 raise NotImplementedError
34 def updateChroot(self, chroot_dir):
35 """Update the chroot environment to have the latest packages"""
36 raise NotImplementedError
38 def cleanPackageCache(self, chroot_dir):
39 """Clean out any cached package files"""
40 raise NotImplementedError