ipg gzip lvm2 pcre

This commit is contained in:
joborun linux 2023-08-15 14:42:39 +03:00
parent 3e381f3434
commit 96c814f088
10 changed files with 2824 additions and 30 deletions

View File

@ -7,12 +7,15 @@
pkgname=gzip
pkgver=1.12
pkgrel=02
pkgrel=03
pkgdesc='GNU compression utility'
arch=('x86_64')
url='https://www.gnu.org/software/gzip/'
groups=('base-devel')
depends=('glibc' 'bash' 'less')
depends=('glibc' 'bash' 'coreutils' 'sed' 'grep')
optdepends=('less: zless support'
'more: zmore support'
'diffutils: zdiff/zcmp support'
)
source=("https://ftp.gnu.org/pub/gnu/gzip/gzip-$pkgver.tar.xz"{,.sig})
prepare() {
@ -53,6 +56,5 @@ validpgpkeys=('155D3FC500C834486D1EEA677FD9FCCB000BEEEE') # Jim Meyering
sha256sums=(ce5e03e519f637e1f814011ace35c4f87b33c0bbabeec35baf5fbd3479e91956 # gzip-1.12.tar.xz
3ed9ab54452576e0be0d477c772c9f47baa36415133fef7dd1fcf7b15480ba32) # gzip-1.12.tar.xz.sig
## 2afd14df0e7f406ea507fe497f5764a5e88490ff7001e11262ded77ed70d86e2 gzip-1.12-02-x86_64.pkg.tar.lz
## e373f543d2c8f504f5ac10fe06d0aa6b25b36ce5b3d4395b06f4fa847331479d gzip-1.12-03-x86_64.pkg.tar.lz

View File

@ -4,12 +4,16 @@
pkgname=gzip
pkgver=1.12
pkgrel=2
pkgrel=3
pkgdesc='GNU compression utility'
arch=('x86_64')
url='https://www.gnu.org/software/gzip/'
license=('GPL3')
depends=('glibc' 'bash' 'less')
depends=('glibc' 'bash' 'coreutils' 'sed' 'grep')
optdepends=('less: zless support'
'more: zmore support'
'diffutils: zdiff/zcmp support'
)
validpgpkeys=('155D3FC500C834486D1EEA677FD9FCCB000BEEEE') # Jim Meyering
source=("https://ftp.gnu.org/pub/gnu/gzip/gzip-$pkgver.tar.xz"{,.sig})
sha256sums=('ce5e03e519f637e1f814011ace35c4f87b33c0bbabeec35baf5fbd3479e91956'

View File

@ -9,7 +9,7 @@ pkgbase=lvm2
pkgname=('lvm2' 'device-mapper')
_tag='7038cd60222f93f05e4844fe215568de9a67100d' # git rev-parse v${pkgver//./_}
pkgver=2.03.22
pkgrel=01
pkgrel=02
url='https://sourceware.org/lvm2/'
makedepends=('git' 'libaio' 'thin-provisioning-tools')
#options=('!makeflags')
@ -32,6 +32,10 @@ prepare() {
git show "${_c}" -- ':(exclude)WHATS_NEW' | git apply
done
# install libexec scripts
# https://bugs.archlinux.org/task/79352
sed -i '/^install_lvm2:/s|$| install_libexec|' scripts/Makefile.in
# prepare for non-systemd initcpio
# cp udev/69-dm-lvm.rules.in udev/69-dm-lvm-initcpio.rules.in
# patch -Np1 < ../0001-udev-initcpio.patch
@ -72,6 +76,7 @@ build() {
--with-default-locking-dir=/run/lock/lvm \
--with-default-pid-dir=/run \
--with-default-run-dir=/run/lvm \
--with-libexecdir=/usr/lib/lvm2 \
--without-systemdsystemunitdir \
--with-thin=internal \
--with-udev-prefix=/usr
@ -135,6 +140,6 @@ sha256sums=(SKIP
def6e03aa1629bbc0ca1ee5e84e620366daf779f037eab2fda47487a8471729b # lvm2_install
e10f24b57582d6e2da71f7c80732a62e0ee2e3b867fe84591ccdb53e80fa92e0) # 11-dm-initramfs.rules
## 6e224c7d6b1ebdc2442242d63fbfb3efb374458c6fe4c0920c27b37dd241b57b lvm2-2.03.22-01-x86_64.pkg.tar.lz
## 742aeb51be9419bfe709c9e678eb2369d81dc252834c60a0bd91c1292116da3d device-mapper-2.03.22-01-x86_64.pkg.tar.lz
## 95bb872c0f30524a6f38fba3b7165c3f64db876a0eb2c4aa49aaf926b9c2df25 device-mapper-2.03.22-02-x86_64.pkg.tar.lz
## 538558654f6ed104443af1aeb1399233e1cd0b9f770b59992d4c6f1c9435ec39 lvm2-2.03.22-02-x86_64.pkg.tar.lz

View File

@ -5,7 +5,7 @@ pkgbase=lvm2
pkgname=('lvm2' 'device-mapper')
_tag='7038cd60222f93f05e4844fe215568de9a67100d' # git rev-parse v${pkgver//./_}
pkgver=2.03.22
pkgrel=1
pkgrel=2
arch=('x86_64')
url='https://sourceware.org/lvm2/'
license=('GPL2' 'LGPL2.1')
@ -33,6 +33,10 @@ prepare() {
git show "${_c}" -- ':(exclude)WHATS_NEW' | git apply
done
# install libexec scripts
# https://bugs.archlinux.org/task/79352
sed -i '/^install_lvm2:/s|$| install_libexec|' scripts/Makefile.in
# prepare for non-systemd initcpio
patch -Np1 --output='udev/69-dm-lvm-initcpio.rules.in' < ../0001-udev-initcpio.patch
@ -70,6 +74,7 @@ build() {
--with-default-locking-dir=/run/lock/lvm \
--with-default-pid-dir=/run \
--with-default-run-dir=/run/lvm \
--with-libexecdir=/usr/lib/lvm2 \
--with-systemdsystemunitdir=/usr/lib/systemd/system \
--with-thin=internal \
--with-udev-prefix=/usr

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,98 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: "H.J. Lu" <hjl.tools@gmail.com>
Date: Sun, 20 Dec 2020 13:55:40 -0800
Subject: [PATCH 2/2] Pass -mshstk to the compiler when Intel CET is enable
Copied from PCRE2.
---
CMakeLists.txt | 18 ++++++++++++++++++
Makefile.am | 3 +++
configure.ac | 15 +++++++++++++++
3 files changed, 36 insertions(+)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 858a34b..74c27e9 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -112,6 +112,24 @@ CHECK_FUNCTION_EXISTS(_strtoi64 HAVE__STRTOI64)
CHECK_TYPE_SIZE("long long" LONG_LONG)
CHECK_TYPE_SIZE("unsigned long long" UNSIGNED_LONG_LONG)
+# Check whether Intel CET is enabled, and if so, adjust compiler flags. This
+# code was written by PH, trying to imitate the logic from the autotools
+# configuration.
+
+CHECK_C_SOURCE_COMPILES(
+ "#ifndef __CET__
+ #error CET is not enabled
+ #endif
+ int main() { return 0; }"
+ INTEL_CET_ENABLED
+)
+
+IF (INTEL_CET_ENABLED)
+ SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mshstk")
+ENDIF(INTEL_CET_ENABLED)
+
+
+
# User-configurable options
#
# (Note: CMakeSetup displays these in alphabetical order, regardless of
diff --git a/Makefile.am b/Makefile.am
index 22b6947..984c686 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -250,6 +250,7 @@ libpcre_la_SOURCES = \
libpcre_la_CFLAGS = \
$(VISIBILITY_CFLAGS) \
+ $(CET_CFLAGS) \
$(AM_CFLAGS)
libpcre_la_LIBADD =
@@ -289,6 +290,7 @@ libpcre16_la_SOURCES = \
libpcre16_la_CFLAGS = \
$(VISIBILITY_CFLAGS) \
+ $(CET_CFLAGS) \
$(AM_CFLAGS)
libpcre16_la_LIBADD =
@@ -328,6 +330,7 @@ libpcre32_la_SOURCES = \
libpcre32_la_CFLAGS = \
$(VISIBILITY_CFLAGS) \
+ $(CET_CFLAGS) \
$(AM_CFLAGS)
libpcre32_la_LIBADD =
diff --git a/configure.ac b/configure.ac
index 6a3e5f3..15f37d1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1043,6 +1043,21 @@ fi # enable_coverage
AM_CONDITIONAL([WITH_GCOV],[test "x$enable_coverage" = "xyes"])
+AC_MSG_CHECKING([whether Intel CET is enabled])
+AC_LANG_PUSH([C])
+AC_COMPILE_IFELSE([AC_LANG_PROGRAM(,
+ [[#ifndef __CET__
+# error CET is not enabled
+#endif]])],
+ [intel_cet_enabled=yes],
+ [intel_cet_enabled=no])
+AC_MSG_RESULT([$intel_cet_enabled])
+if test "$intel_cet_enabled" = yes; then
+ CET_CFLAGS="-mshstk"
+ AC_SUBST([CET_CFLAGS])
+fi
+AC_LANG_POP([C])
+
# Produce these files, in addition to config.h.
AC_CONFIG_FILES(
Makefile
--
2.34.1

View File

@ -7,15 +7,30 @@
pkgname=pcre
pkgver=8.45
pkgrel=03
pkgdesc='A library that implements Perl 5-style regular expressions'
arch=('x86_64')
pkgrel=04
pkgdesc='A deprecated library that implements Perl 5-style regular expressions'
url='https://www.pcre.org/'
depends=('gcc-libs' 'readline' 'zlib' 'bzip2' 'bash')
depends=('gcc-libs' 'glibc' 'readline' 'zlib' 'bzip2' 'bash')
#options=(debug) ## uncomment this to have the debug pkg produced
options=(staticlibs)
#options=(staticlibs)
provides=(libpcre{,16,32,posix,cpp}.so)
source=("https://sourceforge.net/projects/pcre/files/$pkgname/$pkgver/$pkgname-$pkgver.tar.bz2"{,.sig})
source=("https://sourceforge.net/projects/pcre/files/$pkgname/$pkgver/$pkgname-$pkgver.tar.bz2"{,.sig}
'0001-pcre-JIT-compiler-update-for-Intel-CET.patch'
'0002-pcre-Pass-mshstk-to-the-compiler-when-Intel-CET-is-enable.patch')
prepare() {
cd $pkgname-$pkgver
# apply patch from the source array (should be a pacman feature)
local src
for src in "${source[@]}"; do
src="${src%%::*}"
src="${src##*/}"
[[ $src = *.patch ]] || continue
echo "Applying patch $src..."
patch -Np1 < "../$src"
done
autoreconf -fi
}
build() {
cd $pkgname-$pkgver
@ -28,6 +43,7 @@ build() {
--enable-pcregrep-libz \
--enable-pcregrep-libbz2 \
--enable-pcretest-libreadline
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
make
}
@ -43,12 +59,18 @@ package() {
install -Dm644 LICENCE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}
#---- license gpg-key sha256sums ----
#---- arch license gpg-key & sha256sums ----
arch=(x86_64)
license=('BSD')
validpgpkeys=('45F68D54BBE23FB3039B46E59766E084FB0F43D8') # Philip Hazel <ph10@hermes.cam.ac.uk>
sha256sums=(4dae6fdcd2bb0bb6c37b5f97c33c2be954da743985369cddac3546e3218bffb8 # pcre-8.45.tar.bz2
b3480bc76adf5f220c21331d0efe24bc139c52ea687495765daad2b696b563c2) # pcre-8.45.tar.bz2.sig
sha256sums=(4dae6fdcd2bb0bb6c37b5f97c33c2be954da743985369cddac3546e3218bffb8 # pcre-8.45.tar.bz2
b3480bc76adf5f220c21331d0efe24bc139c52ea687495765daad2b696b563c2 # pcre-8.45.tar.bz2.sig
86e2fe1193f2dfaa5e3f3866c6be42a9cd0dddc5623f1658203a4dc73a4526f7 # 0001-pcre-JIT-compiler-update-for-Intel-CET.patch
a44ffb942d585c2c95036f91529063738b1c373fcd26a3e2dc95ae76b1f3c3db) # 0002-pcre-Pass-mshstk-to-the-compiler-when-Intel-CET-is-enable.patch
## eb918c7ab3e70f62694dfb65e05cf9ab1a93badc374300117c43c6f9d1756fbd pcre-8.45-04-x86_64.pkg.tar.lz

View File

@ -5,19 +5,36 @@
pkgname=pcre
pkgver=8.45
pkgrel=3
pkgdesc='A library that implements Perl 5-style regular expressions'
pkgrel=4
pkgdesc='A deprecated library that implements Perl 5-style regular expressions'
arch=('x86_64')
url='https://www.pcre.org/'
license=('BSD')
depends=('gcc-libs' 'readline' 'zlib' 'bzip2' 'bash')
depends=('glibc' 'gcc-libs' 'readline' 'zlib' 'bzip2' 'bash')
provides=(libpcre{,16,32,posix,cpp}.so)
options=(debug)
source=("https://sourceforge.net/projects/pcre/files/$pkgname/$pkgver/$pkgname-$pkgver.tar.bz2"{,.sig})
sha512sums=('91bff52eed4a2dfc3f3bfdc9c672b88e7e2ffcf3c4b121540af8a4ae8c1ce05178430aa6b8000658b9bb7b4252239357250890e20ceb84b79cdfcde05154061a'
'SKIP')
source=("https://sourceforge.net/projects/pcre/files/$pkgname/$pkgver/$pkgname-$pkgver.tar.bz2"{,.sig}
'0001-pcre-JIT-compiler-update-for-Intel-CET.patch'
'0002-pcre-Pass-mshstk-to-the-compiler-when-Intel-CET-is-enable.patch')
sha256sums=('4dae6fdcd2bb0bb6c37b5f97c33c2be954da743985369cddac3546e3218bffb8'
'SKIP'
'86e2fe1193f2dfaa5e3f3866c6be42a9cd0dddc5623f1658203a4dc73a4526f7'
'a44ffb942d585c2c95036f91529063738b1c373fcd26a3e2dc95ae76b1f3c3db')
validpgpkeys=('45F68D54BBE23FB3039B46E59766E084FB0F43D8') # Philip Hazel <ph10@hermes.cam.ac.uk>
prepare() {
cd $pkgname-$pkgver
# apply patch from the source array (should be a pacman feature)
local src
for src in "${source[@]}"; do
src="${src%%::*}"
src="${src##*/}"
[[ $src = *.patch ]] || continue
echo "Applying patch $src..."
patch -Np1 < "../$src"
done
autoreconf -fi
}
build() {
cd $pkgname-$pkgver
./configure \
@ -29,6 +46,7 @@ build() {
--enable-pcregrep-libz \
--enable-pcregrep-libbz2 \
--enable-pcretest-libreadline
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
make
}

View File

@ -1,2 +1,4 @@
autoconf
automake

View File

@ -1,6 +1,6 @@
real 1m47.135s
user 1m39.913s
sys 0m4.010s
real 1m59.383s
user 1m54.160s
sys 0m6.645s