diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000..3e2a42a --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,223 @@ +name: build, test and release sqlite-js +on: + push: + workflow_dispatch: + +permissions: + contents: write + +jobs: + build: + runs-on: ${{ matrix.os }} + container: ${{ matrix.container && matrix.container || '' }} + name: ${{ matrix.name }}${{ matrix.arch && format('-{0}', matrix.arch) || '' }} build${{ matrix.arch != 'arm64-v8a' && matrix.name != 'ios-sim' && matrix.name != 'ios' && matrix.name != 'apple-xcframework' && ' + test' || ''}} + timeout-minutes: 20 + strategy: + fail-fast: false + matrix: + include: + - os: ubuntu-22.04 + arch: x86_64 + name: linux + - os: ubuntu-22.04-arm + arch: arm64 + name: linux + - os: ubuntu-22.04 + arch: x86_64 + name: linux-musl + container: alpine:latest + - os: ubuntu-22.04-arm + arch: arm64 + name: linux-musl + - os: macos-15 + name: macos + - os: windows-2022 + arch: x86_64 + name: windows + - os: ubuntu-22.04 + arch: arm64-v8a + name: android + make: PLATFORM=android ARCH=arm64-v8a + - os: ubuntu-22.04 + arch: x86_64 + name: android + make: PLATFORM=android ARCH=x86_64 + sqlite-amalgamation-zip: https://sqlite.org/2025/sqlite-amalgamation-3490100.zip + - os: macos-15 + name: ios + make: PLATFORM=ios + - os: macos-15 + name: ios-sim + make: PLATFORM=ios-sim + - os: macos-15 + name: apple-xcframework + make: xcframework + + defaults: + run: + shell: ${{ matrix.container && 'sh' || 'bash' }} + + steps: + + - uses: actions/checkout@v4.2.2 + + - name: windows install dependencies + if: matrix.name == 'windows' + run: choco install sqlite -y + + - name: macos install dependencies + if: matrix.name == 'macos' + run: brew link sqlite --force + + - name: linux-musl x86_64 install dependencies + if: matrix.name == 'linux-musl' && matrix.arch == 'x86_64' + run: apk update && apk add --no-cache gcc make sqlite musl-dev linux-headers + + - name: linux-musl arm64 setup container + if: matrix.name == 'linux-musl' && matrix.arch == 'arm64' + run: | + docker run -d --name alpine \ + --platform linux/arm64 \ + -v ${{ github.workspace }}:/workspace \ + -w /workspace \ + alpine:latest \ + tail -f /dev/null + docker exec alpine sh -c "apk update && apk add --no-cache gcc make sqlite musl-dev linux-headers" + + - name: build sqlite-js + run: ${{ matrix.name == 'linux-musl' && matrix.arch == 'arm64' && 'docker exec alpine' || '' }} make extension ${{ matrix.make && matrix.make || ''}} + + - name: create keychain for codesign + if: matrix.os == 'macos-15' + run: | + echo "${{ secrets.APPLE_CERTIFICATE }}" | base64 --decode > certificate.p12 + security create-keychain -p "${{ secrets.KEYCHAIN_PASSWORD }}" build.keychain + security default-keychain -s build.keychain + security unlock-keychain -p "${{ secrets.KEYCHAIN_PASSWORD }}" build.keychain + security import certificate.p12 -k build.keychain -P "${{ secrets.CERTIFICATE_PASSWORD }}" -T /usr/bin/codesign + security set-key-partition-list -S apple-tool:,apple:,codesign: -s -k "${{ secrets.KEYCHAIN_PASSWORD }}" build.keychain + + - name: codesign dylib + if: matrix.os == 'macos-15' && matrix.name != 'apple-xcframework' + run: codesign --sign "${{ secrets.APPLE_TEAM_ID }}" --timestamp --options runtime dist/js.dylib + + - name: codesign and notarize xcframework + if: matrix.name == 'apple-xcframework' + run: | + find dist/js.xcframework -name "*.framework" -exec echo "Signing: {}" \; -exec codesign --sign "${{ secrets.APPLE_TEAM_ID }}" --timestamp --options runtime {} \; # Sign each individual framework FIRST + codesign --sign "${{ secrets.APPLE_TEAM_ID }}" --timestamp --options runtime dist/js.xcframework # Then sign the xcframework wrapper + ditto -c -k --keepParent dist/js.xcframework dist/js.xcframework.zip + xcrun notarytool submit dist/js.xcframework.zip --apple-id "${{ secrets.APPLE_ID }}" --password "${{ secrets.APPLE_PASSWORD }}" --team-id "${{ secrets.APPLE_TEAM_ID }}" --wait + rm dist/js.xcframework.zip + + - name: cleanup keychain for codesign + if: matrix.os == 'macos-15' + run: | + rm certificate.p12 + security delete-keychain build.keychain + + - name: android setup test environment + if: matrix.name == 'android' && matrix.arch != 'arm64-v8a' + run: | + + echo "::group::enable kvm group perms" + echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules + sudo udevadm control --reload-rules + sudo udevadm trigger --name-match=kvm + echo "::endgroup::" + + echo "::group::download and build sqlite3 without SQLITE_OMIT_LOAD_EXTENSION" + curl -O ${{ matrix.sqlite-amalgamation-zip }} + unzip sqlite-amalgamation-*.zip + export ${{ matrix.make }} + $ANDROID_NDK/toolchains/llvm/prebuilt/linux-x86_64/bin/${{ matrix.arch }}-linux-android26-clang sqlite-amalgamation-*/shell.c sqlite-amalgamation-*/sqlite3.c -o sqlite3 -ldl + # remove unused folders to save up space + rm -rf sqlite-amalgamation-*.zip sqlite-amalgamation-* + echo "::endgroup::" + + echo "::group::prepare the test script" + make test PLATFORM=$PLATFORM ARCH=$ARCH || echo "It should fail. Running remaining commands in the emulator" + cat > commands.sh << EOF + mv -f /data/local/tmp/sqlite3 /system/xbin + cd /data/local/tmp + $(make test PLATFORM=$PLATFORM ARCH=$ARCH -n) + EOF + echo "::endgroup::" + + - name: android test sqlite-js + if: matrix.name == 'android' && matrix.arch != 'arm64-v8a' + uses: reactivecircus/android-emulator-runner@v2.34.0 + with: + api-level: 26 + arch: ${{ matrix.arch }} + script: | + adb root + adb remount + adb push ${{ github.workspace }}/. /data/local/tmp/ + adb shell "sh /data/local/tmp/commands.sh" + + - name: test sqlite-js + if: contains(matrix.name, 'linux') || matrix.name == 'windows' || matrix.name == 'macos' + run: ${{ matrix.name == 'linux-musl' && matrix.arch == 'arm64' && 'docker exec alpine' || '' }} make test ${{ matrix.make && matrix.make || ''}} + + - uses: actions/upload-artifact@v4.6.2 + if: always() + with: + name: js-${{ matrix.name }}${{ matrix.arch && format('-{0}', matrix.arch) || '' }} + path: dist/js.* + if-no-files-found: error + + release: + runs-on: ubuntu-22.04 + name: release + needs: build + if: github.ref == 'refs/heads/main' + + env: + GH_TOKEN: ${{ github.token }} + + steps: + + - uses: actions/checkout@v4.2.2 + + - uses: actions/download-artifact@v4.2.1 + with: + path: artifacts + + - name: release tag version from sqlitejs.h + id: tag + run: | + VERSION=$(make version) + if [[ "$VERSION" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then + LATEST=$(curl -s -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" https://api.github.com/repos/${{ github.repository }}/releases/latest | jq -r '.name') + if [[ "$VERSION" != "$LATEST" || "$GITHUB_EVENT_NAME" == "workflow_dispatch" ]]; then + echo "version=$VERSION" >> $GITHUB_OUTPUT + else + echo "::warning file=src/sqlitejs.h::To release a new version, please update the SQLITE_JS_VERSION in src/sqlitejs.h to be different than the latest $LATEST" + fi + exit 0 + fi + echo "❌ SQLITE_JS_VERSION not found in sqlitejs.h" + exit 1 + + - name: zip artifacts + run: | + for folder in "artifacts"/*; do + if [ -d "$folder" ]; then + name=$(basename "$folder") + if [[ "$name" != "js-apple-xcframework" ]]; then + tar -czf "${name}-${{ steps.tag.outputs.version }}.tar.gz" -C "$folder" . + fi + (cd "$folder" && zip -rq "../../${name}-${{ steps.tag.outputs.version }}.zip" .) + fi + done + + - uses: softprops/action-gh-release@v2.2.1 + if: steps.tag.outputs.version != '' + with: + generate_release_notes: true + tag_name: ${{ steps.tag.outputs.version }} + files: | + js-*-${{ steps.tag.outputs.version }}.zip + js-*-${{ steps.tag.outputs.version }}.tar.gz + make_latest: true diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml deleted file mode 100644 index a477230..0000000 --- a/.github/workflows/release.yml +++ /dev/null @@ -1,172 +0,0 @@ -name: release sqlite-js -on: - push: - -permissions: - contents: write - -jobs: - build: - runs-on: ${{ matrix.os }} - name: ${{ matrix.name }}${{ matrix.arch && format('-{0}', matrix.arch) || '' }} build${{ matrix.arch != 'arm64-v8a' && matrix.name != 'isim' && matrix.name != 'ios' && ' + test' || ''}} - timeout-minutes: 20 - strategy: - fail-fast: false - matrix: - include: - - os: macos-latest - name: isim - make: PLATFORM=isim - - os: macos-latest - name: ios - make: PLATFORM=ios - - os: ubuntu-latest - arch: arm64-v8a - name: android - make: - PLATFORM=android - CC=$ANDROID_NDK/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android26-clang - - os: ubuntu-latest - arch: x86_64 - name: android - make: - PLATFORM=android - CC=$ANDROID_NDK/toolchains/llvm/prebuilt/linux-x86_64/bin/x86_64-linux-android26-clang - sqlite-amalgamation-zip: https://sqlite.org/2025/sqlite-amalgamation-3490100.zip - - os: ubuntu-latest - arch: x86_64 - name: linux - - os: LinuxARM64 - arch: arm64 - name: linux - - os: macos-latest - name: macos - - os: windows-latest - arch: x86_64 - name: windows - - defaults: - run: - shell: bash - env: - MAKEFLAGS: -j 8 - - steps: - - - uses: actions/checkout@v4.2.2 - - - name: build sqlite-js - run: make ${{ matrix.make && matrix.make || ''}} - - - name: windows install sqlite3 - if: matrix.os == 'windows-latest' - run: choco install sqlite -y - - - name: macos install sqlite3 without SQLITE_OMIT_LOAD_EXTENSION - if: matrix.name == 'macos' - run: brew link sqlite --force - - - name: android setup test environment - if: matrix.name == 'android' && matrix.arch != 'arm64-v8a' - run: | - - echo "::group::enable kvm group perms" - echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules - sudo udevadm control --reload-rules - sudo udevadm trigger --name-match=kvm - echo "::endgroup::" - - echo "::group::download and build sqlite3 without SQLITE_OMIT_LOAD_EXTENSION" - curl -O ${{ matrix.sqlite-amalgamation-zip }} - unzip sqlite-amalgamation-*.zip - export ${{ matrix.make }} - $CC sqlite-amalgamation-*/shell.c sqlite-amalgamation-*/sqlite3.c -o sqlite3 -ldl - rm -rf sqlite-amalgamation-*.zip sqlite-amalgamation-* - echo "::endgroup::" - - echo "::group::prepare the test script" - make test CC=$CC PLATFORM=$PLATFORM || echo "It should fail. Running remaining commands in the emulator" - cat > commands.sh << EOF - mv -f /data/local/tmp/sqlite3 /system/xbin - cd /data/local/tmp - $(make test CC=$CC PLATFORM=$PLATFORM -n) - EOF - echo "::endgroup::" - - - name: android test sqlite-js - if: matrix.name == 'android' && matrix.arch != 'arm64-v8a' - uses: reactivecircus/android-emulator-runner@v2.34.0 - with: - api-level: 26 - arch: ${{ matrix.arch }} - script: | - adb root - adb remount - adb push ${{ github.workspace }}/. /data/local/tmp/ - adb shell "sh /data/local/tmp/commands.sh" - - - name: test sqlite-js - if: matrix.name == 'linux' || matrix.name == 'macos' || matrix.name == 'windows' - run: make test - - - uses: actions/upload-artifact@v4.6.2 - with: - name: js-${{ matrix.name }}${{ matrix.arch && format('-{0}', matrix.arch) || '' }} - path: dist/js.* - if-no-files-found: error - - release: - runs-on: ubuntu-latest - name: release - needs: build - if: github.ref == 'refs/heads/main' - - env: - GH_TOKEN: ${{ github.token }} - - steps: - - - uses: actions/checkout@v4.2.2 - - - uses: actions/download-artifact@v4.2.1 - with: - path: artifacts - - - name: release tag version from sqlitejs.h - id: tag - run: | - FILE="src/sqlitejs.h" - VERSION=$(grep -oP '#define SQLITE_JS_VERSION\s+"\K[^"]+' "$FILE") - if [[ "$VERSION" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then - LATEST=$(curl -s -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" https://api.github.com/repos/${{ github.repository }}/releases/latest | jq -r '.name') - if [[ "$VERSION" != "$LATEST" ]]; then - echo "version=$VERSION" >> $GITHUB_OUTPUT - else - echo "::warning file=src/sqlitejs.h::To release a new version, please update the SQLITE_JS_VERSION in src/sqlitejs.h to be different than the latest $LATEST" - fi - exit 0 - fi - echo "❌ SQLITE_JS_VERSION not found in sqlitejs.h" - exit 1 - - - name: zip artifacts - run: | - for folder in "artifacts"/*; do - if [ -d "$folder" ]; then - name=$(basename "$folder") - zip -jq "${name}-${{ steps.tag.outputs.version }}.zip" "$folder"/* - tar -cJf "${name}-${{ steps.tag.outputs.version }}.tar.xz" -C "$folder" . - tar -czf "${name}-${{ steps.tag.outputs.version }}.tar.gz" -C "$folder" . - fi - done - - - uses: softprops/action-gh-release@v2.2.1 - if: steps.tag.outputs.version != '' - with: - generate_release_notes: true - tag_name: ${{ steps.tag.outputs.version }} - files: | - js-*-${{ steps.tag.outputs.version }}.zip - js-*-${{ steps.tag.outputs.version }}.tar.xz - js-*-${{ steps.tag.outputs.version }}.tar.gz - make_latest: true diff --git a/Makefile b/Makefile index 018a298..d99786f 100644 --- a/Makefile +++ b/Makefile @@ -3,16 +3,23 @@ # Set default platform if not specified ifeq ($(OS),Windows_NT) - PLATFORM := windows + PLATFORM := windows + HOST := windows + CPUS := $(shell powershell -Command "[Environment]::ProcessorCount") else - UNAME_S := $(shell uname -s) - ifeq ($(UNAME_S),Darwin) - PLATFORM := macos - else - PLATFORM := linux - endif + HOST = $(shell uname -s | tr '[:upper:]' '[:lower:]') + ifeq ($(HOST),darwin) + PLATFORM := macos + CPUS := $(shell sysctl -n hw.ncpu) + else + PLATFORM := $(HOST) + CPUS := $(shell nproc) + endif endif +# Speed up builds by using all available CPU cores +MAKEFLAGS += -j$(CPUS) + # Directories SRC_DIR := src LIB_DIR := libs @@ -31,40 +38,50 @@ CFLAGS := -Wall -Wextra -fPIC -g -O2 -DQJS_BUILD_LIBC $(INCLUDES) # Platform-specific settings ifeq ($(PLATFORM),windows) - TARGET := $(DIST_DIR)/js.dll - LDFLAGS := -shared - # Create .def file for Windows - DEF_FILE := $(BUILD_DIR)/js.def + TARGET := $(DIST_DIR)/js.dll + LDFLAGS := -shared + # Create .def file for Windows + DEF_FILE := $(BUILD_DIR)/js.def + STRIP = strip --strip-unneeded $@ else ifeq ($(PLATFORM),macos) - TARGET := $(DIST_DIR)/js.dylib - LDFLAGS := -arch x86_64 -arch arm64 -dynamiclib -undefined dynamic_lookup - # macOS-specific flags - CFLAGS += -arch x86_64 -arch arm64 + TARGET := $(DIST_DIR)/js.dylib + LDFLAGS := -arch x86_64 -arch arm64 -dynamiclib -undefined dynamic_lookup + # macOS-specific flags + CFLAGS += -arch x86_64 -arch arm64 + STRIP = strip -x -S $@ else ifeq ($(PLATFORM),android) - # Use Android NDK's Clang compiler, the user should set the CC - # example CC=$ANDROID_NDK/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android26-clang - ifeq ($(filter %-clang,$(CC)),) - $(error "CC must be set to the Android NDK's Clang compiler") - endif - TARGET := $(DIST_DIR)/js.so - LDFLAGS := -shared -lm - # Android-specific flags - CFLAGS += -D__ANDROID__ + ifndef ARCH # Set ARCH to find Android NDK's Clang compiler, the user should set the ARCH + $(error "Android ARCH must be set to ARCH=x86_64 or ARCH=arm64-v8a") + endif + ifndef ANDROID_NDK # Set ANDROID_NDK path to find android build tools; e.g. on MacOS: export ANDROID_NDK=/Users/username/Library/Android/sdk/ndk/25.2.9519653 + $(error "Android NDK must be set") + endif + BIN = $(ANDROID_NDK)/toolchains/llvm/prebuilt/$(HOST)-x86_64/bin + ifneq (,$(filter $(ARCH),arm64 arm64-v8a)) + override ARCH := aarch64 + endif + CC = $(BIN)/$(ARCH)-linux-android26-clang + TARGET := $(DIST_DIR)/js.so + LDFLAGS := -lm -shared + STRIP = $(BIN)/llvm-strip --strip-unneeded $@ else ifeq ($(PLATFORM),ios) - TARGET := $(DIST_DIR)/js.dylib - SDK := -isysroot $(shell xcrun --sdk iphoneos --show-sdk-path) -miphoneos-version-min=11.0 - LDFLAGS := -dynamiclib $(SDK) - # iOS-specific flags - CFLAGS += -arch arm64 $(SDK) -else ifeq ($(PLATFORM),isim) - TARGET := $(DIST_DIR)/js.dylib - SDK := -isysroot $(shell xcrun --sdk iphonesimulator --show-sdk-path) -miphonesimulator-version-min=11.0 - LDFLAGS := -arch x86_64 -arch arm64 -dynamiclib $(SDK) - # iphonesimulator-specific flags - CFLAGS += -arch x86_64 -arch arm64 $(SDK) + TARGET := $(DIST_DIR)/js.dylib + SDK := -isysroot $(shell xcrun --sdk iphoneos --show-sdk-path) -miphoneos-version-min=11.0 + LDFLAGS := -dynamiclib $(SDK) + # iOS-specific flags + CFLAGS += -arch arm64 $(SDK) + STRIP = strip -x -S $@ +else ifeq ($(PLATFORM),ios-sim) + TARGET := $(DIST_DIR)/js.dylib + SDK := -isysroot $(shell xcrun --sdk iphonesimulator --show-sdk-path) -miphonesimulator-version-min=11.0 + LDFLAGS := -arch x86_64 -arch arm64 -dynamiclib $(SDK) + # iphonesimulator-specific flags + CFLAGS += -arch x86_64 -arch arm64 $(SDK) + STRIP = strip -x -S $@ else # linux - TARGET := $(DIST_DIR)/js.so - LDFLAGS := -lm -shared + TARGET := $(DIST_DIR)/js.so + LDFLAGS := -lm -shared + STRIP = strip --strip-unneeded $@ endif # Object files @@ -75,6 +92,7 @@ $(shell mkdir -p $(BUILD_DIR) $(DIST_DIR)) # Main target all: $(TARGET) +extension: $(TARGET) # Link the final target $(TARGET): $(OBJ_FILES) $(DEF_FILE) @@ -83,6 +101,8 @@ ifeq ($(PLATFORM),windows) # Generate import library for Windows dlltool -D $@ -d $(DEF_FILE) -l $(DIST_DIR)/js.lib endif + # Strip debug symbols + $(STRIP) # Compile source files $(BUILD_DIR)/%.o: $(SRC_DIR)/%.c @@ -138,25 +158,86 @@ test: $(TARGET) $(TEST_TARGET) sqlite3 ":memory:" -cmd ".bail on" ".load ./$<" "SELECT js_eval('console.log(\"hello, world\nToday is\", new Date().toLocaleDateString())');" ./$(TEST_TARGET) +.NOTPARALLEL: %.dylib +%.dylib: + rm -rf $(BUILD_DIR) && $(MAKE) PLATFORM=$* + mv $(DIST_DIR)/js.dylib $(DIST_DIR)/$@ + +define PLIST +\ +\ +\ +\ +CFBundleDevelopmentRegion\ +en\ +CFBundleExecutable\ +js\ +CFBundleIdentifier\ +ai.sqlite.js\ +CFBundleInfoDictionaryVersion\ +6.0\ +CFBundlePackageType\ +FMWK\ +CFBundleSignature\ +????\ +CFBundleVersion\ +$(shell make version)\ +CFBundleShortVersionString\ +$(shell make version)\ +MinimumOSVersion\ +11.0\ +\ + +endef + +define MODULEMAP +framework module js {\ + umbrella header \"sqlitejs.h\"\ + export *\ +} +endef + +LIB_NAMES = ios.dylib ios-sim.dylib macos.dylib +FMWK_NAMES = ios-arm64 ios-arm64_x86_64-simulator macos-arm64_x86_64 +$(DIST_DIR)/%.xcframework: $(LIB_NAMES) + @$(foreach i,1 2 3,\ + lib=$(word $(i),$(LIB_NAMES)); \ + fmwk=$(word $(i),$(FMWK_NAMES)); \ + mkdir -p $(DIST_DIR)/$$fmwk/js.framework/Headers; \ + mkdir -p $(DIST_DIR)/$$fmwk/js.framework/Modules; \ + cp src/sqlitejs.h $(DIST_DIR)/$$fmwk/js.framework/Headers; \ + printf "$(PLIST)" > $(DIST_DIR)/$$fmwk/js.framework/Info.plist; \ + printf "$(MODULEMAP)" > $(DIST_DIR)/$$fmwk/js.framework/Modules/module.modulemap; \ + mv $(DIST_DIR)/$$lib $(DIST_DIR)/$$fmwk/js.framework/js; \ + install_name_tool -id "@rpath/js.framework/js" $(DIST_DIR)/$$fmwk/js.framework/js; \ + ) + xcodebuild -create-xcframework $(foreach fmwk,$(FMWK_NAMES),-framework $(DIST_DIR)/$(fmwk)/js.framework) -output $@ + rm -rf $(foreach fmwk,$(FMWK_NAMES),$(DIST_DIR)/$(fmwk)) + +xcframework: $(DIST_DIR)/js.xcframework + +version: + @echo $(shell sed -n 's/^#define SQLITE_JS_VERSION[[:space:]]*"\([^"]*\)".*/\1/p' src/sqlitejs.h) + # Help message help: @echo "SQLite JavaScript Extension Makefile" @echo "Usage:" - @echo " make [PLATFORM=platform] [target]" + @echo " make [PLATFORM=platform] [ARCH=arch] [ANDROID_NDK=\$$ANDROID_HOME/ndk/26.1.10909125] [target]" @echo "" @echo "Platforms:" @echo " linux (default on Linux)" @echo " macos (default on macOS)" @echo " windows (default on Windows)" - @echo " android (needs CC to be set to Android NDK's Clang compiler)" + @echo " android (needs ARCH to be set to x86_64 or arm64-v8a and ANDROID_NDK to be set)" @echo " ios (only on macOS)" - @echo " isim (only on macOS)" + @echo " ios-sim (only on macOS)" @echo "" @echo "Targets:" - @echo " all - Build the extension (default)" - @echo " clean - Remove built files" - @echo " install - Install the extension" - @echo " test - Test the extension" - @echo " help - Display this help message" + @echo " all - Build the extension (default)" + @echo " clean - Remove built files" + @echo " install - Install the extension" + @echo " test - Test the extension" + @echo " help - Display this help message" -.PHONY: all clean install test help +.PHONY: all extension clean install test help version xcframework diff --git a/src/sqlitejs.h b/src/sqlitejs.h index 20d76b4..8f0cc55 100644 --- a/src/sqlitejs.h +++ b/src/sqlitejs.h @@ -16,7 +16,7 @@ #include "sqlite3.h" #endif -#define SQLITE_JS_VERSION "1.1.6" +#define SQLITE_JS_VERSION "1.1.7" int sqlite3_js_init (sqlite3 *db, char **pzErrMsg, const sqlite3_api_routines *pApi); const char *sqlitejs_version (void);