Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build(deps): updated deps (incl PyInstaller v6.2+ with fixes) #976

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 22 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ aw-qt/media/logo/logo.icns:
mv build/MyIcon.icns aw-qt/media/logo/logo.icns

dist/ActivityWatch.app: aw-qt/media/logo/logo.icns
pyinstaller --clean --noconfirm aw.spec
pyinstaller --clean --noconfirm --log-level DEBUG aw.spec
ErikBjare marked this conversation as resolved.
Show resolved Hide resolved

dist/ActivityWatch.dmg: dist/ActivityWatch.app
# NOTE: This does not codesign the dmg, that is done in the CI config
Expand All @@ -169,18 +169,35 @@ package:
mv aw-qt-tmp/* dist/activitywatch
rmdir aw-qt-tmp
# Remove problem-causing binaries
rm -f dist/activitywatch/libdrm.so.2 # see: https://github.com/ActivityWatch/activitywatch/issues/161
rm -f dist/activitywatch/libharfbuzz.so.0 # see: https://github.com/ActivityWatch/activitywatch/issues/660#issuecomment-959889230
rm -f dist/activitywatch/_internal/libdrm.so.2 # see: https://github.com/ActivityWatch/activitywatch/issues/161
rm -f dist/activitywatch/_internal/libharfbuzz.so.0 # see: https://github.com/ActivityWatch/activitywatch/issues/660#issuecomment-959889230
# These should be provided by the distro itself
# Had to be removed due to otherwise causing the error:
# aw-qt: symbol lookup error: /opt/activitywatch/libQt5XcbQpa.so.5: undefined symbol: FT_Get_Font_Format
rm -f dist/activitywatch/libfontconfig.so.1
rm -f dist/activitywatch/libfreetype.so.6
rm -f dist/activitywatch/_internal/libfontconfig.so.1
rm -f dist/activitywatch/_internal/libfreetype.so.6
# Check
make package-check
# Remove unnecessary files
rm -rf dist/activitywatch/pytz
# Builds zips and setups
bash scripts/package/package-all.sh

BADLIBS := \
libdrm.so.2 \
libharfbuzz.so.0 \
libfontconfig.so.1 \
libfreetype.so.6

package-check:
# check that the libs are gone everywhere
@for lib in $(BADLIBS); do \
if [ -n "$$(find dist/activitywatch -name $$lib)" ]; then \
echo "Error: $$lib found in $$(find dist/activitywatch -name $$lib)" >&2; \
exit 1; \
fi \
done

clean:
rm -rf build dist

Expand Down
16 changes: 8 additions & 8 deletions aw.spec
Original file line number Diff line number Diff line change
Expand Up @@ -168,14 +168,14 @@ aw_notify_a = build_analysis(
# https://pythonhosted.org/PyInstaller/spec-files.html#multipackage-bundles
# MERGE takes a bit weird arguments, it wants tuples which consists of
# the analysis paired with the script name and the bin name
MERGE(
(aw_server_a, "aw-server", "aw-server"),
(aw_qt_a, "aw-qt", "aw-qt"),
(aw_watcher_afk_a, "aw-watcher-afk", "aw-watcher-afk"),
(aw_watcher_window_a, "aw-watcher-window", "aw-watcher-window"),
(aw_watcher_input_a, "aw-watcher-input", "aw-watcher-input"),
(aw_notify_a, "aw-notify", "aw-notify"),
)
# MERGE(
# (aw_server_a, "aw-server", "aw-server"),
# (aw_qt_a, "aw-qt", "aw-qt"),
# (aw_watcher_afk_a, "aw-watcher-afk", "aw-watcher-afk"),
# (aw_watcher_window_a, "aw-watcher-window", "aw-watcher-window"),
# (aw_watcher_input_a, "aw-watcher-input", "aw-watcher-input"),
# (aw_notify_a, "aw-notify", "aw-notify"),
# )


# aw-server
Expand Down
Loading