Example #1
0
def data(*args):
    """
    data    [dist] -- fetch all data and libraries for your platform.
    """
    dists = get_dists(*args)
    if dists:
        d = [ (p, r) for s, p, r in parse(*dists)["data"] if system(s)]
        if d: run_data(d)
        else: print "Found no data entries for platform %s." % sys.platform
    d = [ (p, r) for s, p, r in parse(*args)["data"] if system(s)]
    if d: run_data(d)
    else: print "Found no data entries for platform %s." % sys.platform
Example #2
0
def commit_repo(user, repos):
    """
    push changes to repositories
    """
    if system("win"):	
        user = get_windows_username();
    else:
        if user: user = user + "@"
        else: user = ""
    for p,r in repos:
        print "Commiting %s to %s" % (relpath(p), r)
        execute("darcs push %s%s --repodir %s" % (user, r, p))
Example #3
0
def deps():
    """
    deps          -- compile dependency libraries
    """
    prepare()
    owd = os.getcwd()
    os.chdir(deps_dir)
    if not path.isfile(path.join(deps_dir, "Makefile")):
        if system("win"):
            execute("cmake -DDEPS=true -G \"MinGW Makefiles\" ../")
        else: 
            execute("cmake -DDEPS=true ../")
    sys_exec_make("all")
    sys_exec_make("install")
    os.chdir(owd)
def commit_repo(user, repos):
    """
    push changes to repositories
    """
    threadlist = []
    if system("win"):	
        user = get_windows_username();
    else:
        if user: user = user + "@"
        else: user = ""
    for p,r in repos:
        print "Commiting %s to %s" % (relpath(p), r)
        current = Async_repo_upload(user, r, p)
        threadlist.append(current)
        current.start()
    for thread in threadlist:
        thread.join()
def sys_exec_make(target):
    if system("win"):
        execute("mingw32-make --jobs %s" % (target))
    else:
        execute("make --jobs %d %s" % (cores()+1, target))
def sys_exec_cmake():
    if system("win"):
        execute("cmake -G \"MinGW Makefiles\" ../")
    else: 
        execute("cmake ../")