Need a Little Help with deb2tgz
Attention: If you accessed this thread looking for solutions to deb2tgz this is probably not the place. At least for me it is really rare that I ever come across an app that is only available as a .deb, and even then simply extracting the files and manually placing them where designated has always worked. In this case the app was also only available as 64 bit and my system was 32 bit. If you'd like to follow the process to installing and configuring 64 bit multilib feel free to read on. As for deb2tgz, I'll leave that to others as I so rarely need it.
Greetz I have an app, Discord, that I need to install and the first problem I face is with just getting the source out and a tgz package would be a good start. I can't find a DlackBuild and tho the devs expect a full native Linux build at some point all they have now is Discord-Canary-0.8.deb. At first deb3tgz errored out because upon extracting the deb I discovered that control is in the form control.tar.gz but data is in the form data.tar.xz. Since deb2tgz is a script I tried altering the search name from gz to xz and it no longer errors out byt I get no output after it completes. I've never used deb2tgz before and I must be suffering a brain cramp 'cuz I don't know what to do next after trying just placing the files in their respective locations manually. The only error message I get is Code:
bash: /usr/bin/discord-canary: cannot execute binary file |
I have not used deb2tgz, but I have used rpm2tgz. It's pretty straightforward. Change directory into the directory where the *.rpm is stored, then, as root, execute
Code:
rpm2tgz [filename] |
I get that a lot with deb files
bash-4.3# deb2tgz discord-canary-0.0.8.deb mv: cannot stat 'data.tar.gz': No such file or directory ERROR: ar failed. (maybe discord-canary-0.0.8.deb is not an DEB?) bash-4.3# |
You can use ar to extract .debs with a few extra pipes.
For xz compressed debs: Code:
ar p Discord-Canary-0.8.deb data.tar.xz | unxz | tar -xv Code:
ar p Discord-Canary-0.8.deb data.tar.gz | gzip -d | tar -xv I've found this is the easiest native way to extract deb packages for SlackBuilds. |
Quote:
Code:
deb2tgz ./Discord-Canary-0.81.deb |
Quote:
|
Thank you, bassmadrigal, as I stated I was able to extract the deb file and I copied all of the files (including hidden files) to their designated location - /usr/bin and /usr/share, scattered in a few subdirectories as listed.
I found your SB example enlightening but so far it still fails for me in this case. I'm suspecting either a dependency issue or an architecture mismatch and am writing the devs today about $ARCH and any dependencies. |
Hi
I was thinking of trying a Debian command called alien that can convert to/from deb and tgz. But searching for the deb I found this: https://www.reddit.com/r/discordapp/...anary_release/ There's a link to a tar.gz download. |
Yeah, my SlackBuild is based on having an ARCH declared in the package title (which is common for Ubuntu packages ($PRGNAM-$VERSION-$DEBARCH -- Discord-Canary-0.8-i386.deb), but it can be adjusted to not use it.
When you manually copied the files/folders over, did the program work, or is that what you meant when you said it fails for you? I can try to look at it tonight and see what I can find. Also, as Guttorm found, it seems they might have a tar.gz release so you wouldn't have to deal with unpacking the .deb, but I'll try to remember to check that out at home as well. |
Ok, after getting home and looking at everything, a few minor tweaks to the filebot SlackBuild (seems they have a few libraries hardcoded to the "current directory", so I had to remove the symlink and use a script to launch it) had this packaging and then opening. But I don't have an account, so I can't test how well it actually works. Feel free to give it a shot. Also, the binaries seem to be 64bit only, so I caused the script to fail if it is run on a 32bit system.
Code:
#!/bin/sh |
Major Thank Yous for bassmadrigal and Guttorm! Glad to know my failure was likely due to ARCH mismatch. I'm far more comfortable with source and will do it "old skool" by just viewing config and just compiling. Once I get that working I will do the SlackBuild so the app get's listed and is properly uninstallable. It may seem redundant but I'm comfortable with small steps. I'll report back soon.
|
Quote:
|
Yes I discovered that snafu right away. My problem is compounded by what seems to be no available 32 bit versions at all. I even tried the Windows version in wine. I am likely stuck with the web browser version. At least there's that. FWIW, though some may find it backward, my most important apps are 32 bit and at the very least my main PC would be a poor investment to "upgrade" to 64 bit with no net gain I can see, and quite probably a net loss due to additional layers of complexity. This is, however, likely the beginning of the final shift for 64 bit dominance where compliance is just easier.
|
What programs do you use that are 32bit only? For what it's worth, I've noticed no issues running multilib on my desktop (I did it for steam -- checking my system, the only 32bit packages I have installed are steam and googleearth, but I don't even remember the last time I opened Google Earth). There might be some measureable time differences in running 32bit apps on a multilib system, but, while they may be measurable, I doubt they're very noticeable. My htpc now has no reliance on 32bit software, so I'm running a pure 64bit Slackware on there. I'm not saying any of this to pursuade you to switch, just providing my experiences :)
For future reference, you can check if a program is 32bit or 64bit using file. Code:
file /location/to/DiscordCanary |
Thanks again bassmadrigal. I have used dedicated 32 bit so long I had forgotten that "file' will reveal architecture.
FTR I use an old version of KDE's Kpackage regularly and had to install v3 support in /opt to continue to run it. I love that app and it is a rare week that I don't consult it several times. I don't know if that would be a problem in 64 bit. I also have an ancient but still simple and useful app for drawing schematics and don't relish learning a new one with more "features" than I need. Additionally I do multimedia work, more audio than video, and not having to reboot, but just running them when needed in wine (alongside my favorite Native Linux Ardour) , as well as a few games that run with less overhead and more local control than with Steam is handy and likeable. From what I read, wine is much easier to work with, at least for the time being, in a 32 bit OpSys. I depend mostly on external firewalls for security and never install, let alone run, IE or Outlook, etc,. so I am unconcerned with any substantial issues with wine. It beats having to reboot and run actual Windows, hands down, IMHO. I recognize that within a few years I will actually need to go 64 bit and that's acceptable but until then I'm quite content with the simplicity of 32 bit and I have a huge amount of work invested in it. |
All times are GMT -5. The time now is 04:10 PM. |