import urllib2
import argparse
-__version__ = "0.1.2"
+__version__ = "0.2.1"
__license__ = "APACHE-2.0"
__author__ = "Aleksander Mistewicz"
__author_email__ = "a.mistewicz@samsung.com"
BOOT_NAME = "common-boot-armv7l-odroidu3"
USR_NAME = "common-wayland-3parts-armv7l-odroidu3"
- BASE_IA32_WAYLAND = "images/ia32-wayland/"
- IA32_NAME = "common-wayland-efi-i586"
+ def __init__(self, url, arch):
+ if not arch or "i586" in arch:
+ self.BASE_MINNOW_WAYLAND = "images/ia32-wayland/"
+ self.MINNOW_NAME = "common-wayland-efi-i586"
+ else:
+ self.BASE_MINNOW_WAYLAND = "images/x86_64-wayland/"
+ self.MINNOW_NAME = "common-wayland-efi-x86_64"
- def __init__(self, url):
self.url = url
img_ver = ImageVersion(url)
+ self.snap_nr + "/" + self.BASE_ARM_WAYLAND + self.USR_NAME \
+ "/tizen-common_" + self.snap_nr + "_" + self.USR_NAME + ".packages"
- minnow_common_ia32_prefix = self.url + self.BASE_IA32_WAYLAND + self.IA32_NAME
- self.minnow_usr_path = minnow_common_ia32_prefix \
- + "/tizen-common_" + self.ver_nr + "_" + self.IA32_NAME
- self.minnow_usr_path_md5 = minnow_common_ia32_prefix + "/MD5SUMS"
+ minnow_common_minnow_prefix = self.url + self.BASE_MINNOW_WAYLAND + self.MINNOW_NAME
+ self.minnow_usr_path = minnow_common_minnow_prefix \
+ + "/tizen-common_" + self.ver_nr + "_" + self.MINNOW_NAME
+ self.minnow_usr_path_md5 = minnow_common_minnow_prefix + "/MD5SUMS"
self.minnow_snap_pkgs = "http://download.tizen.org/snapshots/tizen/common/tizen-common_" \
- + self.snap_nr + "/" + self.BASE_IA32_WAYLAND + self.IA32_NAME \
- + "/tizen-common_" + self.snap_nr + "_" + self.IA32_NAME + ".packages"
+ + self.snap_nr + "/" + self.BASE_MINNOW_WAYLAND + self.MINNOW_NAME \
+ + "/tizen-common_" + self.snap_nr + "_" + self.MINNOW_NAME + ".packages"
print self.snap_nr, self.ver_nr
print self.odroid_boot_path
action="store_true", default=False, dest="odroid",
help="Download images for odroid")
+ parser.add_argument("-a", "--arch",
+ action="store", dest="arch",
+ help="Choose architecture of minnowboard images")
+
args = parser.parse_args()
return args
def main():
print "Begin"
args = parse_arguments()
- downloader = ImageDownloader(args.url)
+ downloader = ImageDownloader(args.url, args.arch)
if args.odroid:
downloader.odroid()
if args.minnow: