@@ -30,7 +30,8 @@ LINT = $(LINT_BIN) run -v --build-tags itest
3030
3131PKG := github.com/lightninglabs/lightning-node-connect
3232MOBILE_PKG := $(PKG ) /mobile
33- MOBILE_BUILD_DIR :=${GOPATH}/src/$(PKG ) /build
33+ MKFILE_DIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST ) ) ) )
34+ MOBILE_BUILD_DIR := $(MKFILE_DIR ) /build
3435IOS_BUILD_DIR := $(MOBILE_BUILD_DIR ) /ios
3536IOS_BUILD := $(IOS_BUILD_DIR ) /Lncmobile.xcframework
3637ANDROID_BUILD_DIR := $(MOBILE_BUILD_DIR ) /android
@@ -76,13 +77,18 @@ wasm:
7677 cd cmd/wasm-client; CGO_ENABLED=0 GOOS=js GOARCH=wasm go build -trimpath -ldflags=" $( LDFLAGS) " -tags=" $( RPC_TAGS) " -v -o wasm-client.wasm .
7778 $(CP ) cmd/wasm-client/wasm-client.wasm example/wasm-client.wasm
7879
80+ clean :
81+ @$(call print, "Cleaning up.")
82+ $(RM ) -r $(MOBILE_BUILD_DIR )
83+ $(RM ) -r ./reproducible-builds/
84+
7985apple :
80- @$(call print, "Building iOS and macOS cxframework ($(IOS_BUILD ) ) ." )
86+ @$(call print, "Building iOS and macOS xcframework ($(IOS_BUILD ) ) ." )
8187 mkdir -p $(IOS_BUILD_DIR )
8288 cd mobile; $(GOMOBILE_BIN ) bind -target=ios,iossimulator,macos -tags=" mobile $( DEV_TAGS) $( RPC_TAGS) " $(LDFLAGS_MOBILE ) -v -o $(IOS_BUILD ) $(MOBILE_PKG )
8389
8490ios :
85- @$(call print, "Building iOS cxframework ($(IOS_BUILD ) ) ." )
91+ @$(call print, "Building iOS xcframework ($(IOS_BUILD ) ) ." )
8692 mkdir -p $(IOS_BUILD_DIR )
8793 cd mobile; $(GOMOBILE_BIN ) bind -target=ios,iossimulator -tags=" mobile $( DEV_TAGS) $( RPC_TAGS) " $(LDFLAGS_MOBILE ) -v -o $(IOS_BUILD ) $(MOBILE_PKG )
8894 # modify library files for import without C++ modules
9298 sed -i.bak -E " s|$( IOS_STRING1) |$( IOS_STRING2) |g" $(IOS_FILE4 )
9399
94100macos :
95- @$(call print, "Building macOS cxframework ($(IOS_BUILD ) ) ." )
101+ @$(call print, "Building macOS xcframework ($(IOS_BUILD ) ) ." )
96102 mkdir -p $(IOS_BUILD_DIR )
97103 cd mobile; $(GOMOBILE_BIN ) bind -target=macos -tags=" mobile $( DEV_TAGS) $( RPC_TAGS) " $(LDFLAGS_MOBILE ) -v -o $(IOS_BUILD ) $(MOBILE_PKG )
98104
@@ -120,6 +126,10 @@ repro-wasm:
120126 # Remove the repro-wasm-image
121127 docker image rm repro-wasm-image
122128
129+ release : clean mobile repro-wasm
130+ @$(call print, "Building release binaries for $(tag ) .")
131+ ./scripts/release.sh $(tag )
132+
123133# =======
124134# TESTING
125135# =======
0 commit comments