Commit Graph

139 Commits

Author SHA1 Message Date
Jeremy Drake
c50eb37207 filesystem: add /etc/os-release
Used by etc-update to tell if a system is "Arch-like"
2021-06-04 13:11:18 -07:00
Christoph Reiter
9246acfd60 Revert "filesystem: remove empty mingw root directories"
This reverts commit 051eb1c876.

See https://github.com/msys2/MSYS2-packages/issues/2502
2021-05-14 20:13:48 +02:00
Christoph Reiter
051eb1c876 filesystem: remove empty mingw root directories
I don't think they are actually needed anymore
2021-05-13 18:35:58 +02:00
Christoph Reiter
86141654fa filesystem: bump pkgrel, update checksums 2021-05-09 20:29:47 +02:00
Koichi Murase
796df420b7 filesystem/dot.inputrc: remove an unused and incorrect keybinding 2021-05-09 12:19:41 +09:00
Christoph Reiter
e8d696bbc4 filesystem: set XDG_DATA_DIRS for mingw bash-completion
This adds a new profile.d/ script where we can add stuff without changing
/etc/profile and triggering a pacman backup.

Fixes #2438
2021-04-23 10:52:43 +02:00
Christoph Reiter
62f08f4fbc filesystem, gnupg, msys2-keyring: avoid keeping gpg-agent/dirmngr around
They get started in the background and stay around which comes with various problems:
* The files can't be deleted until they are stopped
* Some CI systems wait until all programs are stopped
* On a cygwin update we have to restart everything or forking will be broken
  (though pacman takes care of that now by killing everything cygwin-like on a core update)

Ideally though they would just exit in a controlled way after we no longer need them.

The reason this uses GNUPGHOME instead of passing --home to gpgconf is that dirmngr started by
"pacman-key --refresh-keys" somehow couldn't be killed that way.
Maybe because gpg doesn't forward --homedir in that case. Setting GNUPGHOME helped.
2021-04-18 21:14:38 +02:00
Jeremy Drake
e6cfdf08a5 add CLANGARM64 MSYSTEM/MINGW_ARCH 2021-04-07 21:38:50 -07:00
Christoph Reiter
e9007a72e6 filesystem: update icons, finish support for ucrt64/clang64
Fixes #2406
2021-03-31 19:46:53 +02:00
Christoph Reiter
e1b769b0e4 filesystem: fix missing CONFIG_SITE breaking configure host detection
We want configure to always go through our config.site. It first
looks at CONFIG_SITE, then the prefix if there is one and then falls
back to our default. But this means if a prefix is set it wouldn't
use it.

Fix this by setting CONFIG_SITE always like before.

Broken by 9a37bb560a
2021-03-24 22:29:10 +01:00
Christoph Reiter
1072c33404 filesystem: more ucrt things 2021-03-21 17:54:35 +01:00
Christoph Reiter
1869c1e238 filesystem: typo.. 2021-03-21 17:36:06 +01:00
Christoph Reiter
9c4cb76f7b filesystem: add ucrt64 2021-03-21 09:02:43 +01:00
Christoph Reiter
9a37bb560a filesystem: Clean up CONFIG_SITE usage
Just depend on the MSYSTEM_ env vars being set properly. This allows
us to have one config.site file that handles all cases.
2021-03-21 07:41:21 +01:00
David Macek
f77906b4a3 filesystem: Avoid trying to chmod /dev/{shm,mqueue}
Although the default and most used way to install MSYS2 is to have it
user-writable, some users prefer to have the root writable only to
admins.  In that case, the 01-devices.post script would always print out
two failures on "login" when trying to chmod /dev/{shm,mqueue}.  Since
the only supported configuration for MSYS2 is to mount `/` with noacl
where chmod() is a no-op, the failure is purely cosmetic, as is the
chmod invocation itself.  For these reasons, let's not chmod at all.

I'm aware the non-user-writable root configuration itself is not
officially supported either, but I've been using it like that for years
now and this is the only issue I know of, so I think it's reasonable to
resolve this.
2021-02-10 13:44:44 +01:00
jeremyd2019
8f47f0ac89 filesystem: update sha256sums 2021-01-03 00:15:12 -08:00
jeremyd2019
516a0b8318 filesystem: update pkgver 2021-01-03 00:09:33 -08:00
jeremyd2019
932687a742 filesystem: add CLANG32 and CLANG64 to msystem 2021-01-03 00:08:07 -08:00
jeremyd2019
6f2e18300f filesystem: deduplicate MSYSTEM handling
also add handling for CLANG* in addition to MINGW* MSYSTEM values
2020-12-31 16:02:39 -08:00
Christoph Reiter
d88c4706bd Use zstd for all packages now
It's been long enough and everyone should have a pacman that supports it
2020-12-19 17:48:10 +01:00
Miloš Komarčević
8481dd948d filesystem: bump version 2020-10-12 09:22:21 +02:00
Miloš Komarčević
082493ae57 filesystem: use matching icon for console
Helps identifying window thumbnails when switching between MSYS and MINGW64 consoles
2020-10-09 13:35:45 +02:00
fauxpark
3471304f54 Bump pkgrel 2020-08-13 06:52:06 +10:00
fauxpark
7530d8e962 Override %SHELL% for bash 2020-08-13 06:50:17 +10:00
Christoph Reiter
8a7ada7fbf filesystem: add mingw32.ico and mingw64.ico
Fixes #2081
2020-08-06 00:00:09 +02:00
Christoph Reiter
9f3943b8e4 filesystem: remove rege-info.sh (#2044)
It calls install-info on all info files on the first MSYS2 start, but all
the info files are already installed in our current installer.

I'm not 100% sure why this was added, but I guess because of #1998 the installer
created in a chroot didn't install the info files properly and thus they were
missing on a fresh install. This is no longer the case now.

regen-info.sh is called in /etc/profile and part of the "backup" array in the PKGBUILD
so the call might not be removed if the user has changed /etc/profile. Since it is only
called in the first MSYS2 session this shouldn't lead to any problems.
2020-07-17 10:16:01 +03:00
Christoph Reiter
20f306e94d filesystem: fix upgrade (#2022)
msys2-base was removed from dash and filesystem, but filesystem gets updated
first and then fails beause it would break dash which hasn't been updated yet.

So add the provides back.

This fixes:

error: failed to prepare transaction (could not satisfy dependencies)
:: installing filesystem (2020.02-3) breaks dependency 'msys2-base' required by dash
2020-06-25 08:38:16 +03:00
Yasuhiro KIMURA
4a6f6a1511 filesystem: Make msystem compatible with POSIX compliant shells. (#2009)
Behavior about the value of HOSTTYPE and MACHTYPE is not compatible
between various POSIX compliant shells. For example zsh doesn't set
HOSTTYPE at all and set MACHTYPE to that of HOSTTYPE in bash. I
checked source tree of bash and found that HOSTTYPE is set to the
result of `uname -m` and that MACHTYPE is set to the result of `uname
-m` plus "-pc-msys".So change code accordingly.

This fixes issue #2008.

Co-authored-by: Yasuhiro KIMURA <yasu@utahime.org>
2020-06-23 08:11:26 +03:00
David Macek
19bd06b131 [RFC] Cleanup (#1984)
* Remove msys2-runtime dependencies

* Remove `base` group

* Remove some packages from `base-devel` group
2020-06-02 09:28:40 +03:00
Christoph Reiter
fa38d385cf Switch to zstd by default except for core packages (#1969)
PKGEXT in PKGBUILD wins over the value set in makepkg.conf
2020-05-22 08:51:02 +03:00
Alexey Pavlov
0213401e91 filesystem: Rebuild 2020-02-24 21:51:37 +03:00
hiroakit
7476bdd9b4 Remove double quotes of the LOGINSHELL (#1868)
* Remove double quotes of the LOGINSHELL

When set shell arguments, LOGINSHELL has double quotes.
In the default, L6: set "LOGINSHELL=bash". 
I followed the format it.

* Add value to $SHELL for zsh

Issue:
1. Run, C:\msys64\msys2_shell.cmd -mingw64 -shell zsh
2. echo $SHELL
3. Nothing
2020-02-24 10:34:24 +03:00
Alexey Pavlov
0d665cc45b filesystem: Rebuild 2020-02-06 11:27:53 +03:00
Tanzinul Islam
1ea229850a Fix msys2_shell.cmd argument-handling with spaces (#1836)
* Fix msys2_shell.cmd argument-handling with spaces

Commit 11ba641bed intended to preserve [`cmd.exe` delimiter characters](https://ss64.com/nt/syntax-esc.html#delimiters) in the command line passed on to `bash`, but broke the handling of `-where` directories with spaces in them. Fix this by:

 - Incrementing `shiftCounter` with any quoted arguments treated as separate words, because the `FOR /F ... IN`-loop at the end cannot treat them (in the full command) as single parameters.
 - Using the full list of `cmd.exe` delimiters in the `FOR /F ... IN`-loop when skipping the initial tokens.

Tested this with:

```
C:\msys2\msys2_shell.cmd -defterm -no-start -mingw64 -where <DIR> -shell bash -c $@ -- echo hello there, --world=windows
```

where `<DIR>` is the following:

 - C:\Users
 - C:\Progra~1
 - "C:\Program Files"
 - "C:\Program Files (x86)"
 - "C:\Users\T-17\Documents\Projects and Learning\test,dir"

Fixes #1826

* Clean up `FOR /F ... IN`-command

* Clean up working variables

* Adhere to lowercase CALL convention

* Prefix working variables with `msys2_` to prevent collisions with user-defined variables

* Don't clobber quotes and parentheses in final Bash command line

* Prevent warning trace on no arguments

* Handle cmd.exe metacharacters (e.g. parentheses) in Bash command line
2020-02-06 08:05:49 +03:00
Alexey Pavlov
001fb00426 filesystem: Fix checksums 2020-01-16 10:17:59 +03:00
Alexey Pavlov
fa59bbbb0e filesystem: Rebuild 2020-01-15 16:09:34 +03:00
Tanzinul Islam
11ba641bed msys2_shell.cmd: Avoid argument splitting by cmd.exe (#1795)
Consider this inline invocation in a Windows Command Prompt:

```
C:\msys2\msys2_shell.cmd -defterm -no-start -mingw64 -here -c $@ -- echo hello there, --world=windows
```

This currently produces:

>hello there, --world windows

Note the absence of the `=` character. This is due to the word-splitting done by `cmd.exe` to form the positional parameters (`%1` - `%9`). The same word-splitting is not done on the `%*` special variable, so derive the remaining command line arguments.

With this fix, the above command produces:

>hello there, --world=windows
2020-01-13 07:46:14 +03:00
Viktor Szakats
7f7316ba9b use HTTPS in URLs where supported (#1741) 2019-09-30 09:33:57 +03:00
Niklas Holm
4ae39f3c2e filesystem: minor fix (#1557)
Minor fix, I'm guessing this was the original intention.
2019-01-22 13:50:19 +03:00
Alexey Pavlov
04fc2d6020 filesystem: Add clang mount points for future use 2018-12-15 21:47:05 +03:00
jannick0
7a975b1508 main-config.site: set default value of var 'as_echo' to 'echo' (#1519)
The variable 'as_echo' is not set in a virgin shell, but by 'autoconf'
and friends. Setting the default value to 'echo' facilitates running
'configure' in a virgin shell.

* filesystem/main-config.site: see above.
* filesystem/mingw32-config.site: see above.
* filesystem/mingw64-config.site: see above.

Fixes #1518
2018-12-15 20:31:32 +03:00
Rafael Kitover
c31f18202d better support for Win10 OpenSSH server (#1375)
If msys2 bash is set as the DefaultShell for the Win10 OpenSSH server,
there is no way to pass -l to make it a login shell, so /etc/profile is
not sourced, PATH is not set, and the bashrc produces errors.

Detect this case in /etc/bash.bashrc, by checking for the SSH_CONNECTION
environment variable and PATH not having msys2 elements, and source
/etc/profile.
2018-08-08 08:46:00 +03:00
Alexey Pavlov
6950837a05 filesystem: Fix checksums. Rebuild 2018-06-04 09:44:35 +03:00
pchemguy
45151d01c6 Add support for more than 9 shell command line arguments
Adds a loop collecting all command line arguments remaining after msys2_shell.cmd processing
2018-05-29 15:24:56 +03:00
Henrik Jensen
714549756f Make CHERE_INVOKING visible for users.
Enables users to take action (e.g. in `~/.bash_profile`) if msys was invoked with `CHERE_INVOKING` set.
Example usage (start in same directory as at last logout) :
Add to ~/.bash_profile:
  # Change to pwd at last logout unless $CHERE_INVOKING was set
  if [ ! -z "${CHERE_INVOKING_VISIBLE_FOR_USER}" ]; then
    unset CHERE_INVOKING_VISIBLE_FOR_USER
  else
    [ -s ~/.lastdirectory ] && cd `cat ~/.lastdirectory`
  fi
Add to ~/.bash_logout:
  pwd > ~/.lastdirectory
2018-05-06 06:33:38 +02:00
Alexey Pavlov
e9e36738be filesystem: Update pkgsums, rebuild 2018-04-19 13:43:47 +03:00
Алексей
688944cee3 Merge pull request #1205 from niklasholm/patch-5
filesystem: Include /mingwXX/local/man on MANPATH
2018-04-19 07:41:18 +03:00
Алексей
885d5ba144 Merge pull request #1214 from AeliusSaionji/patch-1
remove minor bashism from /etc/profile
2018-04-19 07:40:27 +03:00
Алексей
dc3d9f2c6a Merge pull request #1169 from jd28/master
filesystem: Add -shell parameter to msys2_shell.cmd
2018-04-19 07:39:48 +03:00
Aelius
950791306b remove minor bashism from /etc/profile
Noticed this when using `dash` as my shell.

https://wiki.ubuntu.com/DashAsBinSh#source
2018-04-04 15:28:06 -04:00