fix: install app in user Applications for discovery

This commit is contained in:
2026-10-18 20:02:46 +02:00
parent 015da6a33e
commit 0e860b2ef6
3 changed files with 13 additions and 7 deletions
+7 -4
View File
@@ -10,6 +10,7 @@ FF_LIBS = $(shell PKG_CONFIG_LIBDIR="$(DEPENDENCY_ROOT)/ffmpeg/lib/pkgconfig" pk
BUILD_DIR ?= .build BUILD_DIR ?= .build
DEBUG_FLAGS ?= -g DEBUG_FLAGS ?= -g
PREFIX ?= $(HOME)/.local PREFIX ?= $(HOME)/.local
APPDIR ?= $(HOME)/Applications
CXXFLAGS = -std=c++20 -mmacosx-version-min=15.0 -O2 $(DEBUG_FLAGS) -Wall -Wextra -Wno-unused-parameter $(FF_CFLAGS) CXXFLAGS = -std=c++20 -mmacosx-version-min=15.0 -O2 $(DEBUG_FLAGS) -Wall -Wextra -Wno-unused-parameter $(FF_CFLAGS)
FRAMEWORKS := -framework AppKit -framework AudioToolbox -framework CoreAudio -framework Metal -framework MetalKit -framework QuartzCore -framework MediaPlayer FRAMEWORKS := -framework AppKit -framework AudioToolbox -framework CoreAudio -framework Metal -framework MetalKit -framework QuartzCore -framework MediaPlayer
OBJECTS := $(BUILD_DIR)/player.o $(BUILD_DIR)/progress_reporter.o $(BUILD_DIR)/Output.o $(BUILD_DIR)/cast_media.o OBJECTS := $(BUILD_DIR)/player.o $(BUILD_DIR)/progress_reporter.o $(BUILD_DIR)/Output.o $(BUILD_DIR)/cast_media.o
@@ -44,11 +45,13 @@ release:
$(MAKE) BUILD_DIR=.build/release DEBUG_FLAGS= all $(MAKE) BUILD_DIR=.build/release DEBUG_FLAGS= all
install: release install: release
mkdir -p "$(PREFIX)/lib/terebi" "$(PREFIX)/bin" mkdir -p "$(APPDIR)" "$(PREFIX)/bin"
rm -f "$(PREFIX)/lib/terebi/terebi" rm -f "$(PREFIX)/lib/terebi/terebi"
rm -rf "$(PREFIX)/lib/terebi/terebi.app" rm -rf "$(PREFIX)/lib/terebi/terebi.app" "$(APPDIR)/terebi.app"
cp -R ".build/release/terebi.app" "$(PREFIX)/lib/terebi/terebi.app" cp -R ".build/release/terebi.app" "$(APPDIR)/terebi.app"
ln -sfn "$$(cd "$(PREFIX)" && pwd)/lib/terebi/terebi.app/Contents/MacOS/terebi-cli" "$(PREFIX)/bin/terebi" ln -sfn "$$(cd "$(APPDIR)" && pwd)/terebi.app/Contents/MacOS/terebi-cli" "$(PREFIX)/bin/terebi"
/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -f "$(APPDIR)/terebi.app"
mdimport "$(APPDIR)/terebi.app"
$(BUILD_DIR): $(BUILD_DIR):
mkdir -p "$@" mkdir -p "$@"
+4 -2
View File
@@ -20,12 +20,14 @@ The resulting `.build/terebi.app` is self-contained: copy the whole app to a com
### Install ### Install
```sh ```sh
make install # builds a release and installs under ~/.local make install # app: ~/Applications; CLI: ~/.local/bin
export PATH="$HOME/.local/bin:$PATH" export PATH="$HOME/.local/bin:$PATH"
terebi --help terebi --help
``` ```
Use `make install PREFIX="/custom/path"` to change the prefix, or `make release` for just `.build/release/terebi.app`. Installation places the app in `lib/terebi/terebi.app` and its CLI symlink in `bin/terebi`. Quit running players before updating. Installation builds a release, places `terebi.app` in `~/Applications`, registers it with Launch Services, and requests Spotlight indexing. The CLI symlink is `~/.local/bin/terebi`; any old app under `~/.local/lib/terebi` is removed. Quit running players before updating.
Use `make install APPDIR="/Applications"` to change the app directory (it must be writable), `PREFIX="/custom/path"` to change the CLI prefix (`bin/terebi`), or both. Use `make release` for just `.build/release/terebi.app`.
Builds are ad-hoc signed for personal use, not notarized. Bundled licenses and source archives are in the app's Resources; public binary redistribution requires a separate dependency/license audit, including the GPLv3+ standalone yt-dlp bundle. Builds are ad-hoc signed for personal use, not notarized. Bundled licenses and source archives are in the app's Resources; public binary redistribution requires a separate dependency/license audit, including the GPLv3+ standalone yt-dlp bundle.
+2 -1
View File
@@ -4,7 +4,8 @@
- native playback activity prevents idle system sleep; local video keeps the display awake, casting allows screensaver/display sleep; native assertion checks and loopback Cast transitions passed, physical idle-TV verification remains unverified - native playback activity prevents idle system sleep; local video keeps the display awake, casting allows screensaver/display sleep; native assertion checks and loopback Cast transitions passed, physical idle-TV verification remains unverified
- [x] add session-only local-file playlist support - [x] add session-only local-file playlist support
- multi-file Open/Finder/drop, natural filename order, editable queue sidebar, explicit append, previous/next and automatic advance; Cast navigation retains the receiver; UI/drag-drop and physical-Cast verification remain unverified - multi-file Open/Finder/drop, natural filename order, editable queue sidebar, explicit append, previous/next and automatic advance; Cast navigation retains the receiver; UI/drag-drop and physical-Cast verification remain unverified
- [ ] make sure the `make install` command installs the application (i can't find it in spotlight) - [x] make sure the `make install` command installs the application (i can't find it in spotlight)
- installs to ~/Applications, migrates the old hidden app, registers with Launch Services and requests Spotlight indexing; actual install, CLI, code signature, registration and Spotlight query passed; Spotlight UI remains unverified
- [ ] takes an awfully long time seek in local videos which i find weird, since seeking in streamed youtube videos is pretty much instant - [ ] takes an awfully long time seek in local videos which i find weird, since seeking in streamed youtube videos is pretty much instant
- [ ] in the "choose what to play" screen, we should change the youtube button to general streaming - [ ] in the "choose what to play" screen, we should change the youtube button to general streaming
- we can figure out the stream and how to handle it from the url (i.e. if youtube url, handle as youtube stream; if miruro url, handle accordingly) - we can figure out the stream and how to handle it from the url (i.e. if youtube url, handle as youtube stream; if miruro url, handle accordingly)