def set_global(args): global pkg_path global output_dir global GOPATH global servlet_dir arch = ops.getEnv("ARCH_ALT") pkg_path = args["pkg_path"] output_dir = args["output_path"] GOPATH = output_dir servlet_dir = ops.path_join(output_dir, "/build")
def MAIN_CONFIGURE(args): set_global(args) extra_conf = [] extra_conf.append("--host=" + cc_host) extra_conf.append("V=1") extra_conf.append("--disable-x11") extra_conf.append("--disable-gles1") extra_conf.append("--enable-gles2") extra_conf.append("--enable-egl") extra_conf.append("--enable-libdrm") #extra_conf.append("--enable-vg") cc_sysroot = ops.getEnv("CC_SYSROOT") cflags = "" cflags += " -I" + ops.path_join(iopc.getSdkPath(), 'usr/include/mesa') cflags += " -I" + ops.path_join(iopc.getSdkPath(), 'usr/include/libglu') cflags += " -I" + ops.path_join(iopc.getSdkPath(), 'usr/include/libdrm') cflags += " -I" + ops.path_join(iopc.getSdkPath(), 'usr/include/libdrm/libdrm') cflags += " -I" + ops.path_join(iopc.getSdkPath(), 'usr/include/libdrm/libkms') cflags += " -DMESA_EGL_NO_X11_HEADERS" libs = "" libs += " -L" + ops.path_join(cc_sysroot, 'lib') libs += " -L" + ops.path_join(cc_sysroot, 'usr/lib') libs += " -L" + ops.path_join(iopc.getSdkPath(), 'lib') libs += " -ldrm -lEGL -lglapi -lGLESv2 -lOSMesa -lGLU -lgbm -lxml2 -lexpat -lz -lffi -lfreetype" extra_conf.append('GL_CFLAGS=' + cflags) extra_conf.append('GL_LIBS=' + libs) extra_conf.append('EGL_CFLAGS=' + cflags) extra_conf.append('EGL_LIBS=' + libs) extra_conf.append('GLESV2_CFLAGS=' + cflags) extra_conf.append('GLESV2_LIBS=' + libs) extra_conf.append('DRM_CFLAGS=' + cflags) extra_conf.append('DRM_LIBS=' + libs) extra_conf.append('GBM_CFLAGS=' + cflags) extra_conf.append('GBM_LIBS=' + libs) extra_conf.append('OSMESA_CFLAGS=' + cflags) extra_conf.append('OSMESA_LIBS=' + libs) #extra_conf.append('GLEW_CFLAGS=' + cflags) #extra_conf.append('GLEW_LIBS=' + libs) extra_conf.append('GLU_CFLAGS=' + cflags) extra_conf.append('GLU_LIBS=' + libs) extra_conf.append('FREETYPE2_CFLAGS=' + libs) extra_conf.append('FREETYPE2_LIBS=' + libs) iopc.configure(tarball_dir, extra_conf) return True
def MAIN_EXTRACT(args): set_global(args) ops.mkdir(dst_lib_dir) ops.copyto(ops.path_join(src_usr_lib_dir, "libdb-5.3.so"), dst_lib_dir) ops.ln(dst_lib_dir, "libdb-5.3.so", "libdb.so") #ops.mkdir(dst_include_dir) #iopc.installBin(args["pkg_name"], ops.path_join(src_include_dir, "db_185.h"), dst_include_dir) #iopc.installBin(args["pkg_name"], ops.path_join(src_include_dir, "db.h"), dst_include_dir) return True
def MAIN_CONFIGURE(args): set_global(args) extra_conf = [] extra_conf.append("--host=" + cc_host) cflags = "" cflags += " -I" + ops.path_join(iopc.getSdkPath(), 'usr/include/mesa') libs = "" libs += " -L" + ops.path_join(iopc.getSdkPath(), 'lib') libs += " -ldrm -lEGL -lglapi -lGLESv2" extra_conf.append('GL_CFLAGS=' + cflags) extra_conf.append('GL_LIBS=' + libs) # iopc.configure(tarball_dir, extra_conf) return True
def MAIN_SDKENV(args): set_global(args) cc_sysroot = ops.getEnv("CC_SYSROOT") cflags = "" cflags += " -I" + ops.path_join(cc_sysroot, 'usr/include') cflags += " -I" + ops.path_join(iopc.getSdkPath(), 'usr/include') #cflags += " -I" + ops.path_join(iopc.getSdkPath(), 'usr/include/linux_headers') libs = "" libs += " -L" + ops.path_join(cc_sysroot, 'lib') libs += " -L" + ops.path_join(cc_sysroot, 'usr/lib') libs += " -L" + ops.path_join(iopc.getSdkPath(), 'lib') #libs += " -L" + ops.path_join(iopc.getSdkPath(), 'usr/lib') libs += " -lm -ldl -lpthread -lrt" iopc.add_includes(cflags) iopc.add_libs(libs) return False
def MAIN_EXTRACT(args): set_global(args) ops.mkdir(output_platform_dir) for ini in dao_files: dao_file = ops.path_join(pkg_path, ini + ".ini") ops.copyto(dao_file, output_platform_dir) ops.copyto(dao_file, output_dir) return True
def MAIN_BUILD(args): set_global(args) ops.mkdir(install_dir) ops.mkdir(install_tmp_dir) iopc.make(tarball_dir) iopc.make_install(tarball_dir) ops.copyto( ops.path_join(install_tmp_dir, "usr/local/share/wayland-protocols"), install_dir) ops.mkdir(tmp_include_dir) #ops.copyto(ops.path_join(install_tmp_dir, "usr/local/include/."), tmp_include_dir) ops.mkdir(dst_pkgconfig_dir) ops.copyto(ops.path_join(src_pkgconfig_dir, '.'), dst_pkgconfig_dir) return False
def MAIN_BUILD(args): set_global(args) ops.mkdir(install_dir) ops.mkdir(install_tmp_dir) iopc.make(tarball_dir) iopc.make_install(tarball_dir) ops.mkdir(install_dir) ops.mkdir(dst_lib_dir) libmtdev = "libmtdev.so.1.0.0" ops.copyto(ops.path_join(install_tmp_dir, "usr/local/lib/" + libmtdev), dst_lib_dir) ops.ln(dst_lib_dir, libmtdev, "libmtdev.so.1.0") ops.ln(dst_lib_dir, libmtdev, "libmtdev.so.1") ops.ln(dst_lib_dir, libmtdev, "libmtdev.so") ops.mkdir(tmp_include_dir) ops.copyto(ops.path_join(install_tmp_dir, "usr/local/include/."), tmp_include_dir) return False
def set_global(args): global pkg_path global output_dir global arch global src_lib_dir global dst_lib_dir global src_usr_lib_dir global dst_lib_dir global src_usr_bin_dir global dst_usr_bin_dir global src_sbin_dir global dst_sbin_dir global src_usr_sbin_dir global dst_usr_sbin_dir global src_include_dir global dst_include_dir pkg_path = args["pkg_path"] output_dir = args["output_path"] arch = ops.getEnv("ARCH_ALT") if arch == "armhf": src_lib_dir = iopc.getBaseRootFile("lib/arm-linux-gnueabihf") src_usr_lib_dir = iopc.getBaseRootFile("usr/lib/arm-linux-gnueabihf") elif arch == "armel": src_lib_dir = iopc.getBaseRootFile("lib/arm-linux-gnueabi") src_usr_lib_dir = iopc.getBaseRootFile("usr/lib/arm-linux-gnueabi") elif arch == "x86_64": src_lib_dir = iopc.getBaseRootFile("lib/x86_64-linux-gnu") src_usr_lib_dir = iopc.getBaseRootFile("usr/lib/x86_64-linux-gnu") else: sys.exit(1) dst_lib_dir = ops.path_join(output_dir, "lib") src_sbin_dir = iopc.getBaseRootFile("sbin") dst_sbin_dir = ops.path_join(output_dir, "sbin") src_usr_bin_dir = iopc.getBaseRootFile("usr/bin") dst_usr_bin_dir = ops.path_join(output_dir, "usr/bin") src_usr_sbin_dir = iopc.getBaseRootFile("usr/sbin") dst_usr_sbin_dir = ops.path_join(output_dir, "usr/sbin") src_include_dir = iopc.getBaseRootFile("usr/include/lxc") dst_include_dir = ops.path_join("include",args["pkg_name"])
def MAIN_INSTALL(args): set_global(args) ops.mkdir(busybox_install_dir) extra_conf = [] #extra_conf.append("CONFIG_PREFIX=" + iopc.getBinPkgPath(args["pkg_name"])) extra_conf.append("CONFIG_PREFIX=" + busybox_install_dir) iopc.make_install(busybox_build_dir, extra_conf) ops.mkdir(ops.path_join(busybox_install_dir, "usr/share/udhcpc")) ops.copyto(src_busybox_udhcpc_script, ops.path_join(busybox_install_dir, "usr/share/udhcpc")) ops.mkdir(ops.path_join(busybox_install_dir, "etc")) #ops.copyto(src_busybox_inittab, ops.path_join(busybox_install_dir, "etc")) ops.ln(busybox_install_dir, "/sbin/init", "init") #iopc.installBin(args["pkg_name"], tmp_busybox_udhcpc_script, "/usr/share/udhcpc/") #iopc.installBin(args["pkg_name"], dst_busybox_inittab, "/etc") iopc.installBin(args["pkg_name"], ops.path_join(busybox_install_dir, "."), ".") #ops.ln(install_dir, "/sbin/init", "init") return False
def MAIN_INSTALL(args): set_global(args) if install_platform_dao == True: #ops.copyto(ops.path_join(output_dir, 'db_init.bin'), iopc.getOutputRootDir()) #ops.copyto(ops.path_join(output_dir, 'img_header.bin'), iopc.getOutputRootDir()) iopc.installBin(args["pkg_name"], ops.path_join(output_dir, "db_init.inc"), 'include/platform') return False
def MAIN_EXTRACT(args): set_global(args) ops.mkdir(dst_lib_dir) lib_so = "libjson-c.so.2.0.0" ops.copyto(ops.path_join(src_lib_dir, lib_so), dst_lib_dir) ops.ln(dst_lib_dir, lib_so, "libjson-c.so.2.0") ops.ln(dst_lib_dir, lib_so, "libjson-c.so.2") ops.ln(dst_lib_dir, lib_so, "libjson-c.so") return True
def MAIN_BUILD(args): set_global(args) #iopc.make_squashfs_xz(output_platform_dir, output_dir, squashfs_name) CMD = [ 'python', daosfs_script, output_platform_dir, ops.path_join(output_dir, squashfs_name) ] ops.execCmd(CMD, output_dir, False) return False
def set_global(args): global pkg_path global output_dir global arch global output_platform_dir global install_platform_dao global dao_script global pkg_tarball global pkg_tarball_dir pkg_path = args["pkg_path"] output_dir = args["output_path"] arch = ops.getEnv("ARCH_ALT") output_platform_dir = ops.path_join(iopc.getOutputRootDir(), "platform") dao_script = ops.path_join(output_platform_dir, "dao.py") pkg_tarball = ops.path_join(pkg_path, pkg_tarball) pkg_tarball_dir = ops.path_join(output_dir, pkg_tarball_dir) install_platform_dao = False if ops.getEnv("INSTALL_PLATFORM_DAO") == 'y': install_platform_dao = True
def set_global(args): global pkg_path global output_dir global arch global src_image_cfg global output_platform_dir global install_platform_dao pkg_path = args["pkg_path"] output_dir = args["output_path"] arch = ops.getEnv("ARCH_ALT") output_platform_dir = ops.path_join(iopc.getOutputRootDir(), "platform")
def MAIN_SDKENV(args): set_global(args) cflags = "" cflags += " -I" + ops.path_join(iopc.getSdkPath(), 'usr/include/' + args["pkg_name"]) iopc.add_includes(cflags) libs = "" libs += " -lmtdev" iopc.add_libs(libs) return False
def MAIN_SDKENV(args): set_global(args) cflags = "" cflags += " -I" + ops.path_join(iopc.getSdkPath(), 'usr/include/' + args["pkg_name"]) iopc.add_includes(cflags) libs = "" libs += " -lcairo" iopc.add_libs(libs) return False
def MAIN_EXTRACT(args): set_global(args) ops.pkg_mkdir(output_rootfs_dir, "bin") ops.pkg_mkdir(output_rootfs_dir, "dev") ops.pkg_mkdir(output_rootfs_dir, "etc") ops.pkg_mkdir(output_rootfs_dir, "lib") ops.pkg_mkdir(output_rootfs_dir, "mnt") ops.pkg_mkdir(output_rootfs_dir, "newroot") ops.pkg_mkdir(output_rootfs_dir, "root") ops.pkg_mkdir(output_rootfs_dir, "sbin") ops.pkg_mkdir(output_rootfs_dir, "proc") ops.pkg_mkdir(output_rootfs_dir, "sys") ops.mknod_char(ops.path_join(output_rootfs_dir, "dev"), "console", "5", "1") ops.mknod_char(ops.path_join(output_rootfs_dir, "dev"), "null", "1", "3") ops.copyto(ops.path_join(pkg_path, "init"), output_rootfs_dir) ops.ln(output_rootfs_dir, "lib", "lib64") return True
def MAIN_ENV(args): set_global(args) ops.exportEnv(ops.setEnv("CC", ops.getEnv("CROSS_COMPILE") + "gcc")) ops.exportEnv(ops.setEnv("CXX", ops.getEnv("CROSS_COMPILE") + "g++")) ops.exportEnv(ops.setEnv("CROSS", ops.getEnv("CROSS_COMPILE"))) ops.exportEnv(ops.setEnv("DESTDIR", install_tmp_dir)) #ops.exportEnv(ops.setEnv("PKG_CONFIG_LIBDIR", ops.path_join(iopc.getSdkPath(), "pkgconfig"))) #ops.exportEnv(ops.setEnv("PKG_CONFIG_SYSROOT_DIR", iopc.getSdkPath())) cc_sysroot = ops.getEnv("CC_SYSROOT") cflags = "" cflags += " -I" + ops.path_join(cc_sysroot, 'usr/include') cflags += " -I" + ops.path_join(iopc.getSdkPath(), 'usr/include/libdrm') cflags += " -I" + ops.path_join(iopc.getSdkPath(), 'usr/include/libdrm/libdrm') ldflags = "" ldflags += " -L" + ops.path_join(cc_sysroot, 'lib') ldflags += " -L" + ops.path_join(cc_sysroot, 'usr/lib') ldflags += " -L" + ops.path_join(iopc.getSdkPath(), 'lib') libs = "" libs += " -lffi -lxml2 -lexpat -ldrm" #ops.exportEnv(ops.setEnv("LDFLAGS", ldflags)) #ops.exportEnv(ops.setEnv("CFLAGS", cflags)) #ops.exportEnv(ops.setEnv("LIBS", libs)) return False
def MAIN_BUILD(args): set_global(args) ops.mkdir(install_dir) ops.mkdir(install_tmp_dir) iopc.make(tarball_dir) iopc.make_install(tarball_dir) ops.mkdir(dst_lib_dir) libgio = "libgio-2.0.so.0.5400.3" ops.copyto(ops.path_join(install_tmp_dir, "usr/local/lib/" + libgio), dst_lib_dir) ops.ln(dst_lib_dir, libgio, "libgio-2.0.so.0") ops.ln(dst_lib_dir, libgio, "libgio-2.0.so") libglib = "libglib-2.0.so.0.5400.3" ops.copyto(ops.path_join(install_tmp_dir, "usr/local/lib/" + libglib), dst_lib_dir) ops.ln(dst_lib_dir, libglib, "libglib-2.0.so.0") ops.ln(dst_lib_dir, libglib, "libglib-2.0.so") libgmodule = "libgmodule-2.0.so.0.5400.3" ops.copyto(ops.path_join(install_tmp_dir, "usr/local/lib/" + libgmodule), dst_lib_dir) ops.ln(dst_lib_dir, libgmodule, "libgmodule-2.0.so.0") ops.ln(dst_lib_dir, libgmodule, "libgmodule-2.0.so") libgobject = "libgobject-2.0.so.0.5400.3" ops.copyto(ops.path_join(install_tmp_dir, "usr/local/lib/" + libgobject), dst_lib_dir) ops.ln(dst_lib_dir, libgobject, "libgobject-2.0.so.0") ops.ln(dst_lib_dir, libgobject, "libgobject-2.0.so") libgthread = "libgthread-2.0.so.0.5400.3" ops.copyto(ops.path_join(install_tmp_dir, "usr/local/lib/" + libgthread), dst_lib_dir) ops.ln(dst_lib_dir, libgthread, "libgthread-2.0.so.0") ops.ln(dst_lib_dir, libgthread, "libgthread-2.0.so") ops.mkdir(dst_include_dir) ops.copyto(ops.path_join(tarball_dir, "glib/glibconfig.h"), dst_include_dir) ops.copyto(ops.path_join(install_tmp_dir, "usr/local/include/."), dst_include_dir) ops.mkdir(dst_pkgconfig_dir) ops.copyto(ops.path_join(src_pkgconfig_dir, '.'), dst_pkgconfig_dir) return False
def MAIN_BUILD(args): set_global(args) print "AAAA" + ops.getEnv("PATH") ops.mkdir(install_dir) ops.mkdir(install_tmp_dir) iopc.make(tarball_dir) iopc.make_install(tarball_dir) ops.mkdir(install_dir) ops.mkdir(dst_lib_dir) libwayland_client = "libwayland-client.so.0.3.0" ops.copyto( ops.path_join(install_tmp_dir, "usr/local/lib/" + libwayland_client), dst_lib_dir) ops.ln(dst_lib_dir, libwayland_client, "libwayland-client.so.0.3") ops.ln(dst_lib_dir, libwayland_client, "libwayland-client.so.0") ops.ln(dst_lib_dir, libwayland_client, "libwayland-client.so") libwayland_cursor = "libwayland-cursor.so.0.0.0" ops.copyto( ops.path_join(install_tmp_dir, "usr/local/lib/" + libwayland_cursor), dst_lib_dir) ops.ln(dst_lib_dir, libwayland_cursor, "libwayland-cursor.so.0.0") ops.ln(dst_lib_dir, libwayland_cursor, "libwayland-cursor.so.0") ops.ln(dst_lib_dir, libwayland_cursor, "libwayland-cursor.so") libwayland_egl = "libwayland-egl.so.1.0.0" ops.copyto( ops.path_join(install_tmp_dir, "usr/local/lib/" + libwayland_egl), dst_lib_dir) ops.ln(dst_lib_dir, libwayland_egl, "libwayland-egl.so.1.0") ops.ln(dst_lib_dir, libwayland_egl, "libwayland-egl.so.1") ops.ln(dst_lib_dir, libwayland_egl, "libwayland-egl.so") libwayland_server = "libwayland-server.so.0.1.0" ops.copyto( ops.path_join(install_tmp_dir, "usr/local/lib/" + libwayland_server), dst_lib_dir) ops.ln(dst_lib_dir, libwayland_server, "libwayland-server.so.0.1") ops.ln(dst_lib_dir, libwayland_server, "libwayland-server.so.0") ops.ln(dst_lib_dir, libwayland_server, "libwayland-server.so") ops.mkdir(tmp_include_dir) ops.copyto(ops.path_join(install_tmp_dir, "usr/local/include/."), tmp_include_dir) ops.mkdir(host_utils) ops.copyto(ops.path_join(pkg_path, "host_utils/wayland-scanner"), host_utils) ops.mkdir(dst_pkgconfig_dir) ops.copyto(ops.path_join(src_pkgconfig_dir, '.'), dst_pkgconfig_dir) return False
def MAIN_ENV(args): set_global(args) ops.exportEnv(ops.setEnv("CC", ops.getEnv("CROSS_COMPILE") + "gcc")) ops.exportEnv(ops.setEnv("CXX", ops.getEnv("CROSS_COMPILE") + "g++")) ops.exportEnv(ops.setEnv("CROSS", ops.getEnv("CROSS_COMPILE"))) ops.exportEnv(ops.setEnv("DESTDIR", install_tmp_dir)) #ops.exportEnv(ops.setEnv("PKG_CONFIG_LIBDIR", ops.path_join(iopc.getSdkPath(), "pkgconfig"))) #ops.exportEnv(ops.setEnv("PKG_CONFIG_SYSROOT_DIR", iopc.getSdkPath())) #ops.exportEnv(ops.setEnv("WAYLAND_SCANNER_UTIL", wayland_scanner)) ops.exportEnv(ops.addEnv("PATH", ops.path_join(pkg_path, "host_utils"))) return False
def MAIN_SDKENV(args): set_global(args) cflags = "" cflags += " -I" + ops.path_join(iopc.getSdkPath(), 'usr/include/' + args["pkg_name"]) iopc.add_includes(cflags) libs = "" libs += " -lwayland-client -lwayland-cursor -lwayland-egl -lwayland-server" iopc.add_libs(libs) return False
def MAIN_BUILD(args): set_global(args) ops.mkdir(install_dir) ops.mkdir(install_tmp_dir) iopc.make(tarball_dir) iopc.make_install(tarball_dir) ops.mkdir(install_dir) ops.mkdir(dst_lib_dir) libfontconfig = "libfontconfig.so.1.11.1" ops.copyto( ops.path_join(install_tmp_dir, "usr/local/lib/" + libfontconfig), dst_lib_dir) ops.ln(dst_lib_dir, libfontconfig, "libfontconfig.so.1.11") ops.ln(dst_lib_dir, libfontconfig, "libfontconfig.so.1") ops.ln(dst_lib_dir, libfontconfig, "libfontconfig.so") ops.mkdir(tmp_include_dir) ops.copyto(ops.path_join(install_tmp_dir, "usr/local/include/."), tmp_include_dir) return True
def copy_sdk_usr_libs(): ops.mkdir(dst_usr_lib_dir) ops.copyto(ops.path_join(cc_sdk_sysroot, "Mcrt1.o"), dst_usr_lib_dir) ops.copyto(ops.path_join(cc_sdk_sysroot, "Scrt1.o"), dst_usr_lib_dir) ops.copyto(ops.path_join(cc_sdk_sysroot, "crt1.o"), dst_usr_lib_dir) ops.copyto(ops.path_join(cc_sdk_sysroot, "crti.o"), dst_usr_lib_dir) ops.copyto(ops.path_join(cc_sdk_sysroot, "crtn.o"), dst_usr_lib_dir) ops.copyto(ops.path_join(cc_sdk_sysroot, "gcrt1.o"), dst_usr_lib_dir)
def MAIN_SDKENV(args): set_global(args) cflags = "" cflags += " -I" + ops.path_join(iopc.getSdkPath(), 'usr/include/' + args["pkg_name"]) cflags += " -DMESA_EGL_NO_X11_HEADERS" iopc.add_includes(cflags) libs = "" libs += " -lEGL -lGLESv2 -lgbm -lglapi -lOSMesa -lwayland-egl" iopc.add_libs(libs) return False
def set_global(args): global pkg_path global output_dir global arch global do_debootstrap global base_rootfs_dir global base_rootfs_tarball pkg_path = args["pkg_path"] output_dir = args["output_path"] arch = ops.getEnv("ARCH_ALT") do_debootstrap = ops.getEnv("DO_DEBOOTSTRAP") pkg_args = args["pkg_args"] base_rootfs_tarball = ops.path_join(pkg_path, pkg_args["version"]) if arch == "armhf": base_rootfs_dir = ops.path_join(output_dir, "debian_jessie_armhf") elif arch == "armel": base_rootfs_dir = ops.path_join(output_dir, "debian_jessie_armel") elif arch == "x86_64": base_rootfs_dir = ops.path_join(output_dir, "debian_jessie_x86_64") else: sys.exit(1) print base_rootfs_tarball
def MAIN_BUILD(args): set_global(args) ops.mkdir(install_dir) ops.mkdir(install_tmp_dir) iopc.make(tarball_dir) iopc.make_install(tarball_dir) ops.mkdir(install_dir) ops.mkdir(dst_lib_dir) libharfbuzz_subset = "libharfbuzz-subset.so.0.10706.0" ops.copyto( ops.path_join(install_tmp_dir, "usr/local/lib/" + libharfbuzz_subset), dst_lib_dir) ops.ln(dst_lib_dir, libharfbuzz_subset, "libharfbuzz-subset.so.0.10706") ops.ln(dst_lib_dir, libharfbuzz_subset, "libharfbuzz-subset.so.0") ops.ln(dst_lib_dir, libharfbuzz_subset, "libharfbuzz-subset.so") libharfbuzz = "libharfbuzz.so.0.10706.0" ops.copyto(ops.path_join(install_tmp_dir, "usr/local/lib/" + libharfbuzz), dst_lib_dir) ops.ln(dst_lib_dir, libharfbuzz, "libharfbuzz.so.0.10706") ops.ln(dst_lib_dir, libharfbuzz, "libharfbuzz.so.0") ops.ln(dst_lib_dir, libharfbuzz, "libharfbuzz.so") libharfbuzz_icu = "libharfbuzz-icu.so.0.10706.0" ops.copyto( ops.path_join(install_tmp_dir, "usr/local/lib/" + libharfbuzz_icu), dst_lib_dir) ops.ln(dst_lib_dir, libharfbuzz_icu, "libharfbuzz-icu.so.0.10706") ops.ln(dst_lib_dir, libharfbuzz_icu, "libharfbuzz-icu.so.0") ops.ln(dst_lib_dir, libharfbuzz_icu, "libharfbuzz-icu.so") ops.mkdir(tmp_include_dir) ops.copyto(ops.path_join(install_tmp_dir, "usr/local/include/."), tmp_include_dir) return False
def MAIN_INSTALL(args): set_global(args) iopc.installBin(args["pkg_name"], ops.path_join(ops.path_join(install_dir, "lib"), "."), "lib") iopc.installBin(args["pkg_name"], ops.path_join(tmp_include_dir, "."), dst_include_dir) iopc.installBin(args["pkg_name"], ops.path_join(dst_pkgconfig_dir, '.'), "pkgconfig") if install_test_utils: iopc.installBin(args["pkg_name"], ops.path_join(ops.path_join(install_dir, "bin"), "."), "bin") return False
def MAIN_ENV(args): set_global(args) ops.exportEnv(ops.setEnv("CC", ops.getEnv("CROSS_COMPILE") + "gcc")) ops.exportEnv(ops.setEnv("CXX", ops.getEnv("CROSS_COMPILE") + "g++")) ops.exportEnv(ops.setEnv("CROSS", ops.getEnv("CROSS_COMPILE"))) ops.exportEnv(ops.setEnv("DESTDIR", install_tmp_dir)) ops.exportEnv(ops.setEnv("PKG_CONFIG_LIBDIR", ops.path_join(iopc.getSdkPath(), "pkgconfig"))) ops.exportEnv(ops.setEnv("PKG_CONFIG_SYSROOT_DIR", iopc.getSdkPath())) ''' ops.exportEnv(ops.setEnv("LDFLAGS", ldflags)) ops.exportEnv(ops.setEnv("CFLAGS", cflags)) ops.exportEnv(ops.setEnv("LIBS", libs)) ''' return False
def MAIN_EXTRACT(args): set_global(args) ops.mkdir(dst_sbin_dir) ops.copyto(ops.path_join(src_sbin_dir, "badblocks"), dst_sbin_dir) ops.copyto(ops.path_join(src_sbin_dir, "mke2fs"), dst_sbin_dir) ops.ln(dst_sbin_dir, "mke2fs", "mkfs.ext4") ops.copyto(ops.path_join(src_sbin_dir, "resize2fs"), dst_sbin_dir) ops.copyto(ops.path_join(src_sbin_dir, "tune2fs"), dst_sbin_dir) ops.mkdir(dst_lib_dir) lib_so = "libext2fs.so.2.4" ops.copyto(ops.path_join(src_lib_dir, lib_so), dst_lib_dir) ops.ln(dst_lib_dir, lib_so, "libext2fs.so.2") ops.ln(dst_lib_dir, lib_so, "libext2fs.so") lib_so = "libcom_err.so.2.1" ops.copyto(ops.path_join(src_lib_dir, lib_so), dst_lib_dir) ops.ln(dst_lib_dir, lib_so, "libcom_err.so.2") ops.ln(dst_lib_dir, lib_so, "libcom_err.so") lib_so = "libblkid.so.1.1.0" ops.copyto(ops.path_join(src_lib_dir, lib_so), dst_lib_dir) ops.ln(dst_lib_dir, lib_so, "libblkid.so.1.1") ops.ln(dst_lib_dir, lib_so, "libblkid.so.1") ops.ln(dst_lib_dir, lib_so, "libblkid.so") lib_so = "libuuid.so.1.3.0" ops.copyto(ops.path_join(src_lib_dir, lib_so), dst_lib_dir) ops.ln(dst_lib_dir, lib_so, "libuuid.so.1.3") ops.ln(dst_lib_dir, lib_so, "libuuid.so.1") ops.ln(dst_lib_dir, lib_so, "libuuid.so") lib_so = "libe2p.so.2.3" ops.copyto(ops.path_join(src_lib_dir, lib_so), dst_lib_dir) ops.ln(dst_lib_dir, lib_so, "libe2p.so.2") ops.ln(dst_lib_dir, lib_so, "libe2p.so") return True
def MAIN_INSTALL(args): set_global(args) ops.mkdir(install_dir) ops.mkdir(dst_lib_dir) libcairo = "libcairo.so.2.11400.12" ops.copyto(ops.path_join(install_tmp_dir, "usr/local/lib/" + libcairo), dst_lib_dir) ops.ln(dst_lib_dir, libcairo, "libcairo.so.2") ops.ln(dst_lib_dir, libcairo, "libcairo.so") ops.mkdir(dst_include_dir) ops.copyto(ops.path_join(install_tmp_dir, "usr/local/include/cairo/cairo-deprecated.h"), dst_include_dir) ops.copyto(ops.path_join(install_tmp_dir, "usr/local/include/cairo/cairo-features.h"), dst_include_dir) ops.copyto(ops.path_join(install_tmp_dir, "usr/local/include/cairo/cairo.h"), dst_include_dir) ops.copyto(ops.path_join(install_tmp_dir, "usr/local/include/cairo/cairo-script.h"), dst_include_dir) ops.copyto(ops.path_join(install_tmp_dir, "usr/local/include/cairo/cairo-version.h"), dst_include_dir) iopc.installBin(args["pkg_name"], ops.path_join(ops.path_join(install_dir, "lib"), "."), "lib") iopc.installBin(args["pkg_name"], dst_include_dir, "include") return False
def set_global(args): global pkg_path global output_dir global tarball_pkg global install_dir global install_tmp_dir global tarball_dir global cc_host global dst_include_dir global dst_lib_dir pkg_path = args["pkg_path"] output_dir = args["output_path"] tarball_pkg = ops.path_join(pkg_path, TARBALL_FILE) install_dir = ops.path_join(output_dir, INSTALL_DIR) install_tmp_dir = ops.path_join(output_dir, INSTALL_DIR + "-tmp") tarball_dir = ops.path_join(output_dir, TARBALL_DIR) cc_host_str = ops.getEnv("CROSS_COMPILE") cc_host = cc_host_str[:len(cc_host_str) - 1] dst_include_dir = ops.path_join(output_dir, ops.path_join("include",args["pkg_name"])) dst_lib_dir = ops.path_join(install_dir, "lib")