Skip to content

Commit

Permalink
Fix 'make ios'
Browse files Browse the repository at this point in the history
  • Loading branch information
radare committed Jun 26, 2023
1 parent 3f76032 commit 0dfa354
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 13 deletions.
18 changes: 7 additions & 11 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ else
IOS_ON_DEVICE_COMPILE=0
IOS_SYSROOT=$(shell xcrun --sdk iphoneos --show-sdk-path)
IOS_CC=$(shell xcrun --sdk iphoneos --find clang) $(IOS_CFLAGS)
IOS_STRIP=$(shell xcrun --sdk iphoneos strip)
IOS_STRIP=xcrun --sdk iphoneos strip
LDID=ldid2
endif

Expand All @@ -81,23 +81,19 @@ OBJS=fsmon.o main.o
all: macos

oldios:
$(IOS_CC) $(CFLAGS) -DTARGET_IOS=1 -o fsmon-ios $(SOURCES) \
-framework CoreFoundation \
-framework MobileCoreServices
$(IOS_CC) $(CFLAGS) -DTARGET_IOS=1 -o fsmon-ios $(SOURCES) -framework CoreFoundation -framework MobileCoreServices
$(IOS_STRIP) fsmon-ios
if [ $(IOS_ON_DEVICE_COMPILE) != 1 ]; \
then \
xcrun --sdk iphoneos codesign -f --entitlements ./entitlements.plist -s- fsmon-ios; \
fi

IOS_FRAMEWORKS=-framework CoreFoundation -weak_framework MobileCoreServices -weak_framework CoreServices
ios:
$(IOS_CC) $(CFLAGS) -DTARGET_IOS=1 -o fsmon-ios $(SOURCES) \
-framework CoreFoundation \
-weak_framework MobileCoreServices \
-weak_framework CoreServices
$(IOS_STRIP) fsmon-ios
if [ $(IOS_ON_DEVICE_COMPILE) != 1 ]; \
then \
$(IOS_CC) $(CFLAGS) -DTARGET_IOS=1 -o fsmon-ios $(SOURCES) $(IOS_FRAMEWORKS)
ls -l fsmon-ios
-$(IOS_STRIP) fsmon-ios
if [ $(IOS_ON_DEVICE_COMPILE) != 1 ]; then \
xcrun --sdk iphoneos codesign -f --entitlements ./entitlements.plist -s- fsmon-ios; \
fi
$(LDID) -Sentitlements.plist fsmon-ios
Expand Down
3 changes: 1 addition & 2 deletions backend/devfsev.c
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,6 @@ static bool fm_loop (FileMonitor *fm, FileMonitorCallback cb) {
}

for (; fm->running; ) {
int rewind = 0;
if (buf_idx == buf_end) {
buf_idx = 0;
} else if (buf_idx > 0) {
Expand All @@ -166,7 +165,7 @@ static bool fm_loop (FileMonitor *fm, FileMonitorCallback cb) {
buf_idx = 0;
} else {
memmove (buf, buf + buf_idx, (buf_end - buf_idx));
rewind = buf_idx = (buf_end - buf_idx);
buf_idx = (buf_end - buf_idx);
}
}
if (buf_idx > FM_BUFSIZE) {
Expand Down
2 changes: 2 additions & 0 deletions backend/kdebug/kdebug.c
Original file line number Diff line number Diff line change
Expand Up @@ -635,12 +635,14 @@ static void exit_usage(const char *myname) {
}
#endif

#if 0
int filemgr_index(type) {
if (type & 0x10000) {
return (((type >> 2) & 0x3fff) + 256);
}
return (((type >> 2) & 0x3fff));
}
#endif

static bool set_init(void) {
kd_regtype kr = {0};
Expand Down

0 comments on commit 0dfa354

Please sign in to comment.