-
Notifications
You must be signed in to change notification settings - Fork 237
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
android + ios: missing patches (#1884)
* android: missing patches * ios: missing patches
- Loading branch information
1 parent
62f3a29
commit 07d382f
Showing
4 changed files
with
61 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
diff --git a/rts/ghc.mk b/rts/ghc.mk | ||
index 6d6ff4bb90..02d3c64ce9 100644 | ||
--- a/rts/ghc.mk | ||
+++ b/rts/ghc.mk | ||
@@ -415,6 +415,13 @@ rts_CC_OPTS += -fno-strict-aliasing | ||
|
||
rts_CC_OPTS += -fno-common | ||
|
||
+ | ||
+ifeq "$(TargetArch_CPP)" "aarch64" | ||
+ifeq "$(TargetOS_CPP)" "darwin" | ||
+rts_CC_OPTS += -mcpu=apple-a7 -march=armv8-a+norcpc | ||
+endif | ||
+endif | ||
+ | ||
ifeq "$(BeConservative)" "YES" | ||
rts_CC_OPTS += -DBE_CONSERVATIVE | ||
endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
diff --git a/rts/Linker.c b/rts/Linker.c | ||
index 727fe74..12a22d7 100644 | ||
--- a/rts/Linker.c | ||
+++ b/rts/Linker.c | ||
@@ -1810,6 +1810,8 @@ static HsInt resolveObjs_ (void) | ||
IF_DEBUG(linker, debugBelch("resolveObjs: start\n")); | ||
|
||
for (ObjectCode *oc = objects; oc; oc = oc->next) { | ||
+ if(oc->status == OBJECT_RESOLVED) | ||
+ continue; | ||
int r = ocTryLoad(oc); | ||
if (!r) | ||
{ | ||
diff --git a/rts/linker/Elf.c b/rts/linker/Elf.c | ||
index c3f9110..1b497af 100644 | ||
--- a/rts/linker/Elf.c | ||
+++ b/rts/linker/Elf.c | ||
@@ -963,10 +963,15 @@ ocGetNames_ELF ( ObjectCode* oc ) | ||
stab[j].st_size, stab[j].st_value, nm); | ||
} | ||
*/ | ||
- symbol->addr = (SymbolAddr*)( | ||
- (intptr_t) oc->sections[secno].start + | ||
- (intptr_t) symbol->elf_sym->st_value); | ||
- ASSERT(symbol->addr != 0x0); | ||
+ if(shndx == SHN_UNDEF && ELF_ST_BIND(symbol->elf_sym->st_info) == STB_WEAK) { | ||
+ symbol->addr = NULL; | ||
+ } else { | ||
+ symbol->addr = (SymbolAddr*)( | ||
+ (intptr_t) oc->sections[secno].start + | ||
+ (intptr_t) symbol->elf_sym->st_value); | ||
+ ASSERT(symbol->addr != 0x0); | ||
+ } | ||
+ | ||
if (ELF_ST_BIND(symbol->elf_sym->st_info) == STB_LOCAL) { | ||
isLocal = true; | ||
isWeak = false; |