Code Monkey home page Code Monkey logo

debtap's People

Contributors

asmolero avatar brunochevalier avatar helixarch avatar juergenhoetzel avatar kaqqao avatar nsajko avatar pkasemir avatar pmav99 avatar primetoxinz avatar tleonardi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

debtap's Issues

error: group 'base' was not found

When I was running debtap -u in my manjaro (pacman version v5.2.2.) , I got some error:

[root@manjaro debtap]# ./debtap -u
==> Synchronizing pkgfile database...
:: Updating 5 repos...
  extra is up to date
  community is up to date
  multilib is up to date
  core is up to date
  download complete: archlinuxcn          [    20.5 MiB   178K/s  0 remaining]
:: download complete in 117.94s           <    20.5 MiB   178K/s  1 file     >
:: waiting for 1 process to finish repacking repos...
==> Synchronizing debtap database...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 10.1M  100 10.1M    0     0  36447      0  0:04:51  0:04:51 --:--:-- 58064
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  111k  100  111k    0     0  12148      0  0:00:09  0:00:09 --:--:-- 20170
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 62125  100 62125    0     0  78243      0 --:--:-- --:--:-- --:--:-- 78144
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 39.9M  100 39.9M    0     0  99234      0  0:07:02  0:07:02 --:--:-- 36384
==> Downloading latest virtual packages list...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   149    0   149    0     0    221      0 --:--:-- --:--:-- --:--:--   221
100 14118    0 14118    0     0   8170      0 --:--:--  0:00:01 --:--:--   99k
==> Downloading latest AUR packages list...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  418k    0  418k    0     0  15798      0 --:--:--  0:00:27 --:--:-- 16635
==> Generating base group packages list...
error: group 'base' was not found
==> All steps successfully completed!

It seems caused by line 116:

112                    if [[ $(echo $?) != 0 ]]; then
113                        echo -e "${red}Downloading failed. Exiting...${NC}"; exit 1
114                    else    
115                        echo -e "${lightgreen}==>${NC} ${bold}Generating base group packages list...${normal}"
116                        pacman -Qqg base > /var/cache/debtap/base-packages
117                        chmod 644 /var/cache/debtap/*
118                        echo -e "${lightgreen}==>${NC} ${bold}All steps successfully completed!${normal}"; exit 0
119                    fi

And reference to archlinux official news, base group was replaced by metapackage base, thus we can not find group base.

And I workaround by replace line 116:

@@ -113,7 +113,8 @@ elif [[ $update == set ]]; then
                         echo -e "${red}Downloading failed. Exiting...${NC}"; exit 1
                     else    
                         echo -e "${lightgreen}==>${NC} ${bold}Generating base group packages list...${normal}"
-                        pacman -Qqg base > /var/cache/debtap/base-packages
+                        #pacman -Qqg base > /var/cache/debtap/base-packages
+                        pacman -Qi base | grep Depends | cut -d: -f2
                         chmod 644 /var/cache/debtap/*
                         echo -e "${lightgreen}==>${NC} ${bold}All steps successfully completed!${normal}"; exit 0
                     fi

I don't know if you guys have the same problem, and maybe it not work for you, so i put it in issues but not PR.

does not wirk with control.tar.xz

looks like the new deb packages contain control.tart.xz rather than control.tart.gz. Please update you package to handle them. I replaced the line ar p "$package_with_full_path" control.tar.gz | tar xz with
control_tar_check=ar t "$package_with_full_path" | grep control
if [[ $control_tar_check == control.tar.gz ]]; then
ar p "$package_with_full_path" control.tar.gz | tar xz
elif [[ $control_tar_check == control.tar.xz ]]; then
ar p "$package_with_full_path" control.tar.xz | tar xJ
fi

which seems to be inline with your code and seems to work.

Thanks and BTW great script

mv: cannot stat '*.zst': No such file or directory

Hi,

I'm trying to convert Webull .deb package using "sudo debtap Webull.deb" but I get the error in the title and no .pkg is created in the working dir

*** Creation of .PKGINFO file in progress. It may take a few minutes, please wait...

==> Checking and generating .INSTALL file (if necessary)...

:: If you want to edit .PKGINFO file, press (1) For vi (2) For nano (3) For default editor (4) For a custom editor or any other key to continue:


==> Generating .MTREE file...

==> Creating final package...
Incorrect parameters
mv: cannot stat '*.zst': No such file or directory
==> Package successfully created!
==> Removing leftover files...

debtap -u on ArchLabs

I ran debtap -u on my ArchLabs and it say
$ sudo debtap -u ==> Synchronizing pkgfile database... :: Updating 5 repos... multilib is up to date extra is up to date core is up to date community is up to date download complete: archlabs_repo [ 26.0 B 22.0B/s 0 remaining] :: download complete in 1.14s < 26.0 B 22.0B/s 1 file > :: waiting for 1 process to finish repacking repos... error: failed to create archive reader for archlabs_repo: Invalid or incomplete multibyte or wide character Synchronization failed. Exiting...
So... how to fix it ???

Debtap does not sync the last repo

Seems I'm stuck trying to update repos:

debtap -u
==> Synchronizing pkgfile database...
:: Updating 4 repos...
  core is up to date
  extra is up to date
  multilib is up to date

I would suggest a verbose method so people could have a clue of what is going on

using packages-names-translator via a cli option

The significant content of the debtap script is about mapping debian dependencies to arch linux dependencies. It is not easy to extract only needed places of code for this task (because it will be a really long script). But it will be good if we can check mapping via command line without actually having a .deb file.
Can you please add it? For example, with "-d --d --dependency-map" option.
I need it because I am repacking an amdgpu-pro ubuntu packages for archlinux with a script https://github.com/Ashark/archlinux-amdgpu/blob/master/gen-PKGBUILD.py#L286

cleaning /var/cache/debtap

that directory is growing and i am not sure if any installed packages depend on it.

is it safe to clear this directory out once in a while or would that break packages installed with the help of debtap?

also: thank you for your work :)

Failed to synchronize the pkg file

See what happens when I try to synchronize the database:


[neit ~]# debtap -u
==> Synchronizing pkgfile database...
:: Updating 5 repos...
warning: download failed: http://www.las.ic.unicamp.br/pub/manjarolinux/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://www.las.ic.unicamp.br/pub/manjarolinux/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://www.las.ic.unicamp.br/pub/manjarolinux/stable/community/x86_64/community.files [error 404]
warning: download failed: http://www.las.ic.unicamp.br/pub/manjarolinux/stable/core/x86_64/core.files [error 404]
infinality-bundle is up to date
warning: download failed: http://linorg.usp.br/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://linorg.usp.br/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://repo.manjaro.org.uk/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://repo.manjaro.org.uk/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.nluug.nl/pub/os/Linux/distr/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://ftp.nluug.nl/pub/os/Linux/distr/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.heanet.ie/mirrors/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.heanet.ie/mirrors/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://ftp.snt.utwente.nl/pub/linux/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.snt.utwente.nl/pub/linux/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirrors.serverhost.ro/manjaro/packages/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirrors.serverhost.ro/manjaro/packages/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://linorg.usp.br/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirror.yandex.ru/mirrors/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.yandex.ru/mirrors/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://repo.manjaro.org.uk/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://linorg.usp.br/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://ftp.nluug.nl/pub/os/Linux/distr/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://manjaro.dcc.uchile.cl/stable/core/x86_64/core.files [error 404]
warning: download failed: http://manjaro.dcc.uchile.cl/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://ftp.heanet.ie/mirrors/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://repo.manjaro.org.uk/stable/community/x86_64/community.files [error 404]
warning: download failed: http://lug.mtu.edu/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://lug.mtu.edu/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.snt.utwente.nl/pub/linux/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.nluug.nl/pub/os/Linux/distr/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirrors.serverhost.ro/manjaro/packages/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.heanet.ie/mirrors/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.yandex.ru/mirrors/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.snt.utwente.nl/pub/linux/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.netcologne.de/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirror.netcologne.de/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://manjaro.dcc.uchile.cl/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirrors.serverhost.ro/manjaro/packages/stable/community/x86_64/community.files [error 404]
warning: download failed: http://lug.mtu.edu/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirror.yandex.ru/mirrors/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.netcologne.de/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://h1860261.stratoserver.net/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://h1860261.stratoserver.net/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://manjaro.dcc.uchile.cl/stable/community/x86_64/community.files [error 404]
warning: download failed: http://lug.mtu.edu/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://h1860261.stratoserver.net/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirror.netcologne.de/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://h1860261.stratoserver.net/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://ftp.halifax.rwth-aachen.de/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://ftp.halifax.rwth-aachen.de/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.halifax.rwth-aachen.de/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.halifax.rwth-aachen.de/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.ragenetwork.de/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirror.ragenetwork.de/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.ragenetwork.de/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirror.ragenetwork.de/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.netzspielplatz.de/manjaro/packages/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.netzspielplatz.de/manjaro/packages/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirror.netzspielplatz.de/manjaro/packages/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirror.netzspielplatz.de/manjaro/packages/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirrors.xservers.ro/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirrors.xservers.ro/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirrors.xservers.ro/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirrors.xservers.ro/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirror.lignux.com/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirror.lignux.com/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.lignux.com/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirror.lignux.com/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.solarvps.com/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirror.solarvps.com/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.solarvps.com/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.solarvps.com/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.lysator.liu.se/pub/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.lysator.liu.se/pub/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://ftp.lysator.liu.se/pub/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.lysator.liu.se/pub/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://manjaro.mirrors.uk2.net/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://manjaro.mirrors.uk2.net/stable/core/x86_64/core.files [error 404]
warning: download failed: http://manjaro.mirrors.uk2.net/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://manjaro.mirrors.uk2.net/stable/community/x86_64/community.files [error 404]
warning: download failed: http://www.mirrorservice.org/sites/repo.manjaro.org/repos/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://www.mirrorservice.org/sites/repo.manjaro.org/repos/stable/core/x86_64/core.files [error 404]
warning: download failed: http://www.mirrorservice.org/sites/repo.manjaro.org/repos/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://www.mirrorservice.org/sites/repo.manjaro.org/repos/stable/community/x86_64/community.files [error 404]
warning: download failed: http://ftp.belnet.be/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://ftp.belnet.be/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.belnet.be/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.belnet.be/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://manjaro.mirror.garr.it/mirrors/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://manjaro.mirror.garr.it/mirrors/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://manjaro.mirror.garr.it/mirrors/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://manjaro.mirror.garr.it/mirrors/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://manjaro.uberglobalmirror.com/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://manjaro.uberglobalmirror.com/stable/core/x86_64/core.files [error 404]
warning: download failed: http://manjaro.uberglobalmirror.com/stable/community/x86_64/community.files [error 404]
warning: download failed: http://manjaro.uberglobalmirror.com/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirrors.tuna.tsinghua.edu.cn/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirrors.tuna.tsinghua.edu.cn/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirrors.tuna.tsinghua.edu.cn/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirrors.tuna.tsinghua.edu.cn/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirror.zetup.net/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.zetup.net/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirror.zetup.net/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.zetup.net/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.riken.jp/Linux/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.riken.jp/Linux/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://ftp.riken.jp/Linux/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.riken.jp/Linux/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://manjaro.mirrors.linux.ro/repos/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://manjaro.mirrors.linux.ro/repos/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://manjaro.mirrors.linux.ro/repos/stable/core/x86_64/core.files [error 404]
warning: download failed: http://manjaro.mirrors.linux.ro/repos/stable/community/x86_64/community.files [error 404]
warning: download failed: https://manjaro.cu.be/stable/extra/x86_64/extra.files [error 404]
warning: download failed: https://manjaro.cu.be/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: https://manjaro.cu.be/stable/core/x86_64/core.files [error 404]
warning: download failed: https://manjaro.cu.be/stable/community/x86_64/community.files [error 404]
download complete: core [ 596,0 B 483B/s 3 remaining]
error: failed to create archive reader for core: Multibyte ou caracter largo inválido
download complete: extra [ 596,0 B 473B/s 2 remaining]
error: failed to create archive reader for extra: Multibyte ou caracter largo inválido
download complete: multilib [ 596,0 B 464B/s 1 remaining]
error: failed to create archive reader for multilib: Multibyte ou caracter largo inválido
download complete: community [ 596,0 B 484B/s 0 remaining]
:: download complete in 20,58s < 2,3 KiB 115B/s 4 files >
:: waiting for 1 process to finish repacking repos...
error: failed to create archive reader for community: Multibyte ou caracter largo inválido
Synchronization failed. Exiting...

errors from the .INSTALL

These show up when install or removing the generated package using packman:

/tmp/alpm_XNlaz5/.INSTALL: line 534: unexpected EOF while looking for matching ``'
/tmp/alpm_XNlaz5/.INSTALL: line 567: syntax error: unexpected end of file

I am using the debtap binary installed from AUR using yay:

[viasat@Manjaro ~]$ debtap -v
3.2.2

Dependencies from core repo

In some debian packages there are dependencies such as "udev". It is mapped to "systemd-libs", which is core, so it doesn't need to be explicitly required in dependencies.
Maybe make a special check for such cases?

zx compression preset

Hi, first of all thanks for your work, it helped me a lot.

I was trying to convert the file above in my raspberry 3 b+ and I had some memories issue during the "Creating final package..." step. Then I removed the "-9" (compression preset) from xz command line and everything went fine as expected.

So I was wondering if you could change the default preset to xz's default or make it configurable. Either way, it would help users with the same issue.

Thanks.

https://github.com/MediaBrowser/Emby.Releases/releases/download/4.1.0.14/emby-server-deb_4.1.0.14_armhf.deb

does not create symbolic link

I'm having problems with the visual-studio-code-bin package from the AUR repository. So I tried to convert .deb. But after installed with sudo pacman -U, the symbolic link of the postinst file is not created

ln -s /usr/share/code/bin /code/usr/bin/code

Cant convert Package

Hi,

i tried to convert the Remote Desktop Manager debian package:


$ sudo debtap -u 
==> Synchronizing pkgfile database... 
:: Updating 4 repos... 
 extra is up to date 
 core is up to date 
 multilib is up to date 
 community is up to date 
==> Synchronizing debtap database... 
 % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current 
                                Dload  Upload   Total   Spent    Left  Speed 
100 10.0M  100 10.0M    0     0   150k      0  0:01:08  0:01:08 --:--:--  148k 
 % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current 
                                Dload  Upload   Total   Spent    Left  Speed 
100  112k  100  112k    0     0  96205      0  0:00:01  0:00:01 --:--:-- 96205 
 % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current 
                                Dload  Upload   Total   Spent    Left  Speed 
100 59366  100 59366    0     0   623k      0 --:--:-- --:--:-- --:--:--  623k 
 % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current 
                                Dload  Upload   Total   Spent    Left  Speed 
100 39.9M  100 39.9M    0     0  10.7M      0  0:00:03  0:00:03 --:--:-- 10.7M 
==> Downloading latest virtual packages list... 
 % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current 
                                Dload  Upload   Total   Spent    Left  Speed 
100   149  100   149    0     0    659      0 --:--:-- --:--:-- --:--:--   656 
100 14118    0 14118    0     0  28871      0 --:--:-- --:--:-- --:--:-- 28871 
==> Downloading latest AUR packages list... 
 % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current 
                                Dload  Upload   Total   Spent    Left  Speed 
100  414k    0  414k    0     0  1385k      0 --:--:-- --:--:-- --:--:-- 1390k 
==> Generating base group packages list... 
error: group 'base' was not found 
==> All steps successfully completed! 

$ debtap RemoteDesktopManager.Free_2020.3.1.0_amd64.deb  
==> Extracting package data... 
==> Fixing possible directories structure differencies... 
==> Generating .PKGINFO file... 

:: Enter Packager name: 
remotedesktopmanagerfree 

:: Enter package license (you can enter multiple licenses comma separated): 
1,2,3,4 

*** Creation of .PKGINFO file in progress. It may take a few minutes, please wait... 

==> Checking and generating .INSTALL file (if necessary)... 

:: If you want to edit .PKGINFO and .INSTALL files (in this order), press (1) For vi (2) For nano (3) 
For default editor (4) For a custom editor or any other key to continue: 2 

==> Generating .MTREE file... 

==> Creating final package... 
Incorrect parameters  
mv: cannot stat '*.zst': No such file or directory 
==> Package successfully created! 
==> Removing leftover files...
 

File 1:

pkgname = 
pkgver = -1 
pkgdesc = Description:RemoteDesktopManagerFree. 
url = 
builddate = 1608471720 
packager = remotedesktopmanagerfree 
arch = 
size = 213697549 
license = 1 
license = 2 
license = 3 
license = 4

File 2:

post_install() { 

       if [ ! -d "/usr/share/.mono/new-certs/Trust" ]; then 
               mkdir -p /usr/share/.mono/new-certs/Trust 
               for f in /usr/share/ca-certificates/mozilla/*.crt ; do cp $f /usr/share/.mono/new-cer> 
       fi 
} 

post_upgrade() { 
       post_install 
} 

What am i doing wrong?

Peculiar dependency

As I transformed Atom nightly debian package into alpm in Manjaro, it included dependency like tuxedo-control-center and Metasploit Framework. You may look in this issue
Prerequisites to reproduce:

  • A Manjaro Linux Lysia installation
  • Metasploit and Tuxedo control center previously installed (I don't use a Tuxedo, it came with XFCE)
  • atom-amd64.deb from above link.
  • debtap script

Way to reproduce:

  • debtap atom-amd64.deb
  • See .PKGBUILD

\n in install script get interpreted

Hi, I ran debtap on a deb package and there these comment within the control scripts

# "Amazon Linux AMI release 2017.0"
# "Ubuntu 16.04.1 LTS \n \"
# "Debian GNU/Linux 9 \n \l"
# "Debian GNU/Linux 8 \n \l"

and in the install script produced, it became

	# "Amazon Linux AMI release 2017.0"
	# "Ubuntu 16.04.1 LTS 
\"
	# "Debian GNU/Linux 9 
 \l"
	# "Debian GNU/Linux 8 
 \l"

I'm guessing the comment were interpreted literally?

Changing Output .tar.xz files' permissions from 644 to 755?

I love your app, and I can't tell you how many times I've used it with great success. I'd like to know if there's a way to change the output .tar.xz files' permissions from 644 to 755?

I might be new to linux, but since there's a big-ol-lock emblem on the file, I think that means that I won't be able to actually install it unless I manually change it's permissions to 755.

Thanks!

Update issue

Hi there I'm quite new on arch and I needed debtap to use a very specific emacs tool called caml tuareg to use emacs and camllight. Each time I try to update it I get a lot of 404 (and some 502) errors, the update finally ends with the message: "All steps fully completed".Then when I try to use debtap on my deb file, I'm asked to update it again. How can I solve this?

Thanks in advance for the help.

If for some reason workdir is not created (e.g. permission issues), script will happily destroy everything in current directory

Around this: https://github.com/helixarch/debtap/blob/master/debtap#L102

Permissions were wrong, so creating a new directory failed, switching to it errored but the script continued, and then ran rm -rf on all files not matched by the grep line (which was all files in that folder).

$ debtap fx-docuprint-cp225-228-w_1.deb                                                                                                                                                         
mkdir: cannot create directory ‘fx-docuprint-cp225-228-w_1-working-directory’: Permission denied
/usr/bin/debtap: line 97: cd: fx-docuprint-cp225-228-w_1-working-directory: No such file or directory
... script continues ...

Fortunately this wasn't anywhere important...

debtap -u returns 'Synchronization failed. Exiting...'

Output

[archer@arch Desktop]$ sudo debtap -u
==> Synchronizing pkgfile database...
:: Updating 4 repos...
  extra is up to date
  core is up to date
  multilib is up to date
  community is up to date
==> Synchronizing debtap database...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 33.4M  100 33.4M    0     0   664k      0  0:00:51  0:00:51 --:--:--  651k
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
curl: (22) The requested URL returned error: 404 Not Found

gzip: /var/cache/debtap/ubuntu-packages-files.gz: unexpected end of file
Synchronization failed. Exiting...

Curl version: curl-7.54.1-1
Arch budgie up to date

Here-Document terminators broken during conversion

Found one more bug while converting Kaspersky.
When copying control scripts (preinst, postinst etc), all lines are prefixed by spaces (for indentation). This is usually just fine, but breaks here-document terminators as they must not have anything before or after them in the same line.

I implemented a change (will make a pull request shortly) that keeps track of all encountered here-document terminator candidates and if the line matches any of them, it is not prefixed as usual. Saying candidfates as it may produce false positives, but they will not affect anything as they won't match an actual line.
I tested it pretty extensively (with complicated scripts) and it seems reliable. The implementation is probably not the best, though...

malware?

Why is cryptoseed getting installed as a dependency when packages such as Thorium reader, vivaldi, and slimjet are installed via debtap?

Dependencies.

Warning: These dependencies (depend = fields) could not be translated into Arch Linux packages names:
jackd, qt5-default
qt5 - its already supposed to be there, i use kde plasma
jackd - i dont know

libstdc++6 (>= 5.2) converts to depend = aarch64-linux-gnu-gcc>=5.2 on x86_64

I have got a license for the commercial Varicad program. Since I have just switched from Xubuntu to Manjaro I used the debtab script to successfully convert the .deb Package.

Varicad...deb lists in its control part a libstdc++6 dependency. This leads to depend = aarch64-linux-gnu-gcc>=5.2 in .PKGINFO. An ARM64 lib for a x86_64 System?? Maybe the Tables are wrong at this point? I have changed this by hand to libstdc++5. This works. But I am not sure if that is needed because the standard c++ lib should be part of gcc-lib? Now my system has this dependency ... preventing me to deinstall libstdc++5.

There is no notice in the readme about the Packager and the License questions yet. Nothing but enter worked. And any other key than 1,2 or 4 skips the editor on my system. The Varicad program installs to /opt/VariCAD/bin/varicad and installs a link at /usr/bin to that. So pamac notes wrong that varicad was not installed. But that are very mini problems.

@ Helix: But the very first thing now: THANK YOU FOR THE SCRIPT!
This is a way to get even commercial software running.

Spotify: Warning: These dependencies (depend = fields) could not be translated into Arch Linux packages names

https://aur.archlinux.org/packages/spotify/
https://repository-origin.spotify.com/pool/non-free/s/spotify-client/spotify-client_1.1.0.237.g378f6f25-11_amd64.deb

==> Extracting package data...
==> Fixing possible directories structure differencies...
==> Generating .PKGINFO file...

:: Enter Packager name:
spotify

:: Enter package license (you can enter multiple licenses comma separated):


*** Creation of .PKGINFO file in progress. It may take a few minutes, please wait...

Warning: These dependencies (depend =   fields) could not be translated into Arch Linux packages names:
libssl1.0.1, libssl1.0.2
Warning: These optional dependencies (optdepend =   fields) could not be translated into Arch Linux packages names:
libavcodec54, libavcodec57, libavcodec-extra-54, libavcodec-extra57, libavcodec-ffmpeg56, libavcodec-ffmpeg-extra56, libavformat54, libavformat57, libavformat-ffmpeg56

==> Checking and generating .INSTALL file (if necessary)...

:: If you want to edit .PKGINFO and .INSTALL files (in this order), press (1) For vi (2) For nano (3) For default editor (4) For a custom editor or any other key to continue: 


==> Generating .MTREE file...

==> Creating final package...
==> Package successfully created!

==> Generating PKGBUILD file...
==> PKGBUILD and spotify-client-bin.install are now located in "/home/user/spotify-client-bin" and ready to be edited
==> Removing leftover files...

Help output shows duplicate options

When I run $ debtap -h I get this:

Syntax: debtap [option] package_filename

Options:

      -h  --h  -help    --help        Prints this help message
      -u  --u  -update  --update      Update debtap database
      -q  --q  -quiet   --quiet       Bypass all questions, except for editing metadata file(s)
      -Q  --Q  -Quiet   --Quiet       Bypass all questions (not recommended)

debtap keep asking me to run `debtap -u` even after I ran it

Execution log

nodxine at sophy in ~/tmp
↳ sudo debtap -u                                                                                                                               ❲MON, OCT 26❳⇼❲08:01:45 PM❳
[sudo] password for nodxine:
==> Synchronizing pkgfile database...
:: Updating 4 repos...
warning: download failed: http://mirror.dacentec.com/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirror.dacentec.com/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.dacentec.com/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.dacentec.com/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://lug.mtu.edu/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://lug.mtu.edu/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://lug.mtu.edu/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://lug.mtu.edu/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirror.catn.com/pub/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirror.catn.com/pub/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.catn.com/pub/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.catn.com/pub/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://manjarolinux.polymorf.fr/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://manjarolinux.polymorf.fr/stable/core/x86_64/core.files [error 404]
warning: download failed: http://manjarolinux.polymorf.fr/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://manjarolinux.polymorf.fr/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.ragenetwork.de/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.ragenetwork.de/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.ragenetwork.de/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirror.ragenetwork.de/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://manjaro.mirrors.uk2.net/stable/core/x86_64/core.files [error 404]
warning: download failed: http://manjaro.mirrors.uk2.net/stable/community/x86_64/community.files [error 404]
warning: download failed: http://manjaro.mirrors.uk2.net/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://manjaro.mirrors.uk2.net/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://ftp.heanet.ie/mirrors/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.heanet.ie/mirrors/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://ftp.heanet.ie/mirrors/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirror.netzspielplatz.de/manjaro/packages/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirror.netzspielplatz.de/manjaro/packages/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.netzspielplatz.de/manjaro/packages/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.heanet.ie/mirrors/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.netzspielplatz.de/manjaro/packages/stable/community/x86_64/community.files [error 404]
warning: download failed: http://ftp.halifax.rwth-aachen.de/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://ftp.halifax.rwth-aachen.de/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.halifax.rwth-aachen.de/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://ftp.halifax.rwth-aachen.de/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirrors.xservers.ro/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirrors.xservers.ro/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirrors.xservers.ro/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirrors.xservers.ro/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://manjaro.dcc.uchile.cl/stable/community/x86_64/community.files [error 404]
warning: download failed: http://manjaro.dcc.uchile.cl/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://manjaro.dcc.uchile.cl/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://manjaro.dcc.uchile.cl/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.yandex.ru/mirrors/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.yandex.ru/mirrors/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirror.yandex.ru/mirrors/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirror.yandex.ru/mirrors/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.solarvps.com/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirror.solarvps.com/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.solarvps.com/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.solarvps.com/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.tu-chemnitz.de/pub/linux/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://ftp.tu-chemnitz.de/pub/linux/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://ftp.tu-chemnitz.de/pub/linux/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.tu-chemnitz.de/pub/linux/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.nluug.nl/pub/os/Linux/distr/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://ftp.nluug.nl/pub/os/Linux/distr/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.nluug.nl/pub/os/Linux/distr/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.nluug.nl/pub/os/Linux/distr/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirrors.ucr.ac.cr/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirrors.ucr.ac.cr/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirrors.ucr.ac.cr/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://repo.manjaro.org.uk/stable/core/x86_64/core.files [error 404]
warning: download failed: http://repo.manjaro.org.uk/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://repo.manjaro.org.uk/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirrors.ucr.ac.cr/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.lignux.com/manjaro/packages/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirror.lignux.com/manjaro/packages/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.lignux.com/manjaro/packages/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://repo.manjaro.org.uk/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.lignux.com/manjaro/packages/stable/community/x86_64/community.files [error 404]
warning: download failed: http://ftp.lysator.liu.se/pub/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.lysator.liu.se/pub/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.lysator.liu.se/pub/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://ftp.lysator.liu.se/pub/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://www.mirrorservice.org/sites/repo.manjaro.org/repos/stable/core/x86_64/core.files [error 404]
warning: download failed: http://www.mirrorservice.org/sites/repo.manjaro.org/repos/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://www.mirrorservice.org/sites/repo.manjaro.org/repos/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://www.mirrorservice.org/sites/repo.manjaro.org/repos/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirror.zetup.net/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirror.zetup.net/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirror.zetup.net/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirror.zetup.net/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://ftp.tsukuba.wide.ad.jp/Linux/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.tsukuba.wide.ad.jp/Linux/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.tsukuba.wide.ad.jp/Linux/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://ftp.tsukuba.wide.ad.jp/Linux/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://manjaro.uberglobalmirror.com/stable/community/x86_64/community.files [error 404]
warning: download failed: http://manjaro.uberglobalmirror.com/stable/core/x86_64/core.files [error 404]
warning: download failed: http://manjaro.uberglobalmirror.com/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://manjaro.uberglobalmirror.com/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://mirrors.serverhost.ro/manjaro/packages/stable/community/x86_64/community.files [error 404]
warning: download failed: http://mirrors.serverhost.ro/manjaro/packages/stable/core/x86_64/core.files [error 404]
warning: download failed: http://mirrors.serverhost.ro/manjaro/packages/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://mirrors.serverhost.ro/manjaro/packages/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://manjaro.mirrors.linux.ro/repos/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://manjaro.mirrors.linux.ro/repos/stable/community/x86_64/community.files [error 404]
warning: download failed: http://manjaro.mirrors.linux.ro/repos/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://manjaro.mirrors.linux.ro/repos/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.riken.jp/Linux/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.riken.jp/Linux/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.riken.jp/Linux/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://ftp.riken.jp/Linux/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://www.las.ic.unicamp.br/pub/manjarolinux/stable/core/x86_64/core.files [error 404]
warning: download failed: http://www.las.ic.unicamp.br/pub/manjarolinux/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://www.las.ic.unicamp.br/pub/manjarolinux/stable/community/x86_64/community.files [error 404]
warning: download failed: http://www.las.ic.unicamp.br/pub/manjarolinux/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://ftp.dei.uc.pt/pub/linux/manjaro/stable/core/x86_64/core.files [error 404]
warning: download failed: http://ftp.dei.uc.pt/pub/linux/manjaro/stable/community/x86_64/community.files [error 404]
warning: download failed: http://ftp.dei.uc.pt/pub/linux/manjaro/stable/multilib/x86_64/multilib.files [error 404]
warning: download failed: http://ftp.dei.uc.pt/pub/linux/manjaro/stable/extra/x86_64/extra.files [error 404]
warning: download failed: http://ftp.linux.org.tr/manjaro/stable/core/x86_64/core.files [error 404]
error: failed to update repo: core
warning: download failed: http://ftp.linux.org.tr/manjaro/stable/multilib/x86_64/multilib.files [error 404]
error: failed to update repo: multilib
warning: download failed: http://ftp.linux.org.tr/manjaro/stable/community/x86_64/community.files [error 404]
error: failed to update repo: community
warning: download failed: http://ftp.linux.org.tr/manjaro/stable/extra/x86_64/extra.files [error 404]
error: failed to update repo: extra
==> Synchronizing debtap database...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 29.6M  100 29.6M    0     0  67835      0  0:07:38  0:07:38 --:--:-- 74433
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 30.8M  100 30.8M    0     0  45904      0  0:11:45  0:11:45 --:--:-- 46984
==> Downloading latest AUR packages list...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  165k    0  165k    0     0  54538      0 --:--:--  0:00:03 --:--:-- 54551
==> All steps successfully completed!
nodxine at sophy in ~/tmp
↳ debtap atom-amd64.deb                                                                                                                        ❲MON, OCT 26❳⇼❲08:21:54 PM❳
Error: You must run at least once "debtap -u" with root privileges (preferably recently), before running this script
nodxine at sophy in ~/tmp
↳ sudo debtap atom-amd64.deb                                                                                                                   ❲MON, OCT 26❳⇼❲08:45:40 PM❳
[sudo] password for nodxine:
Error: You must run at least once "debtap -u" with root privileges (preferably recently), before running this script

Script Broken: PKGBUILD Cannot Be Created if .deb package doesn't contain any usr/bin files

You've already closed a similar issue because you didn't read what the person was saying and told them their installation was broken.

If you simply try to CONVERT a .deb package that doesn't contain any /usr/bin files (let's say for this example it only contains files in /usr/share and /etc), the conversion will work fine.

But if you try to create a PKGBUILD, it will fail with this error:

==> Generating PKGBUILD file...
ls: cannot access 'usr/bin': No such file or directory
Error: Cannot create PKGBUILD directory, permission denied. Removing leftover files and exiting...

It's trying to ls in the usr/bin directory IN THE PACKAGE, but there isn't one, because the original .deb didn't have anything in usr/bin. Again, this is not a broken installation. At all. Your script is broken.

Again, it will convert packages perfectly fine, but it cannot create a PKGBUILD if the package doesn't contain anything in usr/bin. I'll give you two examples so you don't try to write this off as someone having a "broken installation" and then close the issue:

I have two .deb packages: i3-snapshot_1.0-1ubuntu1~ppa1_amd64.deb, and vulkan-amdgpu-pro_20.10-1048554_amd64.deb. Let's look at their containing files:

dpkg-deb -c i3-snapshot_1.0-1ubuntu1~ppa1_amd64.deb

drwxr-xr-x root/root         0 2019-12-14 22:00 ./
drwxr-xr-x root/root         0 2019-12-14 22:00 ./usr/
drwxr-xr-x root/root         0 2019-12-14 22:00 ./usr/bin/
-rwxr-xr-x root/root    129272 2019-12-14 22:00 ./usr/bin/i3-snapshot
drwxr-xr-x root/root         0 2019-12-14 22:00 ./usr/share/
drwxr-xr-x root/root         0 2019-12-14 22:00 ./usr/share/doc/
drwxr-xr-x root/root         0 2019-12-14 22:00 ./usr/share/doc/i3-snapshot/
-rw-r--r-- root/root       248 2019-12-14 22:00 ./usr/share/doc/i3-snapshot/changelog.Debian.gz
-rw-r--r-- root/root      4588 2019-12-14 22:00 ./usr/share/doc/i3-snapshot/copyright

Notice, the i3-snapshot has files in usr/bin. Now, let's look at the other one:

drwxr-xr-x root/root         0 2020-04-08 23:50 ./
drwxr-xr-x root/root         0 2020-04-08 23:50 ./etc/
drwxr-xr-x root/root         0 2020-04-08 23:50 ./etc/vulkan/
drwxr-xr-x root/root         0 2020-04-08 23:50 ./etc/vulkan/icd.d/
drwxr-xr-x root/root         0 2020-04-08 23:50 ./opt/
drwxr-xr-x root/root         0 2020-04-08 23:50 ./opt/amdgpu-pro/
drwxr-xr-x root/root         0 2020-04-08 23:50 ./opt/amdgpu-pro/etc/
drwxr-xr-x root/root         0 2020-04-08 23:50 ./opt/amdgpu-pro/etc/vulkan/
drwxr-xr-x root/root         0 2020-04-08 23:50 ./opt/amdgpu-pro/etc/vulkan/icd.d/
-rw-r--r-- root/root       173 2020-04-08 23:50 ./opt/amdgpu-pro/etc/vulkan/icd.d/amd_icd64.json
drwxr-xr-x root/root         0 2020-04-08 23:50 ./opt/amdgpu-pro/lib/
drwxr-xr-x root/root         0 2020-04-08 23:50 ./opt/amdgpu-pro/lib/x86_64-linux-gnu/
-rw-r--r-- root/root  42276064 2020-04-08 23:50 ./opt/amdgpu-pro/lib/x86_64-linux-gnu/amdvlk64.so
drwxr-xr-x root/root         0 2020-04-08 23:50 ./usr/
drwxr-xr-x root/root         0 2020-04-08 23:50 ./usr/share/
drwxr-xr-x root/root         0 2020-04-08 23:50 ./usr/share/doc/
drwxr-xr-x root/root         0 2020-04-08 23:50 ./usr/share/doc/vulkan-amdgpu-pro/
-rw-r--r-- root/root       243 2020-04-08 23:50 ./usr/share/doc/vulkan-amdgpu-pro/changelog.Debian.gz
-rw-r--r-- root/root      9551 2020-04-08 23:50 ./usr/share/doc/vulkan-amdgpu-pro/copyright

Notice, this .deb has NO files in usr/bin, therefore the package won't have a usr/bin

So, when you run debtap -P i3-snapshot_1.0-1ubuntu1~ppa1_amd64.deb, it runs perfectly, and creates a PKGBUILD, but when you run debtap -P vulkan-amdgpu-pro_20.10-1048554_amd64.deb, it fails with:

==> Generating PKGBUILD file...
ls: cannot access 'usr/bin': No such file or directory
Error: Cannot create PKGBUILD directory, permission denied. Removing leftover files and exiting...

Because somewhere in your script, when it comes time to create a PKGBUILD, You're trying to ls a directory in the package that does not exist.

The script is gigantic, I'm trying to parse through it and find the offending location, but it'll take me a while. When I do, I'll post it, though I'm sure you know exactly where you call for this.

I hope you don't just close this issue like you did the other one, because that person was definitely correct. If the package being created DOES NOT contain any ./usr/bin/ files, it WILL fail trying to create a PKGBUILD.

debtap got the names of dependencies connected together

When I tried to generate a PKGBUILD for vst-video.deb (https://github.com/xymov/vst-video/releases/download/V2.55/vst-video.deb), I got a dependency like this:

libqt5xml5libqt5concurrent5libqt5multimedia5libqt5multimediawidgets5libqt5core5alibqt5gui5libqt5widgets5libqt5network5

I checked the control file inside the package, the dependencies are written like this:

Depends:libqt5xml5,libqt5concurrent5,libqt5multimedia5,libqt5multimediawidgets5,libqt5core5a,libqt5gui5,libqt5widgets5,libqt5network5

It seems that the missing spaces after commas caused debtap failing to read the dependencies. Is this a bug in debtap?

Package info before/during conversion

Since debtap already has to extract package information, it would probably be good if some was shown to the user as it is parsed, e.g. target architecture.

debtap -u fails with 404 error

When I try run debtap -u I get a 404 not found error:

garyvdm@garyvdm ~ % sudo debtap -u                                                            :(
==> Synchronizing pkgfile database...
:: Updating 5 repos...
  infinality-bundle is up to date
  multilib is up to date
  core is up to date
  extra is up to date
  community is up to date
==> Synchronizing debtap database...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 29.7M  100 29.7M    0     0   498k      0  0:01:01  0:01:01 --:--:--  399k
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0curl: (22) The requested URL returned error: 404 Not Found

gzip: /var/cache/debtap/ubuntu-packages-files.gz: unexpected end of file
Synchronization failed. Exiting...

Using version 2.1.5-1

Brother printer drivers- Incorrect translation of some file locations

OS: Manjaro 5.3.12
Debtap: 3.2.2

Background
Just installed Manjaro/Arch. I have a Brother MFC 7820N network printer. As a specific driver for this printer doesn't seem to exist in the repos or AUR, the aim was to use Debtap to convert the .deb files supplied by Brother.

Target Files

  1. brmfc7820nlpr-2.0.1-1.i386.deb
  2. cupswrapperMFC7820N-2.0.1-2.i386.deb

To Reproduce

  1. Download and save the .deb files to a working directory
  2. cd to the directory. Run-
  • debtap -s brmfc7820nlpr-2.0.1-1.i386.deb
  • debtap -s cupswrapperMFC7820N-2.0.1-2.i386.deb
  1. Attempt to install-
  • sudo pacman -U brmfc7820nlpr-2.0.1-1-x86_64.pkg.tar.xz
  • sudo pacman -U cupswrappermfc7820n-2.0.1-1-x86_64.pkg.tar.xz

Symptoms
Installation of both packages fails with a number of errors, including several "file not found" errors for files in /usr/local/Brother. By inspection I could see the packages created by debtap had what looked like the right files, but had installed some of them in /usr/Brother.

I manually moved/coped the contents of /usr/Brother over to /usr/local/Brother and deleted the now empty /usr/Brother directory. After this I was able to go into CUPS admin and by updating the printer to find it's network location, I was able to get the printer working.

It's possible debtap has simply mis-translated the location of these files. However from experience with the Brother drivers on windows I know the installers can be quite clunky and seem to run pre or post- install scripts. I wonder if there is a script in here somewhere that is expected to move the driver files into a platform-dependent location?

Note: I can upload the converted packages if that would be useful, but I don't want to add unecessarily large attachments to the bug report.

Strings unescaped during the conversion

I was converting Kaspersky Endpoint Security DEB (company policy to have it installed), which creates and executes a Perl script in its preisnt. Perl variables (and other strings) are escaped to avoid being interpreted by Bash, but during the conversation, Debtap unescaped them, causing Bash to keel over during the installation.

Example:

Original preisnt script contained:
my (\$logic, \$pkgmgr) = klinstall::get_work_logic(\$0, \\@ARGV);

In the generated .INSTALL, I ended up with:
my ($logic, $pkgmgr) = klinstall::get_work_logic($0, \@ARGV);

debtap exits with 404 error

I tried using debtap to convert openarena to arm arch linux as the aur package does not support armv7h architecture. When I try to convert, I get
Error: You must run at least once "debtap -u" with root privileges (preferably recently), before running this script
So I ran the debtap -u command and it exits with the said 404 error
`==> Synchronizing pkgfile database...
:: Updating 5 repos...
core is up to date
aur is up to date
alarm is up to date
community is up to date
extra is up to date
==> Synchronizing debtap database...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
curl: (22) The requested URL returned error: 404 Not Found

gzip: /var/cache/debtap/debian-packages-files.gz: unexpected end of file
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
curl: (22) The requested URL returned error: 404 Not Found

gzip: /var/cache/debtap/ubuntu-packages-files.gz: unexpected end of file
Synchronization failed. Exiting...`

This is the output of the 'curl -s http://packages.ubuntu.com | grep option | gawk -F '=' '{print $2}' | gawk '{print $1}' | grep -v option | tac | sed -n 2'{p;q;}' | sed s'/("|-updated|-backports)//g''

"yakkety"

Any help would be appreciated

Multiple file processing in one command

I'm not sure exactly where to put this, but I would really like it if you added the ability to convert multiple packages in one command. I don't mean do them all at once, just have it so that you don't need to enter 'debtap [option] filename' each time. This would be greatly appreciated.

Avoid needing host root privileges

This looks like a great project, but running 3.4k lines of shell code from a third party project as root to set up a build environment sounds very risky. It would be great if there was (for example) a Vagrantfile to easily run this is a contained environment.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.