Ejemplo n.º 1
0
def gen_tests(sln_name, directory, proj_dir, c_files):
    sn = sln_name[:sln_name.rfind('.')]
    for cnt, (name, fpath) in enumerate(c_files):
        soln = sn + str(cnt // 100 + 1) + '.sln'
        if cnt % 100 == 0:
            print(soln)
            solc = msvc_solution(abspath(join(solution_dir, directory, soln)))
        print('  ', cnt, name, fpath)
        _, t = split(fpath)
        if t[:2] not in ('t-', 'p-'):
            continue
        p_name = t.replace('.c', '')
        gen_test(solc, name, p_name, directory, proj_dir, name, fpath)
        if cnt % 100 == 99:
            solc.write_solution(vs_info)
    if cnt % 100:
        solc.write_solution(vs_info)
Ejemplo n.º 2
0
    if 0 in n_list:
        exit()
    if any(n < 1 or n > nd_nd for n in n_list):
        print('list contains invalid build numbers')
        sleep(2)
    else:
        break

# multiple builds must each have their own prebuilds
if len(n_list) > 1:
    add_prebuild = True

# now generate the requested builds

# input any existing projects in the solution (*.sln) file
solc = msvc_solution(abspath(join(solution_dir, solution_name)))
hf_list = ('config.h', 'gmp-impl.h', 'longlong.h', 'mpir.h', 'gmp-mparam.h')
for n in n_list:

    if 0 < n <= nd_gc:
        config = sorted(mpn_gc)[n - 1]
        mode = ('Win32', 'x64')
        mpn_f = mpn_gc[config]
    elif nd_gc < n <= nd_32:
        config = sorted(mpn_32)[n - 1 - nd_gc]
        gen_have_list(mpn_32[config], syms32, cfg_dir)
        mode = ('Win32', )
        mpn_f = mpn_32[config]
    elif nd_32 < n <= nd_nd:
        config = sorted(mpn_64)[n - 1 - nd_32]
        gen_have_list(mpn_64[config], syms64, cfg_dir)
Ejemplo n.º 3
0
  if 0 in n_list:
    exit()
  if any(n < 1 or n > nd_nd for n in n_list):
    print('list contains invalid build numbers')
    sleep(2)
  else:
    break

# multiple builds must each have their own prebuilds
if len(n_list) > 1:
  add_prebuild = True

# now generate the requested builds

# input any existing projects in the solution (*.sln) file
solc = msvc_solution(abspath(join(solution_dir, solution_name)))
hf_list = ('config.h', 'gmp-impl.h', 'longlong.h', 'mpir.h', 'gmp-mparam.h')
for n in n_list:

  if 0 < n <= nd_gc:
    config = sorted(mpn_gc)[n - 1]
    mode = ('Win32', 'x64')
    mpn_f = mpn_gc[config]
  elif nd_gc < n <= nd_32:
    config = sorted(mpn_32)[n - 1 - nd_gc]
    gen_have_list(mpn_32[config], syms32, cfg_dir)
    mode = ('Win32', )
    mpn_f = mpn_32[config]
  elif nd_32 < n <= nd_nd:
    config = sorted(mpn_64)[n - 1 - nd_32]
    gen_have_list(mpn_64[config], syms64, cfg_dir)