Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Work around enums not being blittable #1857

Merged
merged 4 commits into from
Nov 9, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions binding/HarfBuzzSharp.Shared/DelegateProxies.unicode.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,17 +24,17 @@ internal static unsafe partial class DelegateProxies
public static readonly UnicodeDecomposeProxyDelegate DecomposeProxy = DecomposeProxyImplementation;

[MonoPInvokeCallback (typeof (UnicodeCombiningClassProxyDelegate))]
private static UnicodeCombiningClass CombiningClassProxyImplementation (IntPtr ufuncs, uint unicode, void* context)
private static int CombiningClassProxyImplementation (IntPtr ufuncs, uint unicode, void* context)
{
GetMultiUserData<CombiningClassDelegate, UnicodeFunctions> ((IntPtr)context, out var del, out var functions, out _);
return del.Invoke (functions, unicode);
return (int)del.Invoke (functions, unicode);
}

[MonoPInvokeCallback (typeof (UnicodeGeneralCategoryProxyDelegate))]
private static UnicodeGeneralCategory GeneralCategoryProxyImplementation (IntPtr ufuncs, uint unicode, void* context)
private static int GeneralCategoryProxyImplementation (IntPtr ufuncs, uint unicode, void* context)
{
GetMultiUserData<GeneralCategoryDelegate, UnicodeFunctions> ((IntPtr)context, out var del, out var functions, out _);
return del.Invoke (functions, unicode);
return (int)del.Invoke (functions, unicode);
}

[MonoPInvokeCallback (typeof (UnicodeMirroringProxyDelegate))]
Expand Down
134 changes: 132 additions & 2 deletions binding/HarfBuzzSharp.Shared/HarfBuzzApi.generated.cs
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,34 @@ internal static hb_blob_t hb_blob_create_from_file ([MarshalAs (UnmanagedType.LP
(hb_blob_create_from_file_delegate ??= GetSymbol<Delegates.hb_blob_create_from_file> ("hb_blob_create_from_file")).Invoke (file_name);
#endif

// extern hb_blob_t* hb_blob_create_from_file_or_fail(const char* file_name)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
internal static extern hb_blob_t hb_blob_create_from_file_or_fail (/* char */ void* file_name);
#else
private partial class Delegates {
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
internal delegate hb_blob_t hb_blob_create_from_file_or_fail (/* char */ void* file_name);
}
private static Delegates.hb_blob_create_from_file_or_fail hb_blob_create_from_file_or_fail_delegate;
internal static hb_blob_t hb_blob_create_from_file_or_fail (/* char */ void* file_name) =>
(hb_blob_create_from_file_or_fail_delegate ??= GetSymbol<Delegates.hb_blob_create_from_file_or_fail> ("hb_blob_create_from_file_or_fail")).Invoke (file_name);
#endif

// extern hb_blob_t* hb_blob_create_or_fail(const char* data, unsigned int length, hb_memory_mode_t mode, void* user_data, hb_destroy_func_t destroy)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
internal static extern hb_blob_t hb_blob_create_or_fail (/* char */ void* data, UInt32 length, MemoryMode mode, void* user_data, DestroyProxyDelegate destroy);
#else
private partial class Delegates {
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
internal delegate hb_blob_t hb_blob_create_or_fail (/* char */ void* data, UInt32 length, MemoryMode mode, void* user_data, DestroyProxyDelegate destroy);
}
private static Delegates.hb_blob_create_or_fail hb_blob_create_or_fail_delegate;
internal static hb_blob_t hb_blob_create_or_fail (/* char */ void* data, UInt32 length, MemoryMode mode, void* user_data, DestroyProxyDelegate destroy) =>
(hb_blob_create_or_fail_delegate ??= GetSymbol<Delegates.hb_blob_create_or_fail> ("hb_blob_create_or_fail")).Invoke (data, length, mode, user_data, destroy);
#endif

// extern hb_blob_t* hb_blob_create_sub_blob(hb_blob_t* parent, unsigned int offset, unsigned int length)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
Expand Down Expand Up @@ -354,6 +382,22 @@ internal static bool hb_buffer_deserialize_glyphs (hb_buffer_t buffer, [MarshalA
(hb_buffer_deserialize_glyphs_delegate ??= GetSymbol<Delegates.hb_buffer_deserialize_glyphs> ("hb_buffer_deserialize_glyphs")).Invoke (buffer, buf, buf_len, end_ptr, font, format);
#endif

// extern hb_bool_t hb_buffer_deserialize_unicode(hb_buffer_t* buffer, const char* buf, int buf_len, const char** end_ptr, hb_buffer_serialize_format_t format)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
[return: MarshalAs (UnmanagedType.I1)]
internal static extern bool hb_buffer_deserialize_unicode (hb_buffer_t buffer, /* char */ void* buf, Int32 buf_len, /* char */ void** end_ptr, SerializeFormat format);
#else
private partial class Delegates {
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
[return: MarshalAs (UnmanagedType.I1)]
internal delegate bool hb_buffer_deserialize_unicode (hb_buffer_t buffer, /* char */ void* buf, Int32 buf_len, /* char */ void** end_ptr, SerializeFormat format);
}
private static Delegates.hb_buffer_deserialize_unicode hb_buffer_deserialize_unicode_delegate;
internal static bool hb_buffer_deserialize_unicode (hb_buffer_t buffer, /* char */ void* buf, Int32 buf_len, /* char */ void** end_ptr, SerializeFormat format) =>
(hb_buffer_deserialize_unicode_delegate ??= GetSymbol<Delegates.hb_buffer_deserialize_unicode> ("hb_buffer_deserialize_unicode")).Invoke (buffer, buf, buf_len, end_ptr, format);
#endif

// extern void hb_buffer_destroy(hb_buffer_t* buffer)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
Expand Down Expand Up @@ -578,6 +622,22 @@ internal static void hb_buffer_guess_segment_properties (hb_buffer_t buffer) =>
(hb_buffer_guess_segment_properties_delegate ??= GetSymbol<Delegates.hb_buffer_guess_segment_properties> ("hb_buffer_guess_segment_properties")).Invoke (buffer);
#endif

// extern hb_bool_t hb_buffer_has_positions(hb_buffer_t* buffer)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
[return: MarshalAs (UnmanagedType.I1)]
internal static extern bool hb_buffer_has_positions (hb_buffer_t buffer);
#else
private partial class Delegates {
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
[return: MarshalAs (UnmanagedType.I1)]
internal delegate bool hb_buffer_has_positions (hb_buffer_t buffer);
}
private static Delegates.hb_buffer_has_positions hb_buffer_has_positions_delegate;
internal static bool hb_buffer_has_positions (hb_buffer_t buffer) =>
(hb_buffer_has_positions_delegate ??= GetSymbol<Delegates.hb_buffer_has_positions> ("hb_buffer_has_positions")).Invoke (buffer);
#endif

// extern void hb_buffer_normalize_glyphs(hb_buffer_t* buffer)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
Expand Down Expand Up @@ -678,6 +738,20 @@ internal static void hb_buffer_reverse_range (hb_buffer_t buffer, UInt32 start,
(hb_buffer_reverse_range_delegate ??= GetSymbol<Delegates.hb_buffer_reverse_range> ("hb_buffer_reverse_range")).Invoke (buffer, start, end);
#endif

// extern unsigned int hb_buffer_serialize(hb_buffer_t* buffer, unsigned int start, unsigned int end, char* buf, unsigned int buf_size, unsigned int* buf_consumed, hb_font_t* font, hb_buffer_serialize_format_t format, hb_buffer_serialize_flags_t flags)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
internal static extern UInt32 hb_buffer_serialize (hb_buffer_t buffer, UInt32 start, UInt32 end, /* char */ void* buf, UInt32 buf_size, UInt32* buf_consumed, hb_font_t font, SerializeFormat format, SerializeFlag flags);
#else
private partial class Delegates {
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
internal delegate UInt32 hb_buffer_serialize (hb_buffer_t buffer, UInt32 start, UInt32 end, /* char */ void* buf, UInt32 buf_size, UInt32* buf_consumed, hb_font_t font, SerializeFormat format, SerializeFlag flags);
}
private static Delegates.hb_buffer_serialize hb_buffer_serialize_delegate;
internal static UInt32 hb_buffer_serialize (hb_buffer_t buffer, UInt32 start, UInt32 end, /* char */ void* buf, UInt32 buf_size, UInt32* buf_consumed, hb_font_t font, SerializeFormat format, SerializeFlag flags) =>
(hb_buffer_serialize_delegate ??= GetSymbol<Delegates.hb_buffer_serialize> ("hb_buffer_serialize")).Invoke (buffer, start, end, buf, buf_size, buf_consumed, font, format, flags);
#endif

// extern hb_buffer_serialize_format_t hb_buffer_serialize_format_from_string(const char* str, int len)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
Expand Down Expand Up @@ -734,6 +808,20 @@ private partial class Delegates {
(hb_buffer_serialize_list_formats_delegate ??= GetSymbol<Delegates.hb_buffer_serialize_list_formats> ("hb_buffer_serialize_list_formats")).Invoke ();
#endif

// extern unsigned int hb_buffer_serialize_unicode(hb_buffer_t* buffer, unsigned int start, unsigned int end, char* buf, unsigned int buf_size, unsigned int* buf_consumed, hb_buffer_serialize_format_t format, hb_buffer_serialize_flags_t flags)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
internal static extern UInt32 hb_buffer_serialize_unicode (hb_buffer_t buffer, UInt32 start, UInt32 end, /* char */ void* buf, UInt32 buf_size, UInt32* buf_consumed, SerializeFormat format, SerializeFlag flags);
#else
private partial class Delegates {
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
internal delegate UInt32 hb_buffer_serialize_unicode (hb_buffer_t buffer, UInt32 start, UInt32 end, /* char */ void* buf, UInt32 buf_size, UInt32* buf_consumed, SerializeFormat format, SerializeFlag flags);
}
private static Delegates.hb_buffer_serialize_unicode hb_buffer_serialize_unicode_delegate;
internal static UInt32 hb_buffer_serialize_unicode (hb_buffer_t buffer, UInt32 start, UInt32 end, /* char */ void* buf, UInt32 buf_size, UInt32* buf_consumed, SerializeFormat format, SerializeFlag flags) =>
(hb_buffer_serialize_unicode_delegate ??= GetSymbol<Delegates.hb_buffer_serialize_unicode> ("hb_buffer_serialize_unicode")).Invoke (buffer, start, end, buf, buf_size, buf_consumed, format, flags);
#endif

// extern void hb_buffer_set_cluster_level(hb_buffer_t* buffer, hb_buffer_cluster_level_t cluster_level)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
Expand Down Expand Up @@ -2208,6 +2296,20 @@ internal static bool hb_font_get_nominal_glyph (hb_font_t font, UInt32 unicode,
(hb_font_get_nominal_glyph_delegate ??= GetSymbol<Delegates.hb_font_get_nominal_glyph> ("hb_font_get_nominal_glyph")).Invoke (font, unicode, glyph);
#endif

// extern unsigned int hb_font_get_nominal_glyphs(hb_font_t* font, unsigned int count, const hb_codepoint_t* first_unicode, unsigned int unicode_stride, hb_codepoint_t* first_glyph, unsigned int glyph_stride)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
internal static extern UInt32 hb_font_get_nominal_glyphs (hb_font_t font, UInt32 count, UInt32* first_unicode, UInt32 unicode_stride, UInt32* first_glyph, UInt32 glyph_stride);
#else
private partial class Delegates {
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
internal delegate UInt32 hb_font_get_nominal_glyphs (hb_font_t font, UInt32 count, UInt32* first_unicode, UInt32 unicode_stride, UInt32* first_glyph, UInt32 glyph_stride);
}
private static Delegates.hb_font_get_nominal_glyphs hb_font_get_nominal_glyphs_delegate;
internal static UInt32 hb_font_get_nominal_glyphs (hb_font_t font, UInt32 count, UInt32* first_unicode, UInt32 unicode_stride, UInt32* first_glyph, UInt32 glyph_stride) =>
(hb_font_get_nominal_glyphs_delegate ??= GetSymbol<Delegates.hb_font_get_nominal_glyphs> ("hb_font_get_nominal_glyphs")).Invoke (font, count, first_unicode, unicode_stride, first_glyph, glyph_stride);
#endif

// extern hb_font_t* hb_font_get_parent(hb_font_t* font)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
Expand Down Expand Up @@ -3244,6 +3346,20 @@ internal static void hb_ot_layout_lookup_collect_glyphs (hb_face_t face, UInt32
(hb_ot_layout_lookup_collect_glyphs_delegate ??= GetSymbol<Delegates.hb_ot_layout_lookup_collect_glyphs> ("hb_ot_layout_lookup_collect_glyphs")).Invoke (face, table_tag, lookup_index, glyphs_before, glyphs_input, glyphs_after, glyphs_output);
#endif

// extern unsigned int hb_ot_layout_lookup_get_glyph_alternates(hb_face_t* face, unsigned int lookup_index, hb_codepoint_t glyph, unsigned int start_offset, unsigned int* alternate_count, hb_codepoint_t* alternate_glyphs)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
internal static extern UInt32 hb_ot_layout_lookup_get_glyph_alternates (hb_face_t face, UInt32 lookup_index, UInt32 glyph, UInt32 start_offset, UInt32* alternate_count, UInt32* alternate_glyphs);
#else
private partial class Delegates {
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
internal delegate UInt32 hb_ot_layout_lookup_get_glyph_alternates (hb_face_t face, UInt32 lookup_index, UInt32 glyph, UInt32 start_offset, UInt32* alternate_count, UInt32* alternate_glyphs);
}
private static Delegates.hb_ot_layout_lookup_get_glyph_alternates hb_ot_layout_lookup_get_glyph_alternates_delegate;
internal static UInt32 hb_ot_layout_lookup_get_glyph_alternates (hb_face_t face, UInt32 lookup_index, UInt32 glyph, UInt32 start_offset, UInt32* alternate_count, UInt32* alternate_glyphs) =>
(hb_ot_layout_lookup_get_glyph_alternates_delegate ??= GetSymbol<Delegates.hb_ot_layout_lookup_get_glyph_alternates> ("hb_ot_layout_lookup_get_glyph_alternates")).Invoke (face, lookup_index, glyph, start_offset, alternate_count, alternate_glyphs);
#endif

// extern void hb_ot_layout_lookup_substitute_closure(hb_face_t* face, unsigned int lookup_index, hb_set_t* glyphs)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
Expand Down Expand Up @@ -3846,6 +3962,20 @@ internal static void hb_set_clear (hb_set_t set) =>
(hb_set_clear_delegate ??= GetSymbol<Delegates.hb_set_clear> ("hb_set_clear")).Invoke (set);
#endif

// extern hb_set_t* hb_set_copy(const hb_set_t* set)
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
internal static extern hb_set_t hb_set_copy (hb_set_t set);
#else
private partial class Delegates {
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
internal delegate hb_set_t hb_set_copy (hb_set_t set);
}
private static Delegates.hb_set_copy hb_set_copy_delegate;
internal static hb_set_t hb_set_copy (hb_set_t set) =>
(hb_set_copy_delegate ??= GetSymbol<Delegates.hb_set_copy> ("hb_set_copy")).Invoke (set);
#endif

// extern hb_set_t* hb_set_create()
#if !USE_DELEGATES
[DllImport (HARFBUZZ, CallingConvention = CallingConvention.Cdecl)]
Expand Down Expand Up @@ -4639,7 +4769,7 @@ private partial class Delegates {

// typedef hb_unicode_combining_class_t (*)(hb_unicode_funcs_t* ufuncs, hb_codepoint_t unicode, void* user_data)* hb_unicode_combining_class_func_t
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
internal unsafe delegate UnicodeCombiningClass UnicodeCombiningClassProxyDelegate(hb_unicode_funcs_t ufuncs, UInt32 unicode, void* user_data);
internal unsafe delegate int UnicodeCombiningClassProxyDelegate(hb_unicode_funcs_t ufuncs, UInt32 unicode, void* user_data);

// typedef hb_bool_t (*)(hb_unicode_funcs_t* ufuncs, hb_codepoint_t a, hb_codepoint_t b, hb_codepoint_t* ab, void* user_data)* hb_unicode_compose_func_t
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
Expand All @@ -4661,7 +4791,7 @@ private partial class Delegates {

// typedef hb_unicode_general_category_t (*)(hb_unicode_funcs_t* ufuncs, hb_codepoint_t unicode, void* user_data)* hb_unicode_general_category_func_t
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
internal unsafe delegate UnicodeGeneralCategory UnicodeGeneralCategoryProxyDelegate(hb_unicode_funcs_t ufuncs, UInt32 unicode, void* user_data);
internal unsafe delegate int UnicodeGeneralCategoryProxyDelegate(hb_unicode_funcs_t ufuncs, UInt32 unicode, void* user_data);

// typedef hb_codepoint_t (*)(hb_unicode_funcs_t* ufuncs, hb_codepoint_t unicode, void* user_data)* hb_unicode_mirroring_func_t
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
Expand Down
15 changes: 15 additions & 0 deletions binding/libHarfBuzzSharp.json
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,11 @@
"_HB_OT_META_TAG_MAX_VALUE": ""
}
},
"hb_ot_layout_baseline_tag_t": {
"members": {
"_HB_OT_LAYOUT_BASELINE_TAG_MAX_VALUE": ""
}
},
"hb_ot_var_axis_flags_t": {
"members": {
"_HB_OT_VAR_AXIS_FLAG_MAX_VALUE": ""
Expand Down Expand Up @@ -208,6 +213,16 @@
}
},
"functions": {
"hb_unicode_combining_class_func_t": {
"parameters": {
"-1": "int"
}
},
"hb_unicode_general_category_func_t": {
"parameters": {
"-1": "int"
}
},
"hb_font_get_glyph_from_name": {
"parameters": {
"1": "[MarshalAs (UnmanagedType.LPStr)] String"
Expand Down
2 changes: 1 addition & 1 deletion scripts/azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ variables:
XCODE_VERSION: 12.4
DOTNET_VERSION_PREVIOUS: 3.1.413
DOTNET_VERSION: 5.0.401
DOTNET_VERSION_PREVIEW: 6.0.100-rtm.21525.3
DOTNET_VERSION_PREVIEW: 6.0.100
DOTNET_WORKLOAD_SOURCE: 'https://aka.ms/dotnet/maui/6.0.101/preview.10.json'
VS_VERSION_PREVIEW: 17/pre
CONFIGURATION: 'Release'
Expand Down
24 changes: 12 additions & 12 deletions scripts/azure-templates-bootstrapper.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ parameters:
condition: succeeded() # whether or not to run this template
shouldPublish: true # whether or not to publish the artifacts
configuration: $(CONFIGURATION) # the build configuration
buildExternals: '' # the build number to download externals from
buildExternals: '5425298' # the build number to download externals from
verbosity: $(VERBOSITY) # the level of verbosity to use when building
docker: '' # the Docker image to build and use
dockerArgs: '' # any additional arguments to pass to docker build
Expand All @@ -31,18 +31,18 @@ parameters:
artifactName: '' # the name of the artifact to merge this run into

jobs:
# - ${{ if startsWith(parameters.name, 'native_') }}:
# - template: azure-templates-download.yml
# parameters:
# name: ${{ parameters.name }}
# displayName: ${{ parameters.displayName }}
# vmImage: ${{ parameters.vmImage }}
# condition: ${{ parameters.condition }}
# postBuildSteps: ${{ parameters.postBuildSteps }}
# buildExternals: ${{ parameters.buildExternals }}
# artifactName: ${{ parameters.artifactName }}
- ${{ if startsWith(parameters.name, 'native_') }}:
- template: azure-templates-download.yml
parameters:
name: ${{ parameters.name }}
displayName: ${{ parameters.displayName }}
vmImage: ${{ parameters.vmImage }}
condition: ${{ parameters.condition }}
postBuildSteps: ${{ parameters.postBuildSteps }}
buildExternals: ${{ parameters.buildExternals }}
artifactName: ${{ parameters.artifactName }}

# - ${{ if not(startsWith(parameters.name, 'native_')) }}:
- ${{ if not(startsWith(parameters.name, 'native_')) }}:
- job: ${{ parameters.name }}
displayName: ${{ parameters.displayName }}
timeoutInMinutes: 120
Expand Down
6 changes: 1 addition & 5 deletions scripts/install-dotnet-workloads.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,6 @@ Write-Host "Installing workloads..."
& dotnet workload install `
android ios tvos macos maccatalyst wasm-tools maui `
--from-rollback-file $SourceUrl `
--source https://aka.ms/dotnet6/nuget/index.json `
--source https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-dotnet-aspnetcore-7c57ecbd-3/nuget/v3/index.json `
--source https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-dotnet-runtime-4822e3c3-5/nuget/v3/index.json `
--source https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-dotnet-windowsdesktop-59fea7da-4/nuget/v3/index.json `
--source https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-dotnet-emsdk-1ec2e17f-4/nuget/v3/index.json
--source https://api.nuget.org/v3/index.json

exit $LASTEXITCODE