Skip to content

Commit 0b5f110

Browse files
committed
chore: remove status-go mobile build logic
Move status-go build logic from mobile scripts to status-go repo. - #18377
1 parent c340193 commit 0b5f110

File tree

5 files changed

+39
-65
lines changed

5 files changed

+39
-65
lines changed

ci/Jenkinsfile.android

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,15 +63,21 @@ pipeline {
6363
}
6464

6565
stages {
66-
66+
67+
stage('Cleanup Workspace') {
68+
steps {
69+
sh './scripts/clean-git.sh'
70+
}
71+
}
72+
6773
stage('Fetch submodules') {
6874
steps {
6975
sh 'git submodule update --init --recursive'
7076
}
7177
}
7278

7379
stage('Build Android APK') {
74-
steps {
80+
steps {
7581
script {
7682
linux.bundle(target='mobile-build', verbose=params.VERBOSE)
7783
}

ci/Jenkinsfile.ios

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,13 @@ pipeline {
7070
}
7171

7272
stages {
73-
73+
74+
stage('Cleanup Workspace') {
75+
steps {
76+
sh './scripts/clean-git.sh'
77+
}
78+
}
79+
7480
stage('Fetch submodules') {
7581
steps {
7682
sh 'git submodule update --init --recursive'
@@ -113,7 +119,7 @@ pipeline {
113119
}
114120
}
115121
}
116-
}
122+
}
117123
}
118124

119125
post {

mobile/Makefile

Lines changed: 22 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
-include ./scripts/EnvVariables.mk
22
-include ./scripts/Common.mk
3+
4+
STATUS_GO_LIB := $(LIB_PATH)/libstatus$(LIB_EXT)
5+
36
$(info Configuring build system for $(OS) $(ARCH) with QT $(QT_MAJOR))
47

58
# default rule
@@ -9,25 +12,32 @@ iosdevice: IPHONE_SDK=iphoneos
912
iosdevice: default
1013

1114
# dependencies
12-
status-go: clean-status-go $(STATUS_GO_LIB)
1315
statusq: clean-statusq $(STATUS_Q_LIB)
1416
dotherside: clean-dotherside $(DOTHERSIDE_LIB)
1517
openssl: clean-openssl $(OPENSSL_LIB)
1618
qrcodegen: clean-qrcodegen $(QRCODEGEN_LIB)
1719
nim-status-client: clean-nim-status-client $(NIM_STATUS_CLIENT_LIB)
1820
status-desktop-rcc: clean-status-desktop-rcc $(STATUS_DESKTOP_RCC)
1921

20-
$(STATUS_GO_LIB): $(STATUS_GO_FILES) $(STATUS_GO_SCRIPT)
21-
@echo "Building Status Go"
22-
ifeq ($(OS),ios)
23-
@STATUS_GO=$(STATUS_GO) \
24-
CC="$(shell xcrun --sdk ${SDK} --find clang)" \
25-
CGO_CFLAGS="-arch ${ARCH} -isysroot $(shell xcrun --sdk ${IPHONE_SDK} --show-sdk-path) -miphoneos-version-min=${IOS_TARGET} -fembed-bitcode" \
26-
$(STATUS_GO_SCRIPT) $(HANDLE_OUTPUT)
27-
else
28-
@STATUS_GO=$(STATUS_GO) $(STATUS_GO_SCRIPT) $(HANDLE_OUTPUT)
22+
$(STATUS_GO_LIB):
23+
@echo "Building status-go mobile library"
24+
ifeq ($(OS),android)
25+
CC="$(CC)" $(MAKE) -C ../vendor/status-go statusgo-android-library \
26+
ARCH=$(ARCH) \
27+
ANDROID_NDK_ROOT="$(ANDROID_NDK_ROOT)" \
28+
ANDROID_API="$(ANDROID_API)" \
29+
HOST_OS="$(HOST_OS)" \
30+
SHELL=/bin/sh
31+
else ifeq ($(OS),ios)
32+
$(MAKE) -C ../vendor/status-go statusgo-ios-library \
33+
ARCH=$(ARCH) \
34+
IPHONE_SDK="$(IPHONE_SDK)" \
35+
IOS_TARGET="$(IOS_TARGET)" \
36+
SHELL=/bin/sh
2937
endif
30-
@echo "Status Go built $(STATUS_GO_LIB)"
38+
@echo "Copying library to mobile lib directory"
39+
@mkdir -p $(LIB_PATH)
40+
@cp ../vendor/status-go/build/bin/libstatus$(LIB_EXT) $(LIB_PATH)/libstatus$(LIB_EXT)
3141

3242
$(STATUS_Q_LIB): $(STATUS_Q_FILES) $(STATUS_Q_SCRIPT) $(STATUS_Q_UI_FILES)
3343
@echo "Building StatusQ"
@@ -73,7 +83,7 @@ makedir:
7383
all: $(TARGET)
7484

7585
.PHONY: clean
76-
clean: clean-status-go clean-statusq clean-dotherside clean-openssl clean-qrcodegen clean-nim-status-client clean-status-desktop-rcc
86+
clean: clean-statusq clean-dotherside clean-openssl clean-qrcodegen clean-nim-status-client clean-status-desktop-rcc
7787
@echo "Cleaning"
7888
@rm -rf $(ROOT_DIR)/bin $(ROOT_DIR)/build $(ROOT_DIR)/lib
7989

@@ -82,12 +92,6 @@ run: makedir $(TARGET)
8292
@echo "Running"
8393
@APP=$(TARGET) QT_MAJOR=$(QT_MAJOR) USE_QML_SERVER=$(USE_QML_SERVER) $(RUN_SCRIPT)
8494

85-
.PHONY: clean-status-go
86-
clean-status-go:
87-
@rm -f $(STATUS_GO_LIB)
88-
@rm -rf $(STATUS_GO)/build
89-
@make -C $(STATUS_DESKTOP) status-go-clean
90-
9195
.PHONY: clean-statusq
9296
clean-statusq:
9397
@rm -f $(STATUS_Q_LIB)

mobile/scripts/buildStatusGo.sh

Lines changed: 0 additions & 42 deletions
This file was deleted.

vendor/status-go

Submodule status-go updated 94 files

0 commit comments

Comments
 (0)