Updated msys2

This commit is contained in:
gator96100 2019-08-16 02:06:21 +02:00
parent 6a85995508
commit f0dc1ea8b0
13308 changed files with 689276 additions and 46605 deletions

@ -0,0 +1,21 @@
# This file is in public domain.
# Original author: Karlson2k (Evgeny Grin)
# Written for MSys2/MinGW64 to help running 'configure' scripts
# Defaults for MinGW64-targeted programs
# Set proper selfname on bash and fallback to default name on other shells
test -n "${BASH_SOURCE}" 2>/dev/null && config_site_me="${BASH_SOURCE[0]##*/}" || config_site_me=config.site
# Set default 'host' to speedup configure
if test -z "$build_alias"; then
build_alias="${MSYSTEM_CHOST-i686-w64-mingw32}" && \
${as_echo-echo} "$config_site_me:${as_lineno-$LINENO}: default build_alias set to $build_alias" >&5
fi
# Set default 'prefix' to "/clang32"
if ( test -z "$prefix" || test "x$prefix" = "xNONE" ) && \
( test -z "$exec_prefix" || test "x$exec_prefix" = "xNONE" ); then
prefix="${MSYSTEM_PREFIX-/clang32}" && \
${as_echo-echo} "$config_site_me:${as_lineno-$LINENO}: default prefix set to $prefix" >&5
fi

@ -0,0 +1,21 @@
# This file is in public domain.
# Original author: Karlson2k (Evgeny Grin)
# Written for MSys2/MinGW64 to help running 'configure' scripts
# Defaults for MinGW64-targeted programs
# Set proper selfname on bash and fallback to default name on other shells
test -n "${BASH_SOURCE}" 2>/dev/null && config_site_me="${BASH_SOURCE[0]##*/}" || config_site_me=config.site
# Set default 'host' to speedup configure
if test -z "$build_alias"; then
build_alias="${MSYSTEM_CHOST-x86_64-w64-mingw32}" && \
${as_echo-echo} "$config_site_me:${as_lineno-$LINENO}: default build_alias set to $build_alias" >&5
fi
# Set default 'prefix' to "/clang64"
if ( test -z "$prefix" || test "x$prefix" = "xNONE" ) && \
( test -z "$exec_prefix" || test "x$exec_prefix" = "xNONE" ); then
prefix="${MSYSTEM_PREFIX-/clang64}" && \
${as_echo-echo} "$config_site_me:${as_lineno-$LINENO}: default prefix set to $prefix" >&5
fi

@ -1,7 +1,7 @@
# Configuration file for dircolors, a utility to help you set the
# LS_COLORS environment variable used by GNU ls with the --color option.
# Copyright (C) 1996-2016 Free Software Foundation, Inc.
# Copyright (C) 1996-2019 Free Software Foundation, Inc.
# Copying and distribution of this file, with or without modification,
# are permitted provided the copyright notice and this notice are preserved.
@ -35,8 +35,10 @@ TERM tmux*
TERM vt100
TERM xterm*
# Below are the color init strings for the basic file types. A color init
# string consists of one or more of the following numeric codes:
# Below are the color init strings for the basic file types.
# One can use codes for 256 or more colors supported by modern terminals.
# The default color codes use the capabilities of an 8 color terminal
# with some additional attributes as per the following codes:
# Attribute codes:
# 00=none 01=bold 04=underscore 05=blink 07=reverse 08=concealed
# Text color codes:
@ -98,7 +100,6 @@ EXEC 01;32
.t7z 01;31
.zip 01;31
.z 01;31
.Z 01;31
.dz 01;31
.gz 01;31
.lrz 01;31
@ -126,6 +127,10 @@ EXEC 01;32
.7z 01;31
.rz 01;31
.cab 01;31
.wim 01;31
.swm 01;31
.dwm 01;31
.esd 01;31
# image formats
.jpg 01;35
@ -176,7 +181,7 @@ EXEC 01;32
.cgm 01;35
.emf 01;35
# http://wiki.xiph.org/index.php/MIME_Types_and_File_Extensions
# https://wiki.xiph.org/MIME_Types_and_File_Extensions
.ogv 01;35
.ogx 01;35
@ -194,7 +199,7 @@ EXEC 01;32
.ra 00;36
.wav 00;36
# http://wiki.xiph.org/index.php/MIME_Types_and_File_Extensions
# https://wiki.xiph.org/MIME_Types_and_File_Extensions
.oga 00;36
.opus 00;36
.spx 00;36

@ -15,6 +15,11 @@
# If not running interactively, don't do anything
[[ "$-" != *i* ]] && return
# If started from sshd, make sure profile is sourced
if [[ -n "$SSH_CONNECTION" ]] && [[ "$PATH" != *:/usr/bin* ]]; then
source /etc/profile
fi
# Warnings
unset _warning_found
for _warning_prefix in '' ${MINGW_PREFIX}; do

@ -11,6 +11,14 @@ elif test "x$MSYSTEM" = "xMINGW32"; then
if test -r "${MINGW_PREFIX-/mingw32}/etc/config.site"; then
. "${MINGW_PREFIX-/mingw32}/etc/config.site"
fi
elif test "x$MSYSTEM" = "xCLANG64"; then
if test -r "${MINGW_PREFIX-/clang64}/etc/config.site"; then
. "${MINGW_PREFIX-/clang64}/etc/config.site"
fi
elif test "x$MSYSTEM" = "xCLANG32"; then
if test -r "${MINGW_PREFIX-/clang32}/etc/config.site"; then
. "${MINGW_PREFIX-/clang32}/etc/config.site"
fi
else
# Defaults for MSys2-targeted programs
@ -20,14 +28,14 @@ else
# Set default 'host' to speedup configure
if test -z "$build_alias"; then
build_alias="${MSYSTEM_CARCH-x86_64}-pc-msys" && \
$as_echo "$config_site_me:${as_lineno-$LINENO}: default build_alias set to $build_alias" >&5
${as_echo-echo} "$config_site_me:${as_lineno-$LINENO}: default build_alias set to $build_alias" >&5
fi
# Set default 'prefix' to "/usr"
if ( test -z "$prefix" || test "x$prefix" = "xNONE" ) && \
( test -z "$exec_prefix" || test "x$exec_prefix" = "xNONE" ); then
prefix="${MSYSTEM_PREFIX-/usr}" && \
$as_echo "$config_site_me:${as_lineno-$LINENO}: default prefix set to $prefix" >&5
${as_echo-echo} "$config_site_me:${as_lineno-$LINENO}: default prefix set to $prefix" >&5
fi
fi

Binary file not shown.

@ -0,0 +1,171 @@
#
# /etc/makepkg.conf
#
#########################################################################
# SOURCE ACQUISITION
#########################################################################
#
#-- The download utilities that makepkg should use to acquire sources
# Format: 'protocol::agent'
DLAGENTS=('ftp::/usr/bin/curl -fC - --ftp-pasv --retry 3 --retry-delay 3 -o %o %u'
'http::/usr/bin/curl -qb "" -fLC - --retry 3 --retry-delay 3 -o %o %u'
'https::/usr/bin/curl -qb "" -fLC - --retry 3 --retry-delay 3 -o %o %u'
'rsync::/usr/bin/rsync --no-motd -z %u %o'
'scp::/usr/bin/scp -C %u %o')
# Other common tools:
# /usr/bin/snarf
# /usr/bin/lftpget -c
# /usr/bin/wget
#-- The package required by makepkg to download VCS sources
# Format: 'protocol::package'
VCSCLIENTS=('bzr::bzr'
'git::git'
'hg::mercurial'
'svn::subversion')
#-- Using git am to apply patches has benefits, but also downsides
# one being that people without their .gitconfig set get prompts
# and the other being that the sha1s vary each time, so fix them
GIT_COMMITTER_NAME="makepkg"
GIT_COMMITTER_EMAIL="makepkg@msys2.org"
function gitam_mkpkg() {
git am --committer-date-is-author-date "$@"
}
#########################################################################
# ARCHITECTURE, COMPILE FLAGS
#########################################################################
#
CARCH="i686"
CHOST="i686-w64-mingw32"
#########################################################################
# Mingw toolchains stuff
#########################################################################
#
MINGW_CHOST="i686-w64-mingw32"
MINGW_PREFIX="/clang32"
MINGW_PACKAGE_PREFIX="clang-mingw-w64-i686"
# DirectX compatibility environment variable
DXSDK_DIR=${MINGW_PREFIX}/${MINGW_CHOST}
#-- Compiler and Linker Flags
# -march (or -mcpu) builds exclusively for an architecture
# -mtune optimizes for an architecture, but builds for whole processor family
CPPFLAGS="-D_FORTIFY_SOURCE=2 -D__USE_MINGW_ANSI_STDIO=1"
CFLAGS="-march=i686 -mtune=generic -O2 -pipe"
CXXFLAGS="-march=i686 -mtune=generic -O2 -pipe"
LDFLAGS="-pipe"
# Uncomment to enable hardening (ASLR, DEP)
#LDFLAGS="-pipe -Wl,--dynamicbase,--nxcompat"
#-- Make Flags: change this for DistCC/SMP systems
MAKEFLAGS="-j$(($(nproc)+1))"
#-- Debugging flags
DEBUG_CFLAGS="-ggdb -Og"
DEBUG_CXXFLAGS="-ggdb -Og"
ACLOCAL_PATH="${MINGW_PREFIX}/share/aclocal:/usr/share/aclocal"
PKG_CONFIG_PATH="${MINGW_PREFIX}/lib/pkgconfig:${MINGW_PREFIX}/share/pkgconfig"
#########################################################################
# BUILD ENVIRONMENT
#########################################################################
#
# Defaults: BUILDENV=(fakeroot !distcc color !ccache check !sign)
# A negated environment option will do the opposite of the comments below.
#
#-- distcc: Use the Distributed C/C++/ObjC compiler
#-- color: Colorize output messages
#-- ccache: Use ccache to cache compilation
#-- check: Run the check() function if present in the PKGBUILD
#-- sign: Generate PGP signature file
#
BUILDENV=(!distcc color !ccache check !sign)
#
#-- If using DistCC, your MAKEFLAGS will also need modification. In addition,
#-- specify a space-delimited list of hosts running in the DistCC cluster.
#DISTCC_HOSTS=""
#
#-- Specify a directory for package building.
#BUILDDIR=/tmp/makepkg
#########################################################################
# GLOBAL PACKAGE OPTIONS
# These are default values for the options=() settings
#########################################################################
#
# Default: OPTIONS=(strip docs !libtool staticlibs emptydirs zipman purge !upx !debug)
# A negated option will do the opposite of the comments below.
#
#-- strip: Strip symbols from binaries/libraries
#-- docs: Save doc directories specified by DOC_DIRS
#-- libtool: Leave libtool (.la) files in packages
#-- staticlibs: Leave static library (.a) files in packages
#-- emptydirs: Leave empty directories in packages
#-- zipman: Compress manual (man and info) pages in MAN_DIRS with gzip
#-- purge: Remove files specified by PURGE_TARGETS
#-- upx: Compress binary executable files using UPX
#-- debug: Add debugging flags as specified in DEBUG_* variables
#
OPTIONS=(strip docs !libtool staticlibs emptydirs zipman purge !upx !debug)
#-- File integrity checks to use. Valid: md5, sha1, sha256, sha384, sha512
INTEGRITY_CHECK=(md5)
#-- Options to be used when stripping binaries. See `man strip' for details.
STRIP_BINARIES="--strip-all"
#-- Options to be used when stripping shared libraries. See `man strip' for details.
STRIP_SHARED="--strip-unneeded"
#-- Options to be used when stripping static libraries. See `man strip' for details.
STRIP_STATIC="--strip-debug"
#-- Manual (man and info) directories to compress (if zipman is specified)
MAN_DIRS=(clang32{{,/local}{,/share},/opt/*}/{man,info})
#-- Doc directories to remove (if !docs is specified)
DOC_DIRS=(clang32/{,local/}{,share/}{doc,gtk-doc})
#-- Files to be removed from all packages (if purge is specified)
PURGE_TARGETS=(clang32/{,share}/info/dir .packlist *.pod)
#########################################################################
# PACKAGE OUTPUT
#########################################################################
#
# Default: put built package and cached source in build directory
#
#-- Destination: specify a fixed directory where all packages will be placed
#PKGDEST=/var/packages-clang32
#-- Source cache: specify a fixed directory where source files will be cached
#SRCDEST=/var/sources
#-- Source packages: specify a fixed directory where all src packages will be placed
#SRCPKGDEST=/var/srcpackages-clang32
#-- Log files: specify a fixed directory where all log files will be placed
#LOGDEST=/var/makepkglogs
#-- Packager: name/email of the person or organization building packages
#PACKAGER="John Doe <john@doe.com>"
#-- Specify a key to use for package signing
#GPGKEY=""
#########################################################################
# COMPRESSION DEFAULTS
#########################################################################
#
COMPRESSGZ=(gzip -c -f -n)
COMPRESSBZ2=(bzip2 -c -f)
COMPRESSXZ=(xz -c -z -T0 -)
COMPRESSLRZ=(lrzip -q)
COMPRESSLZO=(lzop -q)
COMPRESSZ=(compress -c -f)
#########################################################################
# EXTENSION DEFAULTS
#########################################################################
#
# WARNING: Do NOT modify these variables unless you know what you are
# doing.
#
PKGEXT='.pkg.tar.xz'
SRCEXT='.src.tar.gz'
# vim: set ft=sh ts=2 sw=2 et:

@ -0,0 +1,171 @@
#
# /etc/makepkg_mingw64.conf
#
#########################################################################
# SOURCE ACQUISITION
#########################################################################
#
#-- The download utilities that makepkg should use to acquire sources
# Format: 'protocol::agent'
DLAGENTS=('ftp::/usr/bin/curl -fC - --ftp-pasv --retry 3 --retry-delay 3 -o %o %u'
'http::/usr/bin/curl -qb "" -fLC - --retry 3 --retry-delay 3 -o %o %u'
'https::/usr/bin/curl -qb "" -fLC - --retry 3 --retry-delay 3 -o %o %u'
'rsync::/usr/bin/rsync --no-motd -z %u %o'
'scp::/usr/bin/scp -C %u %o')
# Other common tools:
# /usr/bin/snarf
# /usr/bin/lftpget -c
# /usr/bin/wget
#-- The package required by makepkg to download VCS sources
# Format: 'protocol::package'
VCSCLIENTS=('bzr::bzr'
'git::git'
'hg::mercurial'
'svn::subversion')
#-- Using git am to apply patches has benefits, but also downsides
# one being that people without their .gitconfig set get prompts
# and the other being that the sha1s vary each time, so fix them
GIT_COMMITTER_NAME="makepkg"
GIT_COMMITTER_EMAIL="makepkg@msys2.org"
function gitam_mkpkg() {
git am --committer-date-is-author-date "$@"
}
#########################################################################
# ARCHITECTURE, COMPILE FLAGS
#########################################################################
#
CARCH="x86_64"
CHOST="x86_64-w64-mingw32"
#########################################################################
# Mingw toolchains stuff
#########################################################################
#
MINGW_CHOST="x86_64-w64-mingw32"
MINGW_PREFIX="/clang64"
MINGW_PACKAGE_PREFIX="clang-mingw-w64-x86_64"
# DirectX compatibility environment variable
DXSDK_DIR=${MINGW_PREFIX}/${MINGW_CHOST}
#-- Compiler and Linker Flags
# -march (or -mcpu) builds exclusively for an architecture
# -mtune optimizes for an architecture, but builds for whole processor family
CPPFLAGS="-D_FORTIFY_SOURCE=2 -D__USE_MINGW_ANSI_STDIO=1"
CFLAGS="-march=x86-64 -mtune=generic -O2 -pipe"
CXXFLAGS="-march=x86-64 -mtune=generic -O2 -pipe"
LDFLAGS="-pipe"
# Uncomment to enable hardening (ASLR, High entropy ASLR, DEP)
#LDFLAGS="-pipe -Wl,--dynamicbase,--high-entropy-va,--nxcompat"
#-- Make Flags: change this for DistCC/SMP systems
MAKEFLAGS="-j$(($(nproc)+1))"
#-- Debugging flags
DEBUG_CFLAGS="-ggdb -Og"
DEBUG_CXXFLAGS="-ggdb -Og"
ACLOCAL_PATH="${MINGW_PREFIX}/share/aclocal:/usr/share/aclocal"
PKG_CONFIG_PATH="${MINGW_PREFIX}/lib/pkgconfig:${MINGW_PREFIX}/share/pkgconfig"
#########################################################################
# BUILD ENVIRONMENT
#########################################################################
#
# Defaults: BUILDENV=(fakeroot !distcc color !ccache check !sign)
# A negated environment option will do the opposite of the comments below.
#
#-- distcc: Use the Distributed C/C++/ObjC compiler
#-- color: Colorize output messages
#-- ccache: Use ccache to cache compilation
#-- check: Run the check() function if present in the PKGBUILD
#-- sign: Generate PGP signature file
#
BUILDENV=(!distcc color !ccache check !sign)
#
#-- If using DistCC, your MAKEFLAGS will also need modification. In addition,
#-- specify a space-delimited list of hosts running in the DistCC cluster.
#DISTCC_HOSTS=""
#
#-- Specify a directory for package building.
#BUILDDIR=/tmp/makepkg
#########################################################################
# GLOBAL PACKAGE OPTIONS
# These are default values for the options=() settings
#########################################################################
#
# Default: OPTIONS=(strip docs !libtool staticlibs emptydirs zipman purge !upx !debug)
# A negated option will do the opposite of the comments below.
#
#-- strip: Strip symbols from binaries/libraries
#-- docs: Save doc directories specified by DOC_DIRS
#-- libtool: Leave libtool (.la) files in packages
#-- staticlibs: Leave static library (.a) files in packages
#-- emptydirs: Leave empty directories in packages
#-- zipman: Compress manual (man and info) pages in MAN_DIRS with gzip
#-- purge: Remove files specified by PURGE_TARGETS
#-- upx: Compress binary executable files using UPX
#-- debug: Add debugging flags as specified in DEBUG_* variables
#
OPTIONS=(strip docs !libtool staticlibs emptydirs zipman purge !upx !debug)
#-- File integrity checks to use. Valid: md5, sha1, sha256, sha384, sha512
INTEGRITY_CHECK=(md5)
#-- Options to be used when stripping binaries. See `man strip' for details.
STRIP_BINARIES="--strip-all"
#-- Options to be used when stripping shared libraries. See `man strip' for details.
STRIP_SHARED="--strip-unneeded"
#-- Options to be used when stripping static libraries. See `man strip' for details.
STRIP_STATIC="--strip-debug"
#-- Manual (man and info) directories to compress (if zipman is specified)
MAN_DIRS=(clang64{{,/local}{,/share},/opt/*}/{man,info})
#-- Doc directories to remove (if !docs is specified)
DOC_DIRS=(clang64/{,local/}{,share/}{doc,gtk-doc})
#-- Files to be removed from all packages (if purge is specified)
PURGE_TARGETS=(clang64/{,share}/info/dir .packlist *.pod)
#########################################################################
# PACKAGE OUTPUT
#########################################################################
#
# Default: put built package and cached source in build directory
#
#-- Destination: specify a fixed directory where all packages will be placed
#PKGDEST=/var/packages-clang64
#-- Source cache: specify a fixed directory where source files will be cached
#SRCDEST=/var/sources
#-- Source packages: specify a fixed directory where all src packages will be placed
#SRCPKGDEST=/var/srcpackages-clang64
#-- Log files: specify a fixed directory where all log files will be placed
#LOGDEST=/var/makepkglogs
#-- Packager: name/email of the person or organization building packages
#PACKAGER="John Doe <john@doe.com>"
#-- Specify a key to use for package signing
#GPGKEY=""
#########################################################################
# COMPRESSION DEFAULTS
#########################################################################
#
COMPRESSGZ=(gzip -c -f -n)
COMPRESSBZ2=(bzip2 -c -f)
COMPRESSXZ=(xz -c -z -T0 -)
COMPRESSLRZ=(lrzip -q)
COMPRESSLZO=(lzop -q)
COMPRESSZ=(compress -c -f)
#########################################################################
# EXTENSION DEFAULTS
#########################################################################
#
# WARNING: Do NOT modify these variables unless you know what you are
# doing.
#
PKGEXT='.pkg.tar.xz'
SRCEXT='.src.tar.gz'
# vim: set ft=sh ts=2 sw=2 et:

@ -4,6 +4,7 @@
## Primary
## msys2.org
Server = http://repo.msys2.org/mingw/i686
Server = https://downloads.sourceforge.net/project/msys2/REPOS/MINGW/i686
Server = http://www2.futureware.at/~nickoe/msys2-mirror/mingw/i686
Server = http://repo.msys2.org/mingw/i686/
Server = https://sourceforge.net/projects/msys2/files/REPOS/MINGW/i686/
Server = http://www2.futureware.at/~nickoe/msys2-mirror/mingw/i686/
Server = https://mirror.yandex.ru/mirrors/msys2/mingw/i686/

@ -4,6 +4,7 @@
## Primary
## msys2.org
Server = http://repo.msys2.org/mingw/x86_64
Server = https://downloads.sourceforge.net/project/msys2/REPOS/MINGW/x86_64
Server = http://www2.futureware.at/~nickoe/msys2-mirror/mingw/x86_64
Server = http://repo.msys2.org/mingw/x86_64/
Server = https://sourceforge.net/projects/msys2/files/REPOS/MINGW/x86_64/
Server = http://www2.futureware.at/~nickoe/msys2-mirror/mingw/x86_64/
Server = https://mirror.yandex.ru/mirrors/msys2/mingw/x86_64/

@ -4,6 +4,7 @@
## Primary
## msys2.org
Server = http://repo.msys2.org/msys/$arch
Server = https://downloads.sourceforge.net/project/msys2/REPOS/MSYS2/$arch
Server = http://repo.msys2.org/msys/$arch/
Server = https://sourceforge.net/projects/msys2/files/REPOS/MSYS2/$arch/
Server = http://www2.futureware.at/~nickoe/msys2-mirror/msys/$arch/
Server = https://mirror.yandex.ru/mirrors/msys2/msys/$arch/

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

@ -253,6 +253,7 @@ maybe_create_home ()
#
# Make sure we start in home if invoked without -here option and not in a nested shell
if [ ! -z "${CHERE_INVOKING}" ]; then
CHERE_INVOKING_VISIBLE_FOR_USER=CHERE_INVOKING
unset CHERE_INVOKING
elif [ ${SHLVL:-0} -le 1 ]; then
cd "${HOME}" || echo "WARNING: Failed attempt to cd into ${HOME}!"

@ -2,7 +2,6 @@ check_install () {
pacman -Q $1 > /dev/null
if [ $? == 1 ]; then
pacman --noconfirm --force -S $1
pacman --noconfirm --force -Scc
fi
}
@ -10,16 +9,17 @@ check_install_web () {
pacman -Q $1 | grep $2 > /dev/null
if [ $? == 1 ]; then
pacman --noconfirm --force -U $3
pacman --noconfirm --force -Scc
fi
}
clean_qt5_86 () {
clean_86 () {
rm -rf /mingw32/share/qt5/examples
pacman --noconfirm --force -Scc
}
clean_qt5_64 () {
clean_64 () {
rm -rf /mingw64/share/qt5/examples
pacman --noconfirm --force -Scc
}
@ -27,25 +27,30 @@ clean_qt5_64 () {
setup_proxspace ()
{
if [ "$MSYSTEM" == "MINGW64" ]; then
check_install_web mingw-w64-x86_64-gcc-libs 8.2.0-3 http://repo.msys2.org/mingw/x86_64/mingw-w64-x86_64-gcc-libs-8.2.0-3-any.pkg.tar.xz
check_install_web mingw-w64-x86_64-gcc 8.2.0-3 http://repo.msys2.org/mingw/x86_64/mingw-w64-x86_64-gcc-8.2.0-3-any.pkg.tar.xz
check_install_web mingw-w64-x86_64-readline 6.3 http://repo.msys2.org/mingw/x86_64/mingw-w64-x86_64-readline-6.3.008-1-any.pkg.tar.xz
check_install mingw-w64-x86_64-gcc
check_install mingw-w64-x86_64-readline
check_install git
check_install make
check_install pkg-config
check_install mingw-w64-x86_64-qt5
clean_qt5_64
clean_64
fi
if [ "$MSYSTEM" == "MINGW32" ]; then
check_install_web mingw-w64-i686-readline 6.3 http://repo.msys2.org/mingw/i686/mingw-w64-i686-readline-6.3.008-1-any.pkg.tar.xz
check_install mingw-w64-i686-readline
check_install mingw-w64-i686-gcc
check_install git
check_install make
check_install pkg-config
check_install mingw-w64-i686-qt5
clean_qt5_86
clean_86
fi
}
setup_proxspace
export LANG=en_US.UTF-8
if [ "$MAYBE_FIRST_START" = "false" ]; then
yes | pacman -Syuu
setup_proxspace
fi

@ -10,7 +10,7 @@
## Or online here:
## https://www.gnu.org/software/wget/manual/wget.html#Startup-File
##
## Wget initialization file can reside in /etc/wgetrc
## Wget initialization file can reside in /usr/local/etc/wgetrc
## (global, for all users) or $HOME/.wgetrc (for a single user).
##
## To use the settings in this file, you will have to uncomment them,
@ -22,7 +22,7 @@
##
## Global settings (useful for setting up in /etc/wgetrc).
## Global settings (useful for setting up in /usr/local/etc/wgetrc).
## Think well before you change them, since they may reduce wget's
## functionality, and make it behave contrary to the documentation:
##

@ -10,12 +10,12 @@ test -n "${BASH_SOURCE}" 2>/dev/null && config_site_me="${BASH_SOURCE[0]##*/}" |
# Set default 'host' to speedup configure
if test -z "$build_alias"; then
build_alias="${MSYSTEM_CHOST-i686-w64-mingw32}" && \
$as_echo "$config_site_me:${as_lineno-$LINENO}: default build_alias set to $build_alias" >&5
${as_echo-echo} "$config_site_me:${as_lineno-$LINENO}: default build_alias set to $build_alias" >&5
fi
# Set default 'prefix' to "/mingw32"
if ( test -z "$prefix" || test "x$prefix" = "xNONE" ) && \
( test -z "$exec_prefix" || test "x$exec_prefix" = "xNONE" ); then
prefix="${MSYSTEM_PREFIX-/mingw32}" && \
$as_echo "$config_site_me:${as_lineno-$LINENO}: default prefix set to $prefix" >&5
${as_echo-echo} "$config_site_me:${as_lineno-$LINENO}: default prefix set to $prefix" >&5
fi

@ -10,12 +10,12 @@ test -n "${BASH_SOURCE}" 2>/dev/null && config_site_me="${BASH_SOURCE[0]##*/}" |
# Set default 'host' to speedup configure
if test -z "$build_alias"; then
build_alias="${MSYSTEM_CHOST-x86_64-w64-mingw32}" && \
$as_echo "$config_site_me:${as_lineno-$LINENO}: default build_alias set to $build_alias" >&5
${as_echo-echo} "$config_site_me:${as_lineno-$LINENO}: default build_alias set to $build_alias" >&5
fi
# Set default 'prefix' to "/mingw64"
if ( test -z "$prefix" || test "x$prefix" = "xNONE" ) && \
( test -z "$exec_prefix" || test "x$exec_prefix" = "xNONE" ); then
prefix="${MSYSTEM_PREFIX-/mingw64}" && \
$as_echo "$config_site_me:${as_lineno-$LINENO}: default prefix set to $prefix" >&5
${as_echo-echo} "$config_site_me:${as_lineno-$LINENO}: default prefix set to $prefix" >&5
fi

@ -14,9 +14,8 @@ rem set MSYS=error_start:%WD%../../mingw64/bin/qtcreator.exe^|-debug^|^<process-
rem To export full current PATH from environment into MSYS2 use '-use-full-path' parameter
rem or uncomment next line
rem set MSYS2_PATH_TYPE=inherit
SET PATH=%WD%;%PATH%
%~dp0\usr\bin\dash /usr/bin/rebaseall -p 2> nul
rem /tmp is required for bash to work
mkdir %WD%..\..\tmp 2> nul
del %WD%..\..\etc\passwd 2> nul
@ -77,6 +76,11 @@ if "x%~1" == "x-shell" (
set LOGINSHELL="%~2"
)& shift& shift& goto :checkparams
rem Collect remaining command line arguments to be passed to shell
set SHELL_ARGS=
:collectparams
if not "x%~1" == "x" set SHELL_ARGS=%SHELL_ARGS% %1& shift& goto :collectparams
rem Setup proper title
if "%MSYSTEM%" == "MINGW32" (
set "CONTITLE=MinGW x32"
@ -94,9 +98,9 @@ if NOT EXIST "%WD%mintty.exe" goto startsh
set MSYSCON=mintty.exe
:startmintty
if not defined MSYS2_NOSTART (
start "%CONTITLE%" "%WD%mintty" -i /msys2.ico -t "%CONTITLE%" "/usr/bin/%LOGINSHELL%" --login %1 %2 %3 %4 %5 %6 %7 %8 %9
start "%CONTITLE%" "%WD%mintty" -i /msys2.ico -t "%CONTITLE%" "/usr/bin/%LOGINSHELL%" --login %SHELL_ARGS%
) else (
"%WD%mintty" -i /msys2.ico -t "%CONTITLE%" "/usr/bin/%LOGINSHELL%" --login %1 %2 %3 %4 %5 %6 %7 %8 %9
"%WD%mintty" -i /msys2.ico -t "%CONTITLE%" "/usr/bin/%LOGINSHELL%" --login %SHELL_ARGS%
)
exit /b %ERRORLEVEL%
@ -106,18 +110,18 @@ call :conemudetect || (
exit /b 1
)
if not defined MSYS2_NOSTART (
start "%CONTITLE%" "%ComEmuCommand%" /Here /Icon "%WD%..\..\msys2.ico" /cmd "%WD%\%LOGINSHELL%" --login %1 %2 %3 %4 %5 %6 %7 %8 %9
start "%CONTITLE%" "%ComEmuCommand%" /Here /Icon "%WD%..\..\msys2.ico" /cmd "%WD%\%LOGINSHELL%" --login %SHELL_ARGS%
) else (
"%ComEmuCommand%" /Here /Icon "%WD%..\..\msys2.ico" /cmd "%WD%\%LOGINSHELL%" --login %1 %2 %3 %4 %5 %6 %7 %8 %9
"%ComEmuCommand%" /Here /Icon "%WD%..\..\msys2.ico" /cmd "%WD%\%LOGINSHELL%" --login %SHELL_ARGS%
)
exit /b %ERRORLEVEL%
:startsh
set MSYSCON=
if not defined MSYS2_NOSTART (
start "%CONTITLE%" "%WD%\%LOGINSHELL%" --login %1 %2 %3 %4 %5 %6 %7 %8 %9
start "%CONTITLE%" "%WD%\%LOGINSHELL%" --login %SHELL_ARGS%
) else (
"%WD%\%LOGINSHELL%" --login %1 %2 %3 %4 %5 %6 %7 %8 %9
"%WD%\%LOGINSHELL%" --login %SHELL_ARGS%
)
exit /b %ERRORLEVEL%

Binary file not shown.

122
msys2/usr/bin/addgnupghome Normal file

@ -0,0 +1,122 @@
#!/bin/sh
# Add a new .gnupg home directory for a list of users -*- sh -*-
#
# Copyright 2004 Free Software Foundation, Inc.
#
# This file is free software; as a special exception the author gives
# unlimited permission to copy and/or distribute it, with or without
# modifications, as long as this notice is preserved.
#
# This file is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
PGM=addgnupghome
any_error=0
error () {
echo "$PGM: $*" >&2
any_error=1
}
info () {
echo "$PGM: $*" >&2
}
# Do it for one user
one_user () {
user="$1"
home=$(${cat_passwd} | awk -F: -v n="$user" '$1 == n {print $6}')
if [ -z "$home" ]; then
if ${cat_passwd} | awk -F: -v n="$user" '$1 == n {exit 1}'; then
error "no such user \`$user'"
else
error "no home directory for user \`$user'"
fi
return
fi
if [ ! -d "$home" ]; then
error "home directory \`$home' of user \`$user' does not exist"
return
fi
if [ -d "$home/.gnupg" ]; then
info "skipping user \`$user': \`.gnupg' already exists"
return
fi
info "creating home directory \`$home/.gnupg' for \`$user'"
if ! mkdir "$home/.gnupg" ; then
error "error creating \`$home/.gnupg'"
return
fi
if ! chown $user "$home/.gnupg" ; then
error "error changing ownership of \`$home/.gnupg'"
return
fi
group=$(id -g "$user")
[ -z "$group" ] && group="0"
if [ "$group" -gt 0 ]; then
if ! chgrp $group "$home/.gnupg" ; then
error "error changing group of \`$home/.gnupg'"
return
fi
fi
if ! cd "$home/.gnupg" ; then
error "error cd-ing to \`$home/.gnupg'"
return
fi
for f in $filelist; do
if [ -d /etc/skel/.gnupg/$f ]; then
mkdir $f
else
cp /etc/skel/.gnupg/$f $f
fi
if ! chown $user $f ; then
error "error changing ownership of \`$f'"
return
fi
if [ "$group" -gt 0 ]; then
if ! chgrp $group "$f" ; then
error "error changing group of \`$f'"
return
fi
fi
done
}
if [ -z "$1" ]; then
echo "usage: $PGM userids"
exit 1
fi
# Check whether we can use getent
if getent --help </dev/null >/dev/null 2>&1 ; then
cat_passwd='getent passwd'
else
cat_passwd='cat /etc/passwd'
info "please note that only users from /etc/passwd are checked"
fi
if [ ! -d /etc/skel/.gnupg ]; then
error "skeleton directory \`/etc/skel/.gnupg' does not exist"
exit 1
fi
cd "/etc/skel/.gnupg" || (error "error cd-ing to \`/etc/skel/.gnupg'"; exit 1)
filelist=$(find . \( -type f -o -type d \) '!' -name '*~' '!' -name . -print)
if ! umask 0077 ; then
error "error setting umask"
exit 1
fi
for name in $*; do
one_user $name
done
exit $any_error

Binary file not shown.

@ -0,0 +1,81 @@
#!/bin/sh
# Apply defaults from /etc/gnupg/gpgconf.conf to all users -*- sh -*-
#
# Copyright 2007 Free Software Foundation, Inc.
#
# This file is free software; as a special exception the author gives
# unlimited permission to copy and/or distribute it, with or without
# modifications, as long as this notice is preserved.
#
# This file is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
PGM=applygnupgdefaults
errorfile=
error () {
echo "$PGM: $*" >&2
[ -n "$errorfile" ] && echo "$PGM: $*" >>$errorfile
}
info () {
echo "$PGM: $*" >&2
}
if [ -n "$1" ]; then
echo "usage: $PGM" >&2
exit 1
fi
# Cleanup on exit
cleanup ()
{
[ -n "$errorfile" -a -f "$errorfile" ] && rm "$errorfile"
}
trap cleanup EXIT SIGINT SIGHUP SIGPIPE
errorfile=$(mktemp "/tmp/$PGM.log.XXXXXX")
[ -n "$errorfile" -a -f "$errorfile" ] || exit 2
# Check whether we can use getent
if getent --help </dev/null >/dev/null 2>&1 ; then
cat_passwd='getent passwd'
else
cat_passwd='cat /etc/passwd'
info "please note that only users from /etc/passwd are processed"
fi
if [ ! -f /etc/gnupg/gpgconf.conf ]; then
error "global configuration file \`/etc/gnupg/gpgconf.conf' does not exist"
exit 1
fi
if [ ! -f /etc/shells ]; then
error "missing file \`/etc/shells'"
exit 1
fi
if [ $(id -u) -ne 0 ]; then
error "needs to be run as root"
exit 1
fi
${cat_passwd} \
| while IFS=: read -r user dmy_a uid dmy_c dmy_d home shell dmy_rest; do
# Process only entries with a valid login shell
grep </etc/shells "^$shell" 2>/dev/null >/dev/null || continue
# and with an pre-existing gnupg home directory
[ -d "$home/.gnupg" ] || continue
# but not root
[ "${uid:-0}" -eq 0 ] && continue
info "running \"gpgconf --apply-defaults\" for $user"
if su -l -s /bin/sh \
-c 'gpgconf --apply-defaults && echo SUCCESS' $user \
| tail -1 | grep ^SUCCESS >/dev/null ; then
:
else
error "failed to update gnupg defaults for $user"
fi
done
[ "$(wc -c <$errorfile)" -gt 0 ] && exit 1
exit 0

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -1,393 +0,0 @@
#!/usr/bin/bash
#
# bacman: recreate a package from a running system
# This script rebuilds an already installed package using metadata
# stored into the pacman database and system files
#
# Copyright (c) 2008 locci <carlocci_at_gmail_dot_com>
# Copyright (c) 2008-2016 Pacman Development Team <pacman-dev@archlinux.org>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
shopt -s extglob
shopt -s nullglob
declare -r myname='bacman'
declare -r myver='5.0.1'
USE_COLOR='y'
INCLUDE_PACNEW='n'
# Required for fakeroot because options are shifted off the array.
ARGS=("$@")
plain() {
(( QUIET )) && return
local mesg=$1; shift
printf "${BOLD} ${mesg}${ALL_OFF}\n" "$@" >&1
}
msg() {
(( QUIET )) && return
local mesg=$1; shift
printf "${GREEN}==>${ALL_OFF}${BOLD} ${mesg}${ALL_OFF}\n" "$@" >&1
}
msg2() {
(( QUIET )) && return
local mesg=$1; shift
printf "${BLUE} ->${ALL_OFF}${BOLD} ${mesg}${ALL_OFF}\n" "$@" >&1
}
ask() {
local mesg=$1; shift
printf "${BLUE}::${ALL_OFF}${BOLD} ${mesg}${ALL_OFF}" "$@" >&1
}
warning() {
local mesg=$1; shift
printf "${YELLOW}==> $(gettext "WARNING:")${ALL_OFF}${BOLD} ${mesg}${ALL_OFF}\n" "$@" >&2
}
error() {
local mesg=$1; shift
printf "${RED}==> $(gettext "ERROR:")${ALL_OFF}${BOLD} ${mesg}${ALL_OFF}\n" "$@" >&2
}
#
# User Friendliness
#
usage() {
echo "${myname} (pacman) v${myver}"
echo
echo "Recreate a package using pacman's database and system files"
echo
echo "Usage: ${myname} [--nocolor] [--pacnew] <installed package name>"
echo
echo "Example: ${myname} linux-headers"
}
version() {
printf "%s %s\n" "$myname" "$myver"
echo 'Copyright (C) 2008 locci <carlocci_at_gmail_dot_com>'
echo 'Copyright (C) 2008-2016 Pacman Development Team <pacman-dev@archlinux.org>'
}
while [[ ! -z $1 ]]; do
if [[ $1 == "--nocolor" ]]; then
USE_COLOR='n'
shift
elif [[ $1 == "--pacnew" ]]; then
INCLUDE_PACNEW='y'
shift
else
break
fi
done
# check if messages are to be printed using color
unset ALL_OFF BOLD BLUE GREEN RED YELLOW
if [[ -t 2 && ! $USE_COLOR = "n" ]]; then
# prefer terminal safe colored and bold text when tput is supported
if tput setaf 0 &>/dev/null; then
ALL_OFF="$(tput sgr0)"
BOLD="$(tput bold)"
BLUE="${BOLD}$(tput setaf 4)"
GREEN="${BOLD}$(tput setaf 2)"
RED="${BOLD}$(tput setaf 1)"
YELLOW="${BOLD}$(tput setaf 3)"
else
ALL_OFF="\e[1;0m"
BOLD="\e[1;1m"
BLUE="${BOLD}\e[1;34m"
GREEN="${BOLD}\e[1;32m"
RED="${BOLD}\e[1;31m"
YELLOW="${BOLD}\e[1;33m"
fi
fi
readonly ALL_OFF BOLD BLUE GREEN RED YELLOW
if (( $# != 1 )); then
usage
exit 1
fi
if [[ $1 = -@(h|-help) ]]; then
usage
exit 0
elif [[ $1 = -@(V|-version) ]]; then
version
exit 0
fi
#
# Setting environmental variables
#
if [[ ! -r /etc/pacman.conf ]]; then
error "unable to read /etc/pacman.conf"
exit 1
fi
eval $(awk '/DBPath/ {print $1$2$3}' /etc/pacman.conf)
pac_db="${DBPath:-/var/lib/pacman/}/local"
if [[ ! -r /etc/makepkg.conf ]]; then
error "unable to read /etc/makepkg.conf"
exit 1
fi
source "/etc/makepkg.conf"
if [[ -r ~/.makepkg.conf ]]; then
source ~/.makepkg.conf
fi
pkg_dest="${PKGDEST:-$PWD}"
pkg_pkger=${PACKAGER:-'Unknown Packager'}
pkg_name="$1"
pkg_dir=("$pac_db/$pkg_name"-+([^-])-+([^-]))
pkg_namver=("${pkg_dir[@]##*/}")
#
# Checks everything is in place
#
if [[ ! -d $pac_db ]]; then
error "pacman database directory ${pac_db} not found"
exit 1
fi
if (( ${#pkg_dir[@]} != 1 )); then
error "%d entries for package %s found in pacman database" \
${#pkg_dir[@]} "${pkg_name}"
msg2 "%s" "${pkg_dir[@]}"
exit 1
fi
if [[ ! -d $pkg_dir ]]; then
error "package %s is found in pacman database," "${pkg_name}"
plain " but '%s' is not a directory" "${pkg_dir}"
exit 1
fi
#
# Begin
#
msg "Package: ${pkg_namver}"
work_dir=$(mktemp -d "${TMPDIR:-/tmp}/bacman.XXXXXXXXXX")
cd "$work_dir" || exit 1
#
# File copying
#
msg2 "Copying package files..."
while read i; do
if [[ -z $i ]]; then
continue
fi
if [[ $i == %+([A-Z])% ]]; then
current=$i
continue
fi
case "$current" in
%FILES%)
local_file="/$i"
package_file="$work_dir/$i"
if [[ ! -e $local_file ]]; then
warning "package file $local_file is missing"
continue
fi
;;
%BACKUP%)
# Get the MD5 checksum.
original_md5="${i##*$'\t'}"
# Strip the md5sum after the tab.
i="${i%$'\t'*}"
local_file="/$i.pacnew"
package_file="$work_dir/$i"
# Include unmodified .pacnew files.
local_md5="$(md5sum "$local_file" | cut -d' ' -f1)"
if [[ $INCLUDE_PACNEW == 'n' ]] \
|| [[ ! -e $local_file ]] \
|| [[ $local_md5 != $original_md5 ]]; then
# Warn about modified files.
local_md5="$(md5sum "/$i" | cut -d' ' -f1)"
if [[ $local_md5 != $original_md5 ]]; then
warning "package file /$i has been modified"
fi
# Let the normal file be included in the %FILES% list.
continue
fi
;;
*)
continue
;;
esac
ret=0
/usr/bin/bsdtar -cnf - -s'/.pacnew$//' "$local_file" 2> /dev/null | /bin/bsdtar -xpf - 2> /dev/null
# Workaround to bsdtar not reporting a missing file as an error
if ! [[ -e $package_file || -L $package_file ]]; then
error "unable to add $local_file to the package"
plain " If your user does not have permission to read this file, then"
plain " you will need to run $myname as root."
rm -rf "$work_dir"
exit 1
fi
done < "$pkg_dir"/files
ret=$?
if (( ret )); then
rm -rf "$work_dir"
exit 1
fi
pkg_size=$(du -sk | awk '{print $1 * 1024}')
#
# .PKGINFO stuff
# TODO adopt makepkg's write_pkginfo() into this or scripts/library
#
msg2 "Generating .PKGINFO metadata..."
echo "# Generated by $myname $myver" > .PKGINFO
echo "# $(LC_ALL=C date)" >> .PKGINFO
echo "#" >> .PKGINFO
while read i; do
if [[ -z $i ]]; then
continue;
fi
if [[ $i == %+([A-Z])% ]]; then
current=$i
continue
fi
case "$current" in
# desc
%NAME%)
echo "pkgname = $i" >> .PKGINFO
;;
%VERSION%)
echo "pkgver = $i" >> .PKGINFO
;;
%DESC%)
echo "pkgdesc = $i" >> .PKGINFO
;;
%URL%)
echo "url = $i" >> .PKGINFO
;;
%LICENSE%)
echo "license = $i" >> .PKGINFO
;;
%ARCH%)
echo "arch = $i" >> .PKGINFO
pkg_arch="$i"
;;
%BUILDDATE%)
echo "builddate = $(date -u "+%s")" >> .PKGINFO
;;
%PACKAGER%)
echo "packager = $pkg_pkger" >> .PKGINFO
;;
%SIZE%)
echo "size = $pkg_size" >> .PKGINFO
;;
%GROUPS%)
echo "group = $i" >> .PKGINFO
;;
%REPLACES%)
echo "replaces = $i" >> .PKGINFO
;;
%DEPENDS%)
echo "depend = $i" >> .PKGINFO
;;
%OPTDEPENDS%)
echo "optdepend = $i" >> .PKGINFO
;;
%CONFLICTS%)
echo "conflict = $i" >> .PKGINFO
;;
%PROVIDES%)
echo "provides = $i" >> .PKGINFO
;;
# files
%BACKUP%)
# Strip the md5sum after the tab
echo "backup = ${i%%$'\t'*}" >> .PKGINFO
;;
esac
done < <(cat "$pkg_dir"/{desc,files})
comp_files=".PKGINFO"
if [[ -f $pkg_dir/install ]]; then
cp "$pkg_dir/install" "$work_dir/.INSTALL"
comp_files+=" .INSTALL"
fi
if [[ -f $pkg_dir/changelog ]]; then
cp "$pkg_dir/changelog" "$work_dir/.CHANGELOG"
comp_files+=" .CHANGELOG"
fi
#
# Fixes owner:group and permissions for .PKGINFO, .CHANGELOG, .INSTALL
#
chown root:root "$work_dir"/{.PKGINFO,.CHANGELOG,.INSTALL} 2> /dev/null
chmod 644 "$work_dir"/{.PKGINFO,.CHANGELOG,.INSTALL} 2> /dev/null
#
# Generate the package
#
msg2 "Generating the package..."
pkg_file="$pkg_dest/$pkg_namver-$pkg_arch${PKGEXT}"
ret=0
# TODO: Maybe this can be set globally for robustness
shopt -s -o pipefail
/usr/bin/bsdtar -cf - $comp_files * |
case "$PKGEXT" in
*tar.gz) /bin/gzip -c -f -n ;;
*tar.bz2) /bin/bzip2 -c -f ;;
*tar.xz) /bin/xz -c -z - ;;
*tar.Z) compress -c -f ;;
*tar) cat ;;
*) warning "'%s' is not a valid archive extension." \
"$PKGEXT"; cat ;;
esac > "${pkg_file}"; ret=$?
if (( ret )); then
error "Unable to write package to $pkg_dest"
plain " Maybe the disk is full or you do not have write access"
rm -rf "$work_dir"
exit 1
fi
rm -rf "$work_dir"
msg "Done."
exit 0
# vim: set noet:

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
msys2/usr/bin/basenc.exe Normal file

Binary file not shown.

Binary file not shown.

@ -31,7 +31,7 @@ OS="msys"
CC="gcc"
CFLAGS=" -DPROGRAM='bash.exe' -DCONF_HOSTTYPE='i686' -DCONF_OSTYPE='msys' -DCONF_MACHTYPE='i686-pc-msys' -DCONF_VENDOR='pc' -DLOCALEDIR='/usr/share/locale' -DPACKAGE='bash' -DSHELL -DHAVE_CONFIG_H -DRECYCLES_PIDS -I. -I. -I./include -I./lib -DWORDEXP_OPTION -march=i686 -mtune=generic -O2 -pipe -Wno-parentheses -Wno-format-security -D_STATIC_BUILD"
RELEASE="4.4"
PATCHLEVEL="19"
PATCHLEVEL="23"
RELSTATUS="release"
MACHTYPE="i686-pc-msys"

Binary file not shown.

BIN
msys2/usr/bin/brotli.exe Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -1,4 +1,13 @@
#!/usr/bin/perl.exe
#!/usr/bin/env perl
# WARNING: do not edit!
# Generated by Makefile from tools/c_rehash.in
# Copyright 1999-2018 The OpenSSL Project Authors. All Rights Reserved.
#
# Licensed under the OpenSSL license (the "License"). You may not use
# this file except in compliance with the License. You can obtain a copy
# in the file LICENSE in the source distribution or at
# https://www.openssl.org/source/license.html
# Perl c_rehash script, scan all files in a directory
# and add symbolic links to their hash values.
@ -6,12 +15,14 @@
my $dir = "/usr/ssl";
my $prefix = "/usr";
my $errorcount = 0;
my $openssl = $ENV{OPENSSL} || "openssl";
my $pwd;
my $x509hash = "-subject_hash";
my $crlhash = "-hash";
my $verbose = 0;
my $symlink_exists=eval {symlink("",""); 1};
if ($^O eq "msys") { $symlink_exists=0 };
my $removelinks = 1;
## Parse flags.
@ -21,7 +32,7 @@ while ( $ARGV[0] =~ /^-/ ) {
if ( $flag eq '-old') {
$x509hash = "-subject_hash_old";
$crlhash = "-hash_old";
} elsif ( $flag eq '-h') {
} elsif ( $flag eq '-h' || $flag eq '-help' ) {
help();
} elsif ( $flag eq '-n' ) {
$removelinks = 0;
@ -29,15 +40,15 @@ while ( $ARGV[0] =~ /^-/ ) {
$verbose++;
}
else {
print STDERR "Usage error; try -help.\n";
print STDERR "Usage error; try -h.\n";
exit 1;
}
}
sub help {
print "Usage: c_rehash [-old] [-h] [-v] [dirs...]\n";
print "Usage: c_rehash [-old] [-h] [-help] [-v] [dirs...]\n";
print " -old use old-style digest\n";
print " -h print this help text\n";
print " -h or -help print this help text\n";
print " -v print files removed and linked\n";
exit 0;
}
@ -54,24 +65,24 @@ if (defined(&Cwd::getcwd)) {
my $path_delim = ($pwd =~ /^[a-z]\:/i) ? ';' : ':';
$ENV{PATH} = "$prefix/bin" . ($ENV{PATH} ? $path_delim . $ENV{PATH} : "");
if(! -x $openssl) {
if (! -x $openssl) {
my $found = 0;
foreach (split /$path_delim/, $ENV{PATH}) {
if(-x "$_/$openssl") {
if (-x "$_/$openssl") {
$found = 1;
$openssl = "$_/$openssl";
last;
}
}
if($found == 0) {
if ($found == 0) {
print STDERR "c_rehash: rehashing skipped ('openssl' program not available)\n";
exit 0;
}
}
if(@ARGV) {
if (@ARGV) {
@dirlist = @ARGV;
} elsif($ENV{SSL_CERT_DIR}) {
} elsif ($ENV{SSL_CERT_DIR}) {
@dirlist = split /$path_delim/, $ENV{SSL_CERT_DIR};
} else {
$dirlist[0] = "$dir/certs";
@ -84,36 +95,42 @@ if (-d $dirlist[0]) {
}
foreach (@dirlist) {
if(-d $_ and -w $_) {
if (-d $_ ) {
if ( -w $_) {
hash_dir($_);
} else {
print "Skipping $_, can't write\n";
$errorcount++;
}
}
}
exit($errorcount);
sub hash_dir {
my %hashlist;
print "Doing $_[0]\n";
chdir $_[0];
opendir(DIR, ".");
my @flist = readdir(DIR);
my @flist = sort readdir(DIR);
closedir DIR;
if ( $removelinks ) {
# Delete any existing symbolic links
foreach (grep {/^[\da-f]+\.r{0,1}\d+$/} @flist) {
if(-l $_) {
unlink $_;
if (-l $_) {
print "unlink $_" if $verbose;
unlink $_ || warn "Can't unlink $_, $!\n";
}
}
}
FILE: foreach $fname (grep {/\.(pem)|(crt)|(cer)|(crl)$/} @flist) {
# Check to see if certificates and/or CRLs present.
my ($cert, $crl) = check_file($fname);
if(!$cert && !$crl) {
if (!$cert && !$crl) {
print STDERR "WARNING: $fname does not contain a certificate or CRL: skipping\n";
next;
}
link_hash_cert($fname) if($cert);
link_hash_crl($fname) if($crl);
link_hash_cert($fname) if ($cert);
link_hash_crl($fname) if ($crl);
}
}
@ -122,14 +139,14 @@ sub check_file {
my $fname = $_[0];
open IN, $fname;
while(<IN>) {
if(/^-----BEGIN (.*)-----/) {
if (/^-----BEGIN (.*)-----/) {
my $hdr = $1;
if($hdr =~ /^(X509 |TRUSTED |)CERTIFICATE$/) {
if ($hdr =~ /^(X509 |TRUSTED |)CERTIFICATE$/) {
$is_cert = 1;
last if($is_crl);
} elsif($hdr eq "X509 CRL") {
last if ($is_crl);
} elsif ($hdr eq "X509 CRL") {
$is_crl = 1;
last if($is_cert);
last if ($is_cert);
}
}
}
@ -156,7 +173,7 @@ sub link_hash_cert {
# Search for an unused hash filename
while(exists $hashlist{"$hash.$suffix"}) {
# Hash matches: if fingerprint matches its a duplicate cert
if($hashlist{"$hash.$suffix"} eq $fprint) {
if ($hashlist{"$hash.$suffix"} eq $fprint) {
print STDERR "WARNING: Skipping duplicate certificate $fname\n";
return;
}
@ -164,15 +181,21 @@ sub link_hash_cert {
}
$hash .= ".$suffix";
if ($symlink_exists) {
symlink $fname, $hash;
print "link $fname -> $hash\n" if $verbose;
symlink $fname, $hash || warn "Can't symlink, $!";
} else {
open IN,"<$fname" or die "can't open $fname for read";
open OUT,">$hash" or die "can't open $hash for write";
print OUT <IN>; # does the job for small text files
close OUT;
close IN;
print "copy $fname -> $hash\n" if $verbose;
if (open($in, "<", $fname)) {
if (open($out,">", $hash)) {
print $out $_ while (<$in>);
close $out;
} else {
warn "can't open $hash for write, $!";
}
close $in;
} else {
warn "can't open $fname for read, $!";
}
}
$hashlist{$hash} = $fprint;
}
@ -191,7 +214,7 @@ sub link_hash_crl {
# Search for an unused hash filename
while(exists $hashlist{"$hash.r$suffix"}) {
# Hash matches: if fingerprint matches its a duplicate cert
if($hashlist{"$hash.r$suffix"} eq $fprint) {
if ($hashlist{"$hash.r$suffix"} eq $fprint) {
print STDERR "WARNING: Skipping duplicate CRL $fname\n";
return;
}
@ -199,12 +222,12 @@ sub link_hash_crl {
}
$hash .= ".r$suffix";
if ($symlink_exists) {
symlink $fname, $hash;
print "link $fname -> $hash\n" if $verbose;
symlink $fname, $hash || warn "Can't symlink, $!";
} else {
system ("cp", $fname, $hash);
print "cp $fname -> $hash\n" if $verbose;
system ("cp", $fname, $hash);
warn "Can't copy, $!" if ($? >> 8) != 0;
}
$hashlist{$hash} = $fprint;
}

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
msys2/usr/bin/chattr.exe Normal file

Binary file not shown.

Binary file not shown.

@ -19,7 +19,7 @@
#
declare -r myname='checkupdates'
declare -r myver='5.0.1'
declare -r myver='1.0.0'
plain() {
(( QUIET )) && return
@ -78,7 +78,7 @@ readonly ALL_OFF BOLD BLUE GREEN RED YELLOW
if (( $# > 0 )); then
echo "${myname} (pacman) v${myver}"
echo "${myname} v${myver}"
echo
echo "Safely print a list of pending updates"
echo
@ -94,12 +94,17 @@ fi
trap 'rm -f $CHECKUPDATES_DB/db.lck' INT TERM EXIT
DBPath="${DBPath:-/var/lib/pacman/}"
eval $(awk -F' *= *' '$1 ~ /DBPath/ { print $1 "=" $2 }' /etc/pacman.conf)
DBPath="$(pacman-conf DBPath)"
if [[ -z "$DBPath" ]] || [[ ! -d "$DBPath" ]]; then
DBPath="/var/lib/pacman/"
fi
mkdir -p "$CHECKUPDATES_DB"
ln -s "${DBPath}/local" "$CHECKUPDATES_DB" &> /dev/null
pacman -Sy --dbpath "$CHECKUPDATES_DB" --logfile /dev/null &> /dev/null
if ! pacman -Sy --dbpath "$CHECKUPDATES_DB" --logfile /dev/null &> /dev/null; then
error 'Cannot fetch updates'
exit 1
fi
pacman -Qu --dbpath "$CHECKUPDATES_DB" 2> /dev/null | grep -v '\[.*\]'
exit 0

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
msys2/usr/bin/dirmngr.exe Normal file

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Some files were not shown because too many files have changed in this diff Show More