Skip to content

Commit

Permalink
Update Sparkle
Browse files Browse the repository at this point in the history
  • Loading branch information
tekezo committed Sep 5, 2020
1 parent c1a07ef commit 9eeb107
Show file tree
Hide file tree
Showing 8 changed files with 32 additions and 10 deletions.
4 changes: 4 additions & 0 deletions .gitmodules
@@ -1,3 +1,7 @@
[submodule "src/vendor/Karabiner-DriverKit-VirtualHIDDevice"]
path = src/vendor/Karabiner-DriverKit-VirtualHIDDevice
url = https://github.com/pqrs-org/Karabiner-DriverKit-VirtualHIDDevice.git
[submodule "src/vendor/Sparkle"]
path = src/vendor/Sparkle
url = https://github.com/sparkle-project/Sparkle
ignore = dirty
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -107,7 +107,7 @@ System requirements to build Karabiner-Elements:

Karabiner-Elements uses some pre-built binaries in the source tree.

- `src/vendor/Sparkle/Sparkle.framework`
- `src/vendor/Karabiner-DriverKit-VirtualHIDDevice/dist/Karabiner-DriverKit-VirtualHIDDevice-*.dmg`

Above `make package` command does not rebuild these binaries.<br/>
(These binaries will be copied in the distributed package.)
Expand Down
8 changes: 4 additions & 4 deletions src/apps/Updater/CMakeLists.txt
Expand Up @@ -5,7 +5,7 @@ include (../../common.cmake)
project (Karabiner-Elements)

add_compile_options(
-F${CMAKE_CURRENT_LIST_DIR}/../../vendor/Sparkle
-F${CMAKE_CURRENT_LIST_DIR}/../../vendor/Sparkle/build/Build/Products/Release
)

include_directories(
Expand All @@ -19,7 +19,7 @@ add_executable(
src/main.m
Resources/MainMenu.xib
../share/Resources/app.icns
../../vendor/Sparkle/Sparkle.framework
../../vendor/Sparkle/build/Build/Products/Release/Sparkle.framework
)

set_source_files_properties(
Expand All @@ -31,7 +31,7 @@ set_source_files_properties(
)

set_source_files_properties(
../../vendor/Sparkle/Sparkle.framework
../../vendor/Sparkle/build/Build/Products/Release/Sparkle.framework
PROPERTIES
MACOSX_PACKAGE_LOCATION
Frameworks
Expand All @@ -54,7 +54,7 @@ set_target_properties(
target_link_libraries(
Karabiner-Elements
"-framework SystemConfiguration"
-F${CMAKE_CURRENT_LIST_DIR}/../../vendor/Sparkle
-F${CMAKE_CURRENT_LIST_DIR}/../../vendor/Sparkle/build/Build/Products/Release
"-framework Sparkle"
c++
)
4 changes: 1 addition & 3 deletions src/apps/Updater/Makefile
@@ -1,9 +1,7 @@
AUTOUPDATE_ICON = 'build_xcode/build/Release/Karabiner-Elements.app/Contents/Frameworks/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/AppIcon.icns'

all:
make -C ../lib/KarabinerKit
make -C ../../vendor
make build_xcode
install -m 644 ../share/Resources/app.icns $(AUTOUPDATE_ICON)

clean: clean_builds

Expand Down
5 changes: 4 additions & 1 deletion src/vendor/Makefile
@@ -1,5 +1,8 @@
all:
@echo 'Type "make update_cget"'
bash build-sparkle.sh

clean:
cd Sparkle && git clean -d -f -x

update_cget:
rm -rf cget
Expand Down
1 change: 1 addition & 0 deletions src/vendor/Sparkle
Submodule Sparkle added at f2fc72
16 changes: 16 additions & 0 deletions src/vendor/build-sparkle.sh
@@ -0,0 +1,16 @@
#!/bin/bash

cd "$(dirname $0)"
cd "$(pwd -P)"

#
# Sparkle
#

build=$(pwd)/Sparkle/build

if [[ -d "$build" ]]; then
echo "Sparkle is already built."
else
cd Sparkle && xcodebuild -scheme Distribution -configuration Release -derivedDataPath "$build" build
fi
2 changes: 1 addition & 1 deletion version
@@ -1 +1 @@
12.90.4
12.90.5

0 comments on commit 9eeb107

Please sign in to comment.