Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Cygwin depext doesn't report errors for non-existent packages #5839

Open
dra27 opened this issue Feb 15, 2024 · 1 comment
Open

Cygwin depext doesn't report errors for non-existent packages #5839

dra27 opened this issue Feb 15, 2024 · 1 comment

Comments

@dra27
Copy link
Member

dra27 commented Feb 15, 2024

Cygwin setup doesn't return an error code for a package name which doesn't exist, there's simply a line in the console output:

Package 'does-not-exist' not found.

We should already have the information available to be able to display an error at this stage:

C:\Users\DRA>opam install conf-zstd
The following actions will be performed:
=== install 2 packages
  ∗ conf-mingw-w64-zstd-i686 1     [required by conf-zstd]
  ∗ conf-zstd                1.3.8

Proceed with ∗ 2 installations? [y/n] y

The following system packages will first need to be installed:
    xxx-mingw64-i686-zstd

instead of:

<><> Handling external dependencies <><><><><><><><><><><><><><><><><><><><>  🐫

+ C:\Users\DRA\AppData\Local\opam\.cygwin\setup-x86_64.exe "--root" "C:\\Users\\DRA\\AppData\\Local\\opam\\.cygwin\\root" "--quiet-mode" "hidden" "--no-shortcuts" "--no-startmenu" "--no-desktop" "--no-admin" "--packages" "xxx-mingw64-i686-zstd" "--symlink-type" "native" "--upgrade-also" "--only-site" "--no-version-check" "--site" "https://cygwin.mirror.constant.com/" "--local-package-dir" "C:\\Users\\DRA\\AppData\\Local\\opam\\.cygwin\\cache"
- Starting cygwin install, version 2.930
- User has NO backup/restore rights
- User has NO symlink creation right
- Current Directory: C:\Users\DRA\AppData\Local\opam\.cygwin\cache
- root: C:\Users\DRA\AppData\Local\opam\.cygwin\root user
- Changing gid back to original
- Selected local directory: C:\Users\DRA\AppData\Local\opam\.cygwin\cache
- net: Preconfig
- site: https://cygwin.mirror.constant.com/
- Package 'xxx-mingw64-i686-zstd' not found.
- solving: 0 tasks, update: yes, use test packages: no
- solving: 0 tasks, update: no, use test packages: no
- Augmented Transaction List: is empty
- Registry value set: HKEY_CURRENT_USER\Software\Cygwin\setup\rootdir = "C:\Users\DRA\AppData\Local\opam\.cygwin\root"
- running: C:\Users\DRA\AppData\Local\opam\.cygwin\root\bin\dash.exe "/etc/postinstall/0p_000_autorebase.dash"
- running: C:\Users\DRA\AppData\Local\opam\.cygwin\root\bin\dash.exe "/etc/postinstall/0p_update-info-dir.dash"
- running: C:\Users\DRA\AppData\Local\opam\.cygwin\root\bin\dash.exe "/etc/postinstall/zp_man-db-update-index.dash"
- Ending cygwin install

<><> Processing actions <><><><><><><><><><><><><><><><><><><><><><><><><><>  🐫
[ERROR] The compilation of conf-mingw-w64-zstd-i686.1 failed at "pkgconf --personality=i686-w64-mingw32 libzstd".

#=== ERROR while compiling conf-mingw-w64-zstd-i686.1 =========================#
# context     2.2.0~beta2~dev | win32/x86_64 | ocaml-arch-x86_32.1 ocaml-system-mingw.1 | git+file://C:/Devel/opam-repository5#windows-initial
# path        ~\AppData\Local\opam\manpath\.opam-switch\build\conf-mingw-w64-zstd-i686.1
# command     ~\AppData\Local\opam\.cygwin\root\bin\pkgconf.exe --personality=i686-w64-mingw32 libzstd
# exit-code   1
# env-file    ~\AppData\Local\opam\log\conf-mingw-w64-zstd-i686-8284-af926c.env
# output-file ~\AppData\Local\opam\log\conf-mingw-w64-zstd-i686-8284-af926c.out



<><> Error report <><><><><><><><><><><><><><><><><><><><><><><><><><><><><>  🐫
┌─ The following actions failed
│ λ build conf-mingw-w64-zstd-i686 1
└─
╶─ No changes have been performed

(in fact, wouldn't this be better for depext on all platforms?)

@dra27
Copy link
Member Author

dra27 commented Feb 15, 2024

I'm regarding it as a bug because the requested external dependency was not installed, yet opam continued, even though the reason for that is not strictly opam's fault! 🙂

# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

No branches or pull requests

1 participant