def determine_native_name(coreclr_args, base_lib_name, target_os):
    """ Determine the name of the native lib based on the OS.

    Args:
        coreclr_args (CoreclrArguments): parsed args
        base_lib_name (str) : root name of the lib
        target_os (str) : os to run tests on
    Return:
        (str) : name of the native lib for this OS
    """

    if target_os == "OSX":
        return "lib" + base_lib_name + ".dylib"
    elif target_os == "Linux":
        return "lib" + base_lib_name + ".so"
    elif target_os == "windows":
        return base_lib_name + ".dll"
    else:
        raise RuntimeError("Unknown OS.")