4
15
Fork
You've already forked app
3

macOS build fails #1

Closed
opened 2026年06月11日 07:55:25 +02:00 by NSBuitrago · 0 comments
Contributor
Copy link

What happened

macOS builds currently fail due to issues using NSColor trait as a type. I fixed this issue by using NSColor access with objc2 and objc2-app-kit crates in favor of the deprecated objc and cocoa crates. Happy to submit the PR for this if you are ok with updating these dependencies.

Steps to reproduce

  1. clone repository
  2. Install dependencies with npm install
  3. Setup tinymist side car with mkdir src-tauri/binaries && ./scripts/download-tinymist.sh
  4. Run development build with npm run tauri:dev

Expected behaviour

Successfully build InkyCap for macOS target.

Platform / OS

macOS 15.7.4

Install type

Built from source

InkyCap version

26.6.2

Notes, logs, or screenshots

main error message:

error[E0782]: expected a type, found a trait
 --> src/commands/system_color.rs:76:39
 |
76 | let accent: cocoa::base::id = NSColor::controlAccentColor(nil);
 | ^^^^^^^
 |
help: you can add the `dyn` keyword if you want a trait object
 |
76 | let accent: cocoa::base::id = <dyn NSColor>::controlAccentColor(nil);
 | ++++ +
For more information about this error, try `rustc --explain E0782`.
warning: `inkycap` (lib) generated 51 warnings
error: could not compile `inkycap` (lib) due to 1 previous error; 51 warnings emitted
### What happened macOS builds currently fail due to issues using NSColor trait as a type. I fixed this issue by using NSColor access with objc2 and objc2-app-kit crates in favor of the deprecated objc and cocoa crates. Happy to submit the PR for this if you are ok with updating these dependencies. ### Steps to reproduce 1. clone repository 2. Install dependencies with `npm install` 3. Setup tinymist side car with `mkdir src-tauri/binaries && ./scripts/download-tinymist.sh` 4. Run development build with `npm run tauri:dev` ### Expected behaviour Successfully build InkyCap for macOS target. ### Platform / OS macOS 15.7.4 ### Install type Built from source ### InkyCap version 26.6.2 ### Notes, logs, or screenshots main error message: ```bash error[E0782]: expected a type, found a trait --> src/commands/system_color.rs:76:39 | 76 | let accent: cocoa::base::id = NSColor::controlAccentColor(nil); | ^^^^^^^ | help: you can add the `dyn` keyword if you want a trait object | 76 | let accent: cocoa::base::id = <dyn NSColor>::controlAccentColor(nil); | ++++ + For more information about this error, try `rustc --explain E0782`. warning: `inkycap` (lib) generated 51 warnings error: could not compile `inkycap` (lib) due to 1 previous error; 51 warnings emitted ```
joch referenced this issue from a commit 2026年06月11日 22:41:47 +02:00
Sign in to join this conversation.
No Branch/Tag specified
main
v26.7.3
v26.7.2
v26.6.18
v26.6.16
v26.6.14
v26.6.12
26.6.10
v26.6.10
v26.6.8
26.6.6
v26.6.2
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
InkyCap/app#1
Reference in a new issue
InkyCap/app
No description provided.
Delete branch "%!s()"

Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?