georgesnow / MacPassRevealer

MacPass Plugin - Global Keyboard shortcut to hide/unhide MacPass w/ menubar icon
MIT License
11 stars 1 forks source link

The bundle "MacPassRevealer" couldn't be loaded because it is damaged or missing necessary resources #14

Open slunak opened 4 years ago

slunak commented 4 years ago

Catalina 10.15.2. Release: BETA-3. Steps to replicate:

  1. Download and add plugin into MacPass
  2. Restart MacPass and once started I get the following message:

image

In the Preferences > Plugins:

image

georgesnow commented 4 years ago

hmm curious how did you get BETA-3? I thought I had removed it from the release page. Have you tried BETA-4? I believe this is a signing issue since I don't have Apple developer account.

slunak commented 4 years ago

BETA-4 is not released, there is only source code. Would you be able to point me to the direction of compiling it? Perhaps it would eliminate this issue.

georgesnow commented 4 years ago

yeah most likely compiling yourself would resolve it.

you need to install Xcode-command line tools (if you don't have them installed) and Homebrew this makes it easier to install the dependency manager (Carthage).

In Terminal or iTerm2 or whatever terminal app you like and run these commands:

xcode-select --install
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew install carthage
git clone https://github.com/mstarke/MacPass --recursive
cd MacPass
carthage bootstrap --platform macOS
cd ..
git clone https://github.com/georgesnow/MacPassRevealer
cd MacPassRevealer/MacPassRevealer
xcodebuild

after the last command it will tell what folder the .mplugin file is in. it is suppose to move to the proper folder in Application Support/MacPass. however, I have had varying success with that happening. so you may have to do that manually and then restart MacPass. If all goes well you get no errors and you can now use the plugin. if you have issues let me know and hopefully we can figure it out.

slunak commented 4 years ago

Thank you @georgesnow , I was able to build it. I run into issues while building and fixed by:

  1. Installing full Xcode app and

sudo xcode-select -s /Applications/Xcode.app/Contents/Developer

  1. Add Apple ID account to Xcode
  2. Create new signing certificate
  3. Open the project and changing Signing settings to match newly created signing certificate

Issues I had:

When running xcodebuild:

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

When building the project:

Code Signing Error: No signing certificate "Mac Development" found: No "Mac Development" signing certificate matching team ID "XXXXXXXXX" with a private key was found.

I would also like to replace the icon on the top bar as it is in colour and does not fit well with other icons which are in mono.

image

Luckily I can do it by replacing the icon and building a new release. I love open source :)

Looks a bit better now:

image

Are you interested in adding an option to switch the icon once the theme (dark mode) has changed?

georgesnow commented 4 years ago

Awesome glad you got it working! I forgot about the code signing. I will try to update notes on read me on how to build it. If you want to you can submit monochrome icon and I will change it out. I like it better anyway. The blue was for originally for testing so I could easily spot it.

Eventually the functionality will be added to the core macpass code. I am working on that now, but that will take some time between testing and the pull requests being merged.

In mean time I will continue to work on the plugin so if you find bugs or improvement just submit here. I will try to fix them.

slunak commented 4 years ago

I would love to contribute and spent a lot of time today trying to understand how mac os menu bar icons work and how to make the icon change depending on a dark or light mode. I failed to setup it up right though and just used an icon for dark theme. In light theme the icon is simply white. I doubt you want it fixed this way. What I can do though is to create blue (or any other colour) icon which can be used in both modes.

MEPoss commented 3 years ago

The problem is still there in BETA-4

rburgst commented 3 years ago

Tried to build but getting

In file included from /Users/rainer/git/private/osx/MacPassRevealer/MacPassRevealer/MacPassRevealer/MPRStatusItem.m:11:
In file included from ../../MacPass/MacPass/MPDocument.h:24:
../../MacPass/Carthage/Checkouts/KeePassKit/KeePassKit/KeePassKit.h:17:9: fatal error: 'KeePassKit/KPKPlatformIncludes.h' file not found
#import <KeePassKit/KPKPlatformIncludes.h>
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

looks like the plugin is not able to access the libs from MacPass. I followed the above mentioned instructions:

cd MacPass
carthage bootstrap --platform macOS
cd ..
git clone https://github.com/georgesnow/MacPassRevealer
cd MacPassRevealer/MacPassRevealer
xcodebuild

I already changed the signing cert to "Sign to run locally".

It would be nice to get some documentation on how to build the plugin as it seems to be needed for newer OS releases (running on Big Sur)

rburgst commented 3 years ago

I think this is related to https://github.com/MacPass/MacPass/issues/1149

georgesnow commented 3 years ago

@rburgst you trying to build for M1 or intel? But you are correct about the other post and what @mstarke mentioned about the locations. I try and take look to see if I can figure out what changed. And provide better info on how to build the plug-in.

rburgst commented 3 years ago

I am building for intel. I can successfully build macPass without problems but I had to hack around the imports as described in the linked ticket in order to get the plug-in to compile. Tried both on commandline and xcode.

georgesnow commented 3 years ago

@rburgst just getting back your post. So this seems to be an upstream change with MacPass and its dependencies. For whatever reason when the dependencies are checked out the linking for import does not work. I personally don't know enough of how it works to fix it. So the hack I got working and you did appears to be the only option right now.

georgesnow commented 2 years ago

@rburgst just as note we can hope this will be a thing of the past soon. I have ported all of MacPassRevealers functionality into pull requests for the core MacPass app.