Skip to content

Commit

Permalink
Fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
halx99 committed May 25, 2024
1 parent 8409cd9 commit 8d5c8bc
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 0 deletions.
6 changes: 6 additions & 0 deletions 1k/1kiss.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -1836,6 +1836,10 @@ if (!$setupOnly) {
}
$1k.println("cmake --build $BUILD_DIR $BUILD_ALL_OPTIONS")
cmake --build $BUILD_DIR $BUILD_ALL_OPTIONS | Out-Host
if (!$?) {
Set-Location $stored_cwd
exit $LASTEXITCODE
}

if ($options.i) {
$install_args = @($BUILD_DIR, '--config', $optimize_flag)
Expand Down Expand Up @@ -1948,3 +1952,5 @@ if (!$setupOnly) {
compilerID = $TOOLCHAIN_NAME
}
}

exit $LASTEXITCODE
6 changes: 6 additions & 0 deletions build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,12 @@ Foreach ($lib_name in $libs) {
$patch_script = Join-Path $_1k_root "src/$lib_name/patch1.ps1"
if (Test-Path $patch_script -PathType Leaf) {
&$patch_script $lib_src
} elseif(Test-Path (Join-Path $lib_src '.git')) {
$patches = Get-ChildItem (Split-Path $patch_script -Parent) -Filter '*.patch'
foreach($patch_file in $patches) {
println "apply patch: $patch_file"
git -C $lib_src apply $patch_file
}
}

$install_script = Join-Path $_1k_root "src/$lib_name/install1.ps1"
Expand Down
39 changes: 39 additions & 0 deletions src/cares/0001-fix-android-armv7-build.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
From ad736dcb4c30ea23da2363d13d385c0b34703124 Mon Sep 17 00:00:00 2001
From: halx99 <halx99@live.com>
Date: Sat, 25 May 2024 23:44:49 +0800
Subject: [PATCH] fix android armv7 build

---
src/lib/ares_event_configchg.c | 16 +++++++++++++++-
1 file changed, 15 insertions(+), 1 deletion(-)

diff --git a/src/lib/ares_event_configchg.c b/src/lib/ares_event_configchg.c
index dc6e465..eb53fe4 100644
--- a/src/lib/ares_event_configchg.c
+++ b/src/lib/ares_event_configchg.c
@@ -33,7 +33,21 @@ static void ares_event_configchg_reload(ares_event_thread_t *e)
ares_reinit(e->channel);
}

-#ifdef __linux__
+#ifdef __ANDROID__
+
+ares_status_t ares_event_configchg_init(ares_event_configchg_t **configchg,
+ ares_event_thread_t *e)
+{
+ /* No ability */
+ return ARES_ENOTIMP;
+}
+
+void ares_event_configchg_destroy(ares_event_configchg_t *configchg)
+{
+ /* No-op */
+}
+
+#elif defined(__linux__)

# include <sys/inotify.h>

--
2.39.0.windows.2

0 comments on commit 8d5c8bc

Please sign in to comment.