umk: Using curl to fetch upphub instead of HttpRequest+Core/SSL (makes statically linked umk32s possible with upphub support)

This commit is contained in:
Mirek Fidler 2023-06-03 20:56:42 +02:00
parent 555e99a8d3
commit 02ce73828f
4 changed files with 13 additions and 6 deletions

View file

@ -127,7 +127,7 @@ CONSOLE_APP_MAIN
#endif
#ifdef PLATFORM_LINUX
Syx(GetHomeDirFile("bin/umk") + " ./uppsrc umk GCC32 " OPTS + "+NOSSL " + release + "/umks32");
Syx(GetHomeDirFile("bin/umk") + " ./uppsrc umk GCC32 " OPTS + release + "/umks32");
#endif
Syx(GetHomeDirFile("bin/umk") + " ./uppsrc umk GCC +NOMM -rvsM");

View file

@ -258,7 +258,7 @@ void Thread::DumpDiagnostics()
{
#ifdef PLATFORM_LINUX
INTERLOCKED {
int s, i;
int i;
void *stkaddr;
pthread_attr_t attr[1];

View file

@ -30,6 +30,13 @@ Value UppHubDlg::LoadJson(const String& url)
if(IsNull(s)) {
PutVerbose("Fetching UppHub metadata from " << url);
#ifdef PLATFORM_POSIX
s = Sys("curl --silent " + url);
if (IsNull(s)) {
String msg = "Failed to execute UppHub download nests request.";
return ErrorValue(msg);
}
#else
HttpRequest r(url);
r.Execute();
if (!r.IsSuccess()) {
@ -38,6 +45,7 @@ Value UppHubDlg::LoadJson(const String& url)
}
s = r.GetContent();
#endif
}
Value v = ParseJSON(s);

View file

@ -3,7 +3,7 @@ description "Commandline U++ package/assembly builder\377";
uses
ide\Builders;
uses(!NOSSL) Core/SSL;
uses(!POSIX) Core/SSL;
file
umake.h,
@ -16,6 +16,5 @@ file
mainconfig
"" = "",
"" = "NOMM",
"" = "NOSSL";
"" = "NOMM";