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

Slic3rPE-1.41.2+linux64-full-201811221508.AppImage does not install desktop integration #1431

Closed
kortschak opened this issue Nov 26, 2018 · 36 comments
Labels

Comments

@kortschak
Copy link
Contributor

Version

Slic3rPE-1.41.2

Operating system type + version

Linux Ubuntu 16.04

Behavior

Usually, when a new version of Slic3r is first run, it will ask to update the desktop integration. This version does not do so.

@macfly1202
Copy link

I close my opened issue which is the same
#1455

@rmoravcik
Copy link

It looks like a Linux Slic3rPE-1.41.2 AppImage is calling slic3r script instead of slic3r.wrapper script (that is also missing in new AppImage).

It seems that slic3r.wrapper script was doing some desktop integration magic...

@Ghostbird
Copy link

This is a bit of a shame, I'd love to have this feature back in a new release, for convenience's sake.

@macfly1202
Copy link

Hi, release Slic3r PE1.41.3 still have this same issue - Prusa dev team, please correct this annoying bug.

@bubnikv
Copy link
Collaborator

bubnikv commented Feb 17, 2019 via email

@rmoravcik
Copy link

Please advice as how we can fix this annoying bug. I am out of my wits.

On Thu, Feb 14, 2019 at 7:58 PM Jean-Marie Prigent @.***> wrote: Hi, release Slic3r PE1.41.3 https://github.com/prusa3d/Slic3r/releases/tag/version_1.41.3 still have this same issue - Prusa dev team, please correct this annoying bug. — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub <#1431 (comment)>, or mute the thread https://github.com/notifications/unsubscribe-auth/AFj5I11Wxq9STz6JYtXFsC8S9JQIy96Rks5vNbHLgaJpZM4YyyA_ .

The previous versions of Linux AppImage had slic3r.wrapper script, that was taking care of desktop integration and this script is missing in new Linux AppImages.

@rmoravcik
Copy link

@bubnikv

this is a content of 1.41.1 Linux AppImage, that is working fine:

morgan@morgan:/tmp/.mount_Slic3rGZqZER$ ls -l
celkom 38
-rwx--x--x 1 root root  1396 okt 26 14:04 AppRun
-rwx------ 1 root root 21520 okt 26 14:04 libunionpreload.so
-rw------- 1 root root   174 okt 26 14:04 slic3r.desktop
-rw------- 1 root root 16469 okt 26 14:04 slic3r.png
drwxr-xr-x 6 root root     0 okt 26 14:04 usr
morgan@morgan:/tmp/.mount_Slic3rGZqZER$ cat slic3r.desktop 
[Desktop Entry]
Name=Slic3r
Exec=slic3r.wrapper --gui
Icon=slic3r
Terminal=false
Type=Application
Categories=Graphics;3DGraphics;
X-AppImage-Version=1.41.1+linux64.glibc2.14
morgan@morgan:/tmp/.mount_Slic3rGZqZER$ ls -l usr/bin/
celkom 40
drwx------ 2 root root     0 okt 26 14:04 bin
drwx------ 3 root root     0 okt 26 14:04 lib
drwx------ 7 root root     0 okt 26 14:04 resources
-rwx------ 1 root root   148 okt 26 14:04 slic3r
-rwx------ 1 root root 30662 okt 26 14:04 slic3r.pl
-rwx--x--x 1 root root 10259 okt 26 14:04 slic3r.wrapper
morgan@morgan:/tmp/.mount_Slic3rGZqZER$ 

and this is 1.41.2, that is missing slic3r.wapper script:

morgan@morgan:/tmp/.mount_Slic3rQiyRCA$ ls -l
celkom 38
-rwx--x--x 1 root root  1396 nov 22 16:22 AppRun
-rwx------ 1 root root 21520 nov 22 16:23 libunionpreload.so
-rw------- 1 root root   166 nov 22 16:23 slic3r.desktop
-rw------- 1 root root 16469 nov 22 16:22 slic3r.png
drwxr-xr-x 6 root root     0 nov 22 16:22 usr
morgan@morgan:/tmp/.mount_Slic3rQiyRCA$ cat slic3r.desktop 
[Desktop Entry]
Name=Slic3r
Exec=slic3r --gui
Icon=slic3r
Terminal=false
Type=Application
Categories=Graphics;3DGraphics;
X-AppImage-Version=1.41.2+linux64.glibc2.14
morgan@morgan:/tmp/.mount_Slic3rQiyRCA$ ls -l usr/bin/
celkom 30
drwx------ 2 root root     0 nov 22 16:23 bin
drwx------ 3 root root     0 nov 22 16:22 lib
drwx------ 7 root root     0 nov 22 16:22 resources
-rwx------ 1 root root   148 nov 22 16:22 slic3r
-rwx------ 1 root root 30662 nov 22 16:22 slic3r.pl
morgan@morgan:/tmp/.mount_Slic3rQiyRCA$ 

@ardenpm
Copy link
Contributor

ardenpm commented May 27, 2019

This issue still exists in the PrusaSlicer 2.0.0 release.

@bubnikv
Copy link
Collaborator

bubnikv commented Jun 3, 2019

@probonopd please help again.

Reading the last comment of
https://discourse.appimage.org/t/standardise-removal-of-appimage/62/9

it seems that the appimage integration is no more done by the appimage itself, but by appimaged daemon (or the AppImageLauncher tool), which the user has to install on his computer, right?

@ardenpm
Copy link
Contributor

ardenpm commented Jun 3, 2019

In my case I had attempted installing the appimaged package (I’m on Ubuntu 16.04) and following various guides placed the AppImage in its various watch directories but it did not pick it up.

probonopd added a commit to AppImage/appimage.github.io that referenced this issue Jun 3, 2019
@probonopd
Copy link
Contributor

It seems like usr/share/applications/prusaslicer.desktop is missing; hence appimaged cannot integrate it into the system. @bubnikv where can I see the script that generates the AppImage?

@bubnikv
Copy link
Collaborator

bubnikv commented Jun 3, 2019

This is the content of the PrusaSlicer.yml

# This is an AppImage recepie by @probonopd 
# https://github.com/AppImage/AppImages/blob/master/YML.md

app: PrusaSlicer
union: true

ingredients:
  dist: oldstable
  sources:
    - deb http://ftp.de.debian.org/debian/ oldstable main
  packages: freeglut3
  script:
    - echo "${SLIC3R_BUILD_ID}" | sed -e 's|-|.|g' > VERSION
    - echo "Version"
    - cat VERSION
    - echo "multiarch-support" >> excludedeblist

script:
  - pwd
  - mkdir -p usr/bin
  - cp -R ${DIST_DIR_FULL}/* ./usr/bin
  - cp ./usr/bin/resources/icons/Slic3r.png PrusaSlicer.png
  - mv ./usr/lib/x86_64-linux-gnu/lib* ./usr/bin/bin/ # Their wrapper loads libraries only from there
  - cp ${BUILD_UTILS_DIR}/PrusaSlicer.desktop ./
  - cp ${BUILD_UTILS_DIR}/PrusaSlicer.AppRun ./AppRun

The PrusaSlicer.desktop lands to the root of the AppImage
image

@probonopd
Copy link
Contributor

probonopd commented Jun 3, 2019

OK, please add to the end:

- mkdir -p ./usr/share/applications && cp ./PrusaSlicer.desktop ./usr/share/applications/
- mkdir -p ./usr/share/icons/256x256/apps && cp PrusaSlicer.png ./usr/share/icons/256x256/apps/

Assuming the icon is 256x256 (I didn't have a chance to check right now, so please double check and change the directory name appropriately in case it is 512x512 or 128x128).

That should do the trick.

@probonopd
Copy link
Contributor

By the way, is union: true really still needed? I consider it to be a bit of a hack for applications where the authors don't want to make changes; in your case you should be able to do without it because you can make the application look up its resources in paths relative to the main binary's directory (if it doesn't already do that).

@azubieta
Copy link

azubieta commented Jun 4, 2019

It seems like usr/share/applications/prusaslicer.desktop is missing; hence appimaged cannot integrate it into the system. @bubnikv where can I see the script that generates the AppImage?

This doesn't seems to be the issue here. appimaged performs the system integration using libappimage and this support desktop files in the root of the AppDir. I guess that we would need the appimaged logs and the generated desktop file in the user home (if any) to properly check. Also would be nice to know the system in which this issue is happening.

By the way feel free to ping me on the #appimage channel on freenode for a closer review of this issue.

@probonopd
Copy link
Contributor

Sorry, I stand corrected. What is the best way for a user who experiences this issue to help debugging @azubieta?

@probonopd
Copy link
Contributor

probonopd commented Jun 16, 2019

Turns out the .DirIcon is in a non-standard size which is not handled gracefully by libappimage:

me@host:~/Desktop$ /isodevice/Applications/PrusaSlicer-2.0.0-rc2+linux64-201905190649.AppImage --appimage-extract '*.png'
squashfs-root/PrusaSlicer.png
me@host:~/Desktop$ file squashfs-root/PrusaSlicer.png 
squashfs-root/PrusaSlicer.png: PNG image data, 154 x 154, 8-bit/color RGBA, non-interlaced

154x154 is not a valid icon size and hence the icon does not show up. Please use, e.g., 192x192 or 128x128.

So, use PrusaSlicer_128px.png or PrusaSlicer_192px.png as your PrusaSlicer.png @bubnikv.

@bubnikv
Copy link
Collaborator

bubnikv commented Jun 17, 2019

Great, thanks a lot for investigation.

@bubnikv
Copy link
Collaborator

bubnikv commented Aug 19, 2019

@probonopd I have updated the build scripts to use the 128x128 picture for desktop integration. Let's keep our fingers crossed.

@probonopd
Copy link
Contributor

Thanks @bubnikv

@bubnikv
Copy link
Collaborator

bubnikv commented Aug 23, 2019

Please verify with the upcoming PrusaSlicer 2.1.0-beta.

@kortschak
Copy link
Contributor Author

Still not working with 2.2.0-alpha2.

@bubnikv
Copy link
Collaborator

bubnikv commented Mar 20, 2020

The PrusaSlicer.png in the root of the AppImage is
128x128 8 bit color RGBA, non interlaced

@probonopd
Copy link
Contributor

probonopd commented Mar 20, 2020

Usually, when a new version of Slic3r is first run, it will ask to update the desktop integration. This version does not do so.

This is no longer recommended, users are advised to use appimaged, AppImageLauncher, or the desktop environment's native AppImage integration.

At least using https://github.com/probonopd/go-appimage/tree/master/src/appimaged it works for me:

So I'd say this can be closed here. (If there are bugs, then they are probably not in PrusaSlicer but elsewhere.)

@kortschak
Copy link
Contributor Author

Maybe this is a documentation issue then. Prusa should provide information for the correct way to install the software.

@bubnikv
Copy link
Collaborator

bubnikv commented Mar 21, 2020 via email

@kortschak
Copy link
Contributor Author

Maybe it is your distro issue? Maybe your appimaged is misconfigured on
your box?

This is certainly something that would be helped with adequate documentation for installation, no?

@kortschak
Copy link
Contributor Author

To be completely clear, I can find no obvious documentation for desktop integration for the Prusa Slicer appImage release, and no indication (prior to the comments above) that appimaged should be used.

As an aside, I have to say that this is terrifying.

@probonopd
Copy link
Contributor

probonopd commented Mar 21, 2020

Prusa should provide information for the correct way to install the software.

AppImages do not need to be "installed". Just download, make executable, run.
This is documented at
https://docs.appimage.org/user-guide/run-appimages.html.

If you want desktop integration (icons, menu entries) you need either a Linux distribution that integrates AppImages with the system out of the box, or an optional daemon/system that integrates AppImages (not just PrusaSlicer but all of them) into the system, e.g., appimaged or AppImageLauncher. This has nothing to do with Prusa or Prusa documentation. If anything, you can blame AppImage documentation (even though it is mentioned there) or your distribution's desktop environment for not doing it natively.

appimaged is an optional daemon that watches locations like ~/bin and ~/Downloads for AppImages and if it detects some, registers them with the system, so that they show up in the menu, have their icons show up, MIME types associated, etc. It also unregisters AppImages again from the system if they are deleted. Optionally you can use a sandbox if you like: If the firejail sandbox is installed, it runs the AppImages with it.

You find it and its documentation over at
https://github.com/AppImage/appimaged.

Alternatively, you could use AppImageLauncher instead. It allows you to integrate AppImages you download into your application menu or launcher to make it easier for you to launch them. It also takes care of moving them into a central location, where you can find them later if you need access to them again. Furthermore, it sets up the update and removal entries in the launcher for you.

You find it and its documentation over at
https://github.com/TheAssassin/AppImageLauncher.

So I'd say this can be closed here.

@kortschak
Copy link
Contributor Author

Thanks. I understand how AppImage applications work, and how desktop integration works. The title of the issue remains accurate, and could be at least partially mitigated by adding documentation (or links to documentation) explaining (as you have done above) how to perform desktop integration since that behaviour has been removed from the applmage applications' first run.

I agree, the defect does largely exist in AppImage's documentation. While the existence of appimaged and AppImageLauncher is described in the documentation, it could be made more clearly visible. A link in the Prusa Slicer install (for want of a better word) instructions would help here. Having said that, the approach appimaged takes is truly horrifying, and it's sad to see a nice simple approach of AppImage now picking up additional weight, requiring these extra toolings.

@probonopd
Copy link
Contributor

@kortschak thanks for your response. Please keep in mind that desktop integration is still entirely optional. You can still just double-click AppImages from the file manager. We (the AppImage team) are always happy to think about how to improve. Maybe we should continue over at https://github.com/AppImage/AppImageKit/issues.

@spuder
Copy link
Contributor

spuder commented Dec 13, 2020

As a newish linux desktop user I found this really frustrating that prusa slicer wouldn't show up in the launcher. For anyone else looking for a quick workaround, the snap store provides an install of prusa slicer that includes the desktop file

https://snapcraft.io/prusa-slicer

sudo snap install prusa-slicer

@macfly1202
Copy link

amazing and it's works ! so cool. Thanks for sharing @spuder

@probonopd
Copy link
Contributor

probonopd commented Dec 13, 2020

As a newish linux desktop user I found this really frustrating that prusa slicer wouldn't show up in the launcher.

This is because most desktop environments do not offer native AppImage integration yet. But optional tools like AppImageLauncher and appimaged can integrate AppImages into the menu automatically for you. Or you just execute the AppImage directly without a menu entry.

@ardenpm
Copy link
Contributor

ardenpm commented Dec 13, 2020

The AppImage ecosystem is a bit frustrating at the moment. To get the integration as mentioned earlier you really need appimaged now, however the official repo for that says it is deprecated and they direct you to this one which is clearly experimental and pre-release.

In any case I did download the appimaged from the new repo and ran it (just like another AppImage) which installs the daemon. After that it adds the stuff automatically when you drop an AppImage in a watched folder (Downloads). That is what got me at first since I was putting them in a specific place that wasn't being watched.

Really though, the Appimage project hasn't done a good job of keeping the desktop integration stuff simple. You now need to wade through multiple Github repos to work it out.

@bubnikv
Copy link
Collaborator

bubnikv commented Aug 26, 2021

We implemented manual desktop integration into prusaslicer 2.4

@bubnikv bubnikv closed this as completed Aug 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

9 participants