Compare commits
48
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
56d9d5e8f0 | ||
|
|
e13a3c95c1 | ||
|
|
34b585c099 | ||
|
|
c399b6d682 | ||
|
|
36eed021b6 | ||
|
|
30bc19f730 | ||
|
|
37741586af | ||
|
|
e77bf9257e | ||
|
|
a3a1364f3d | ||
|
|
089731c8ea | ||
|
|
bd397daf1c | ||
|
|
358b4116c7 | ||
|
|
b4d8147a95 | ||
|
|
fd313c4ceb | ||
|
|
d26f371758 | ||
|
|
522b56cd50 | ||
|
|
0ce896b28b | ||
|
|
8d6f9393ec | ||
|
|
2c627ac6b3 | ||
|
|
f74f7d4a03 | ||
|
|
c8edd532c2 | ||
|
|
ddbad663e0 | ||
|
|
bfd75a5bd2 | ||
|
|
b1b3aab60d | ||
|
|
0f20d9a9b8 | ||
|
|
a68899d49e | ||
|
|
1838d8e5ea | ||
|
|
6b410a5fd8 | ||
|
|
164d6e65c7 | ||
|
|
d402ffe276 | ||
|
|
ad75a5d478 | ||
|
|
25918f455c | ||
|
|
7c820d45cd | ||
|
|
7acaff2d9b | ||
|
|
da3996a39d | ||
|
|
cff52ab07c | ||
|
|
d1553b47e0 | ||
|
|
103f75bfab | ||
|
|
41463deed4 | ||
|
|
c53f5e78fc | ||
|
|
90be04d4d3 | ||
|
|
b73853cf7f | ||
|
|
13e778fcf1 | ||
|
|
2c6a292b93 | ||
|
|
a9d487ae5d | ||
|
|
a5da7ee5a8 | ||
|
|
a80b13fc63 | ||
|
|
070d91ed04 |
@@ -35,8 +35,6 @@ board/intel/galileo/patches/linux/0001-x86-relocs-Make-per_cpu_load_addr-static.
|
||||
board/intel/galileo/post-build.sh Shellcheck
|
||||
board/intel/galileo/rootfs_overlay/etc/init.d/S09modload Shellcheck lib_sysv.Variables
|
||||
board/kontron/bl-imx8mm/post-build.sh Shellcheck
|
||||
board/kontron/pitx-imx8m/patches/uboot/2022.04/0001-tools-mkeficapsule-use-pkg-config-to-get-luuid-and-l.patch lib_patch.NumberedSubject lib_patch.Upstream
|
||||
board/kontron/pitx-imx8m/post-build.sh Shellcheck
|
||||
board/kontron/smarc-sal28/post-build.sh Shellcheck
|
||||
board/lego/ev3/post-image.sh Shellcheck
|
||||
board/lemaker/bananapro/patches/linux/0001-arch-arm-boot-dts-sun7i-a20-bananapro.dts-disable-00.patch lib_patch.Upstream
|
||||
@@ -159,7 +157,6 @@ configs/imx8mqevk_defconfig lib_defconfig.ForceCheckHash
|
||||
configs/imxrt1050-evk_defconfig lib_defconfig.ForceCheckHash
|
||||
configs/khadas_vim3_defconfig lib_defconfig.ForceCheckHash
|
||||
configs/kontron_bl_imx8mm_defconfig lib_defconfig.ForceCheckHash
|
||||
configs/kontron_pitx_imx8m_defconfig lib_defconfig.ForceCheckHash
|
||||
configs/kontron_smarc_sal28_defconfig lib_defconfig.ForceCheckHash
|
||||
configs/mangopi_mq1rdw2_defconfig lib_defconfig.ForceCheckHash
|
||||
configs/mender_x86_64_efi_defconfig lib_defconfig.ForceCheckHash
|
||||
@@ -664,7 +661,6 @@ package/libnetfilter_conntrack/0001-conntrack-fix-build-with-kernel-5-15-and-mus
|
||||
package/libnfc/0001-autotools-make-example-build-optional.patch lib_patch.Upstream
|
||||
package/libnids/0001-libpcap-use-pkg-config.patch lib_patch.Upstream
|
||||
package/libnss/0001-Bug-1801182-Allow-overriding-OS_ARCH-OS_TEST-and-OS_.patch lib_patch.Upstream
|
||||
package/liboauth/0001-Fixes-build-issue-with-OpenSSL-1.1.0.patch lib_patch.Upstream
|
||||
package/libodb-mysql/0001-fix-syntax-issue-while-checking-ldflags.patch lib_patch.Upstream
|
||||
package/libodb-mysql/0002-mariadb-FTBFS-fix.patch lib_patch.Upstream
|
||||
package/libopenssl/0001-Reproducible-build-do-not-leak-compiler-path.patch lib_patch.Upstream
|
||||
@@ -1043,8 +1039,6 @@ package/screen/0002-Change-binary-permission-flags-even-if-chown-fails.patch lib
|
||||
package/screen/0003-Support-overriding-SCREEN-to-get-a-non-versioned-bin.patch lib_patch.Upstream
|
||||
package/screen/0004-Renamed-sched.h-to-eventqueue.h.patch lib_patch.Upstream
|
||||
package/scrub/0001-configure-ac-make-sure-m4-macros-are-included-in-the-build.patch lib_patch.Upstream
|
||||
package/sdl/0001-fix-compilation-with-libx11.patch lib_patch.Upstream
|
||||
package/sdl/0002-SDL_x11yuv.c-fix-possible-use-after-free.patch lib_patch.Upstream
|
||||
package/sdl_mixer/0001-Add-Libs.private-field-to-pkg-config-file.patch lib_patch.Upstream
|
||||
package/sdl_mixer/0002-configure__set_macro_directory.patch lib_patch.Upstream
|
||||
package/sdl_mixer/0003-configure.ac-fix-static-linking-with-tremor.patch lib_patch.Upstream
|
||||
|
||||
@@ -1,3 +1,23 @@
|
||||
2025.08-rc3, released August 28th, 2025
|
||||
|
||||
Fixes all over the tree, mainly GCC 15.x build fixes
|
||||
|
||||
support/misc/pkg-stats: Be more robust when parsing CVEs
|
||||
|
||||
Fixed defconfigs: canaan_kd233, sipeed_maix*: Correct Linux
|
||||
image name configuration, ci20: Needs host-openssl,
|
||||
imx6ulz_bsh_smm_m2: Use correct FPU configuration
|
||||
|
||||
Removed defconfigs: kontron_pitx_imx8m
|
||||
|
||||
Updated/fixed packages: binutils, cpp-httplib, dtach,
|
||||
dump1090, ffmpeg, gdbm, gpm, libjwt, liblog4c-localtime,
|
||||
libv4l, lrzsz, mesa3d, p11-kit, php-lua, proftpd,
|
||||
python-aexpect, python-pyroute2, python3, rpi-userland, sdl,
|
||||
vim, wayland, weston, wpewebkit, xvisor
|
||||
|
||||
Removed packages: liboauth
|
||||
|
||||
2025.08-rc2, released August 21th, 2025
|
||||
|
||||
Fixes all over the tree.
|
||||
|
||||
@@ -146,6 +146,13 @@ endif
|
||||
|
||||
comment "Legacy options removed in 2025.08"
|
||||
|
||||
config BR2_KERNEL_HEADERS_6_15
|
||||
bool "kernel headers version 6.15.x are no longer supported"
|
||||
select BR2_LEGACY
|
||||
help
|
||||
Version 6.15.x of the Linux kernel headers are no longer
|
||||
maintained upstream and are now removed.
|
||||
|
||||
config BR2_PACKAGE_LIBCURL_BEARSSL
|
||||
bool "libcurl removed BearSSL support"
|
||||
select BR2_LEGACY
|
||||
|
||||
+1
-3
@@ -187,7 +187,7 @@ F: package/pkg-qmake.mk
|
||||
F: package/qt5/qt5opcua/
|
||||
F: package/qt6/qt6opcua/
|
||||
|
||||
N: Andreas Ziegler <br015@umbiko.net>
|
||||
N: Andreas Ziegler <br025@umbiko.net>
|
||||
F: package/mpd/
|
||||
|
||||
N: Andrey Smirnov <andrew.smirnov@gmail.com>
|
||||
@@ -1408,10 +1408,8 @@ F: package/volk/
|
||||
N: Heiko Thiery <heiko.thiery@gmail.com>
|
||||
F: board/kontron/bl-imx8mm/
|
||||
F: board/kontron/smarc-sal28/
|
||||
F: board/kontron/pitx-imx8m/
|
||||
F: configs/kontron_bl_imx8mm_defconfig
|
||||
F: configs/kontron_smarc_sal28_defconfig
|
||||
F: configs/kontron_pitx_imx8m_defconfig
|
||||
F: package/altera-stapl/
|
||||
F: package/blake3/
|
||||
F: package/ipmitool/
|
||||
|
||||
@@ -92,9 +92,9 @@ all:
|
||||
.PHONY: all
|
||||
|
||||
# Set and export the version string
|
||||
export BR2_VERSION := 2025.08-rc2
|
||||
export BR2_VERSION := 2025.08-rc3
|
||||
# Actual time the release is cut (for reproducible builds)
|
||||
BR2_VERSION_EPOCH = 1755760000
|
||||
BR2_VERSION_EPOCH = 1756360000
|
||||
|
||||
# Save running make version since it's clobbered by the make package
|
||||
RUNNING_MAKE_VERSION := $(MAKE_VERSION)
|
||||
|
||||
+2
-2
@@ -785,7 +785,7 @@ config BR2_ARM_INSTRUCTIONS_THUMB
|
||||
# Thumb-1 and VFP are not compatible
|
||||
depends on BR2_ARM_SOFT_FLOAT
|
||||
help
|
||||
This option instructions the compiler to generate Thumb
|
||||
This option instructs the compiler to generate Thumb
|
||||
instructions, which allows to mix 16 bits instructions and
|
||||
32 bits instructions. This generally provides a much smaller
|
||||
compiled binary size.
|
||||
@@ -798,7 +798,7 @@ config BR2_ARM_INSTRUCTIONS_THUMB2
|
||||
bool "Thumb2"
|
||||
depends on BR2_ARM_CPU_HAS_THUMB2
|
||||
help
|
||||
This option instructions the compiler to generate Thumb2
|
||||
This option instructs the compiler to generate Thumb2
|
||||
instructions, which allows to mix 16 bits instructions and
|
||||
32 bits instructions. This generally provides a much smaller
|
||||
compiled binary size.
|
||||
|
||||
@@ -1,4 +0,0 @@
|
||||
label buildroot
|
||||
kernel /boot/Image
|
||||
devicetree /boot/freescale/imx8mq-kontron-pitx-imx8m.dtb
|
||||
append root=PARTUUID=%PARTUUID% rootwait rw
|
||||
@@ -1,17 +0,0 @@
|
||||
image sdcard.img {
|
||||
hdimage {
|
||||
partition-table-type = "gpt"
|
||||
}
|
||||
|
||||
partition imx-boot {
|
||||
in-partition-table = "no"
|
||||
image = "flash.bin"
|
||||
offset = 33K
|
||||
}
|
||||
|
||||
partition rootfs {
|
||||
offset = 8M
|
||||
image = "rootfs.ext4"
|
||||
partition-uuid = %PARTUUID%
|
||||
}
|
||||
}
|
||||
-33
@@ -1,33 +0,0 @@
|
||||
From f3523977e8f5f6b2173708777001332431ebc609 Mon Sep 17 00:00:00 2001
|
||||
From: Heiko Thiery <heiko.thiery@gmail.com>
|
||||
Date: Tue, 19 Jul 2022 16:17:09 +0200
|
||||
Subject: [PATCH 1/2] tools: mkeficapsule: use pkg-config to get -luuid and -lgnutls
|
||||
|
||||
Instead of hardcoding -luuid -lgnutls as the flags needed to build
|
||||
mkeficapsule, use pkg-config when available.
|
||||
|
||||
We gracefully fallback on the previous behavior of hardcoding -luuid
|
||||
-lgnutls if pkg-config is not available or fails with an error.
|
||||
|
||||
Signed-off-by: Heiko Thiery <heiko.thiery@gmail.com>
|
||||
---
|
||||
tools/Makefile | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/tools/Makefile b/tools/Makefile
|
||||
index 9f2339666a..9f6b282ad8 100644
|
||||
--- a/tools/Makefile
|
||||
+++ b/tools/Makefile
|
||||
@@ -242,7 +242,8 @@ hostprogs-$(CONFIG_MIPS) += mips-relocs
|
||||
hostprogs-$(CONFIG_ASN1_COMPILER) += asn1_compiler
|
||||
HOSTCFLAGS_asn1_compiler.o = -idirafter $(srctree)/include
|
||||
|
||||
-HOSTLDLIBS_mkeficapsule += -lgnutls -luuid
|
||||
+HOSTLDLIBS_mkeficapsule += \
|
||||
+ $(shell pkg-config --libs gnutls uuid 2> /dev/null || echo "-lgnutls -luuid")
|
||||
hostprogs-$(CONFIG_TOOLS_MKEFICAPSULE) += mkeficapsule
|
||||
|
||||
# We build some files with extra pedantic flags to try to minimize things
|
||||
--
|
||||
2.30.2
|
||||
|
||||
@@ -1,7 +0,0 @@
|
||||
#!/bin/sh
|
||||
BOARD_DIR="$(dirname $0)"
|
||||
PARTUUID="$($HOST_DIR/bin/uuidgen)"
|
||||
|
||||
install -d "$TARGET_DIR/boot/extlinux/"
|
||||
sed "s/%PARTUUID%/$PARTUUID/g" "$BOARD_DIR/extlinux.conf" > "$TARGET_DIR/boot/extlinux/extlinux.conf"
|
||||
sed "s/%PARTUUID%/$PARTUUID/g" "$BOARD_DIR/genimage.cfg" > "$BINARIES_DIR/genimage.cfg"
|
||||
@@ -1,74 +0,0 @@
|
||||
Kontron pitx-imx8m
|
||||
==================
|
||||
|
||||
https://www.kontron.com/produkte/pitx-imx8m/p155258
|
||||
|
||||
|
||||
How to build it
|
||||
===============
|
||||
|
||||
Configure buildroot:
|
||||
|
||||
$ make kontron_pitx_imx8m_defconfig
|
||||
|
||||
Change settings to fit your needs (optional):
|
||||
|
||||
$ make menuconfig
|
||||
|
||||
Compile everything and buildr the rootfs image:
|
||||
|
||||
$ make
|
||||
|
||||
|
||||
Result of the build
|
||||
===================
|
||||
|
||||
After building, the output/images directory contains:
|
||||
|
||||
output/images/
|
||||
├── bl31.bin
|
||||
├── boot.scr
|
||||
├── ddr_fw.bin
|
||||
├── Image
|
||||
├── imx8-boot-sd.bin
|
||||
├── imx8mq-kontron-pitx-imx8m.dtb
|
||||
├── lpddr4_pmu_train_fw.bin
|
||||
├── rootfs.ext2
|
||||
├── rootfs.ext4 -> rootfs.ext2
|
||||
├── rootfs.tar
|
||||
├── sdcard.img
|
||||
├── signed_hdmi_imx8m.bin
|
||||
├── u-boot.bin
|
||||
├── u-boot.itb
|
||||
├── u-boot-nodtb.bin
|
||||
├── u-boot-spl.bin
|
||||
└── u-boot-spl-ddr.bin
|
||||
|
||||
|
||||
Flashing the SD card image
|
||||
==========================
|
||||
|
||||
To install the image on a SDCard simply copy sdcard.img to the storage (e.g. SD, eMMC)
|
||||
|
||||
$ sudo dd if=output/images/sdcard.img of=<your-sd-device>
|
||||
|
||||
|
||||
Preparing the board
|
||||
===================
|
||||
|
||||
* Connect a serial line to the board
|
||||
* Insert the SD card
|
||||
* Make sure the boot source selection DIP switches are set correctly
|
||||
* SW1 1-4 OFF
|
||||
* SW1 2-3 OFF
|
||||
* Power-up the board
|
||||
|
||||
|
||||
Booting the board
|
||||
=================
|
||||
|
||||
By default the bootloader will search for the first valid image, starting
|
||||
with the internal eMMC. To make sure the bootloader loads bootscript from
|
||||
the correct location (SD card) set the boot_targets environment variable:
|
||||
|
||||
$ setenv boot_targets mmc1
|
||||
@@ -1,3 +1,2 @@
|
||||
# Locally calculated
|
||||
sha256 a45390c9e1d584a389abd37ee49dce3f8d3b41718b1fd7c977608b5387a38955 xlnx_rebase_v2.10_2024.2.tar.gz
|
||||
sha256 4d16661f367adb8713113acb420a1ad5f611ce6a309e98005a8ea3273511f03d xlnx_rebase_v2.12_2025.1.tar.gz
|
||||
|
||||
@@ -1,3 +1,2 @@
|
||||
# Locally calculated
|
||||
sha256 b726226e8784d92049190f19768d393eccf3ad111c7a2e685bb29cfa1bdf1f70 xlnx_rebase_v6.6_LTS_merge_6.6.70.tar.gz
|
||||
sha256 25795c354f30a3358506ab02deeac99e7f79850804c52d6c3d5539fd310f0491 xlnx_rebase_v6.12_LTS_2025.1.tar.gz
|
||||
|
||||
@@ -1,3 +1,2 @@
|
||||
# Locally calculated
|
||||
sha256 f1a86ccdbe60bac89177a24bbfd56fc6e8e67823669f0997de563c3cc0ea4dd1 xlnx_rebase_v2024.01_2024.2.tar.gz
|
||||
sha256 b86d6f07d16a83ed0bdbd9b9439e099afc87ba7dfb77246e2472183848e2ea93 xlnx_rebase_v2025.01_2025.1.tar.gz
|
||||
|
||||
@@ -15,7 +15,7 @@ BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="5.19"
|
||||
BR2_LINUX_KERNEL_DEFCONFIG="nommu_k210"
|
||||
BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="board/canaan/kd233/linux-cpio.config"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y
|
||||
BR2_LINUX_KERNEL_IMAGE_NAME="loader.bin"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="loader.bin"
|
||||
BR2_PACKAGE_BUSYBOX_CONFIG_FRAGMENT_FILES="board/canaan/k210-soc/busybox-tiny.config"
|
||||
# BR2_PACKAGE_IFUPDOWN_SCRIPTS is not set
|
||||
BR2_TARGET_ROOTFS_INITRAMFS=y
|
||||
|
||||
@@ -18,6 +18,7 @@ BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y
|
||||
BR2_TARGET_UBOOT_CUSTOM_VERSION=y
|
||||
BR2_TARGET_UBOOT_CUSTOM_VERSION_VALUE="2024.01"
|
||||
BR2_TARGET_UBOOT_BOARD_DEFCONFIG="ci20_mmc"
|
||||
BR2_TARGET_UBOOT_NEEDS_OPENSSL=y
|
||||
BR2_TARGET_UBOOT_FORMAT_IMG=y
|
||||
BR2_TARGET_UBOOT_SPL=y
|
||||
BR2_PACKAGE_HOST_GENIMAGE=y
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
BR2_arm=y
|
||||
BR2_cortex_a7=y
|
||||
BR2_ARM_FPU_VFPV3=y
|
||||
BR2_ARM_FPU_NEON_VFPV4=y
|
||||
BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_6_12=y
|
||||
BR2_GLOBAL_PATCH_DIR="board/bsh/imx6ulz-bsh-smm-m2/patches"
|
||||
BR2_DOWNLOAD_FORCE_CHECK_HASHES=y
|
||||
|
||||
@@ -1,45 +0,0 @@
|
||||
BR2_aarch64=y
|
||||
BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_5_17=y
|
||||
BR2_GLOBAL_PATCH_DIR="board/kontron/pitx-imx8m/patches"
|
||||
BR2_TARGET_GENERIC_GETTY_PORT="ttymxc2"
|
||||
BR2_ROOTFS_POST_BUILD_SCRIPT="board/kontron/pitx-imx8m/post-build.sh"
|
||||
BR2_ROOTFS_POST_IMAGE_SCRIPT="support/scripts/genimage.sh"
|
||||
BR2_ROOTFS_POST_SCRIPT_ARGS="-c $(BINARIES_DIR)/genimage.cfg"
|
||||
BR2_LINUX_KERNEL=y
|
||||
BR2_LINUX_KERNEL_CUSTOM_VERSION=y
|
||||
BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="5.17.7"
|
||||
BR2_LINUX_KERNEL_USE_ARCH_DEFAULT_CONFIG=y
|
||||
BR2_LINUX_KERNEL_DTS_SUPPORT=y
|
||||
BR2_LINUX_KERNEL_INTREE_DTS_NAME="freescale/imx8mq-kontron-pitx-imx8m"
|
||||
BR2_LINUX_KERNEL_DTB_KEEP_DIRNAME=y
|
||||
BR2_LINUX_KERNEL_INSTALL_TARGET=y
|
||||
BR2_LINUX_KERNEL_NEEDS_HOST_OPENSSL=y
|
||||
BR2_PACKAGE_FREESCALE_IMX=y
|
||||
BR2_PACKAGE_FREESCALE_IMX_PLATFORM_IMX8M=y
|
||||
BR2_PACKAGE_FIRMWARE_IMX=y
|
||||
BR2_TARGET_ROOTFS_EXT2=y
|
||||
BR2_TARGET_ROOTFS_EXT2_4=y
|
||||
BR2_TARGET_ROOTFS_EXT2_SIZE="120M"
|
||||
BR2_TARGET_ARM_TRUSTED_FIRMWARE=y
|
||||
BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_VERSION=y
|
||||
BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_VERSION_VALUE="v2.5"
|
||||
BR2_TARGET_ARM_TRUSTED_FIRMWARE_PLATFORM="imx8mq"
|
||||
BR2_TARGET_UBOOT=y
|
||||
BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y
|
||||
BR2_TARGET_UBOOT_CUSTOM_VERSION=y
|
||||
BR2_TARGET_UBOOT_CUSTOM_VERSION_VALUE="2022.04"
|
||||
BR2_TARGET_UBOOT_BOARD_DEFCONFIG="kontron_pitx_imx8m"
|
||||
BR2_TARGET_UBOOT_NEEDS_DTC=y
|
||||
BR2_TARGET_UBOOT_NEEDS_PYLIBFDT=y
|
||||
BR2_TARGET_UBOOT_NEEDS_OPENSSL=y
|
||||
BR2_TARGET_UBOOT_NEEDS_GNUTLS=y
|
||||
BR2_TARGET_UBOOT_NEEDS_UTIL_LINUX=y
|
||||
BR2_TARGET_UBOOT_NEEDS_ATF_BL31=y
|
||||
BR2_TARGET_UBOOT_NEEDS_IMX_FIRMWARE=y
|
||||
BR2_TARGET_UBOOT_FORMAT_CUSTOM=y
|
||||
BR2_TARGET_UBOOT_FORMAT_CUSTOM_NAME="flash.bin"
|
||||
BR2_TARGET_UBOOT_SPL=y
|
||||
BR2_PACKAGE_HOST_GENIMAGE=y
|
||||
BR2_PACKAGE_HOST_IMX_MKIMAGE=y
|
||||
BR2_PACKAGE_HOST_UBOOT_TOOLS=y
|
||||
BR2_PACKAGE_HOST_UBOOT_TOOLS_FIT_SUPPORT=y
|
||||
@@ -15,7 +15,7 @@ BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="5.19"
|
||||
BR2_LINUX_KERNEL_DEFCONFIG="nommu_k210"
|
||||
BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="board/sipeed/maix-bit/linux-cpio.config"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y
|
||||
BR2_LINUX_KERNEL_IMAGE_NAME="loader.bin"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="loader.bin"
|
||||
BR2_PACKAGE_BUSYBOX_CONFIG_FRAGMENT_FILES="board/canaan/k210-soc/busybox-tiny.config"
|
||||
# BR2_PACKAGE_IFUPDOWN_SCRIPTS is not set
|
||||
BR2_TARGET_ROOTFS_INITRAMFS=y
|
||||
|
||||
@@ -19,7 +19,7 @@ BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="5.19"
|
||||
BR2_LINUX_KERNEL_DEFCONFIG="nommu_k210_sdcard"
|
||||
BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="board/canaan/k210-soc/linux-sdcard.config"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y
|
||||
BR2_LINUX_KERNEL_IMAGE_NAME="loader.bin"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="loader.bin"
|
||||
BR2_LINUX_KERNEL_DTS_SUPPORT=y
|
||||
BR2_LINUX_KERNEL_INTREE_DTS_NAME="canaan/sipeed_maix_bit"
|
||||
# BR2_PACKAGE_IFUPDOWN_SCRIPTS is not set
|
||||
|
||||
@@ -15,7 +15,7 @@ BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="5.19"
|
||||
BR2_LINUX_KERNEL_DEFCONFIG="nommu_k210"
|
||||
BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="board/sipeed/maix-dock/linux-cpio.config"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y
|
||||
BR2_LINUX_KERNEL_IMAGE_NAME="loader.bin"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="loader.bin"
|
||||
BR2_PACKAGE_BUSYBOX_CONFIG_FRAGMENT_FILES="board/canaan/k210-soc/busybox-tiny.config"
|
||||
# BR2_PACKAGE_IFUPDOWN_SCRIPTS is not set
|
||||
BR2_TARGET_ROOTFS_INITRAMFS=y
|
||||
|
||||
@@ -19,7 +19,7 @@ BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="5.19"
|
||||
BR2_LINUX_KERNEL_DEFCONFIG="nommu_k210_sdcard"
|
||||
BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="board/canaan/k210-soc/linux-sdcard.config"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y
|
||||
BR2_LINUX_KERNEL_IMAGE_NAME="loader.bin"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="loader.bin"
|
||||
BR2_LINUX_KERNEL_DTS_SUPPORT=y
|
||||
BR2_LINUX_KERNEL_INTREE_DTS_NAME="canaan/sipeed_maix_dock"
|
||||
# BR2_PACKAGE_IFUPDOWN_SCRIPTS is not set
|
||||
|
||||
@@ -15,7 +15,7 @@ BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="5.19"
|
||||
BR2_LINUX_KERNEL_DEFCONFIG="nommu_k210"
|
||||
BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="board/sipeed/maix-go/linux-cpio.config"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y
|
||||
BR2_LINUX_KERNEL_IMAGE_NAME="loader.bin"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="loader.bin"
|
||||
BR2_PACKAGE_BUSYBOX_CONFIG_FRAGMENT_FILES="board/canaan/k210-soc/busybox-tiny.config"
|
||||
# BR2_PACKAGE_IFUPDOWN_SCRIPTS is not set
|
||||
BR2_TARGET_ROOTFS_INITRAMFS=y
|
||||
|
||||
@@ -19,7 +19,7 @@ BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="5.19"
|
||||
BR2_LINUX_KERNEL_DEFCONFIG="nommu_k210_sdcard"
|
||||
BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="board/canaan/k210-soc/linux-sdcard.config"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y
|
||||
BR2_LINUX_KERNEL_IMAGE_NAME="loader.bin"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="loader.bin"
|
||||
BR2_LINUX_KERNEL_DTS_SUPPORT=y
|
||||
BR2_LINUX_KERNEL_INTREE_DTS_NAME="canaan/sipeed_maix_go"
|
||||
# BR2_PACKAGE_IFUPDOWN_SCRIPTS is not set
|
||||
|
||||
@@ -15,7 +15,7 @@ BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="5.19"
|
||||
BR2_LINUX_KERNEL_DEFCONFIG="nommu_k210"
|
||||
BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="board/sipeed/maixduino/linux-cpio.config"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y
|
||||
BR2_LINUX_KERNEL_IMAGE_NAME="loader.bin"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="loader.bin"
|
||||
BR2_PACKAGE_BUSYBOX_CONFIG_FRAGMENT_FILES="board/canaan/k210-soc/busybox-tiny.config"
|
||||
# BR2_PACKAGE_IFUPDOWN_SCRIPTS is not set
|
||||
BR2_TARGET_ROOTFS_INITRAMFS=y
|
||||
|
||||
@@ -19,7 +19,7 @@ BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="5.19"
|
||||
BR2_LINUX_KERNEL_DEFCONFIG="nommu_k210_sdcard"
|
||||
BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="board/canaan/k210-soc/linux-sdcard.config"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y
|
||||
BR2_LINUX_KERNEL_IMAGE_NAME="loader.bin"
|
||||
BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="loader.bin"
|
||||
BR2_LINUX_KERNEL_DTS_SUPPORT=y
|
||||
BR2_LINUX_KERNEL_INTREE_DTS_NAME="canaan/sipeed_maixduino"
|
||||
# BR2_PACKAGE_IFUPDOWN_SCRIPTS is not set
|
||||
|
||||
@@ -76,37 +76,37 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h3 style="text-align: center;">Latest release candidate: <b>2025.08-rc2</b></h3>
|
||||
<h3 style="text-align: center;">Latest release candidate: <b>2025.08-rc3</b></h3>
|
||||
<div class="row mt centered">
|
||||
<div class="col-sm-6">
|
||||
<div class="flip-container center-block" ontouchstart="this.classList.toggle('hover');">
|
||||
<div class="flipper">
|
||||
<div class="front">
|
||||
<a href="/downloads/buildroot-2025.08-rc2.tar.gz"><img src="images/zip.png" width="180" alt=""></a>
|
||||
<a href="/downloads/buildroot-2025.08-rc3.tar.gz"><img src="images/zip.png" width="180" alt=""></a>
|
||||
</div>
|
||||
<div class="back">
|
||||
<a href="/downloads/buildroot-2025.08-rc2.tar.gz"><img src="images/zip.png" width="180" alt=""></a>
|
||||
<a href="/downloads/buildroot-2025.08-rc3.tar.gz"><img src="images/zip.png" width="180" alt=""></a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h3><a href="/downloads/buildroot-2025.08-rc2.tar.gz">buildroot-2025.08-rc2.tar.gz</a></h3>
|
||||
<p><a href="/downloads/buildroot-2025.08-rc2.tar.gz.sign">PGP signature</a></p>
|
||||
<h3><a href="/downloads/buildroot-2025.08-rc3.tar.gz">buildroot-2025.08-rc3.tar.gz</a></h3>
|
||||
<p><a href="/downloads/buildroot-2025.08-rc3.tar.gz.sign">PGP signature</a></p>
|
||||
</div>
|
||||
<div class="col-sm-6">
|
||||
<div class="flip-container center-block" ontouchstart="this.classList.toggle('hover');">
|
||||
<div class="flipper">
|
||||
<div class="front">
|
||||
<a href="/downloads/buildroot-2025.08-rc2.tar.xz"><img src="images/package.png" width="180" alt=""></a>
|
||||
<a href="/downloads/buildroot-2025.08-rc3.tar.xz"><img src="images/package.png" width="180" alt=""></a>
|
||||
</div>
|
||||
<div class="back">
|
||||
<a href="/downloads/buildroot-2025.08-rc2.tar.xz"><img src="images/package.png" width="180" alt=""></a>
|
||||
<a href="/downloads/buildroot-2025.08-rc3.tar.xz"><img src="images/package.png" width="180" alt=""></a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h3><a href="/downloads/buildroot-2025.08-rc2.tar.xz">buildroot-2025.08-rc2.tar.xz</a></h3>
|
||||
<p><a href="/downloads/buildroot-2025.08-rc2.tar.xz.sign">PGP signature</a></p>
|
||||
<h3><a href="/downloads/buildroot-2025.08-rc3.tar.xz">buildroot-2025.08-rc3.tar.xz</a></h3>
|
||||
<p><a href="/downloads/buildroot-2025.08-rc3.tar.xz.sign">PGP signature</a></p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -9,6 +9,27 @@
|
||||
<h2>News</h2>
|
||||
<ul class="timeline">
|
||||
|
||||
<li>
|
||||
<div class="timeline-badge"><i class="glyphicon glyphicon-thumbs-up"></i></div>
|
||||
<div class="timeline-panel">
|
||||
<div class="timeline-heading">
|
||||
<h4 class="timeline-title">2025.08-rc3 released</h4>
|
||||
<p><small class="text-muted"><i class="glyphicon glyphicon-time"></i>28 August 2025</small></p>
|
||||
</div>
|
||||
<div class="timeline-body">
|
||||
<p>Another week, another release candidate with more cleanups and build fixes. See the
|
||||
<a href="https://gitlab.com/buildroot.org/buildroot/-/blob/2025.08-rc3/CHANGES">CHANGES</a>
|
||||
file for more details.</p>
|
||||
|
||||
<p>Go to the <a href="/downloads/">downloads page</a> to pick up the
|
||||
<a href="/downloads/buildroot-2025.08-rc3.tar.xz">2025.08-rc3
|
||||
release</a>, and report any problems found to the
|
||||
<a href="support.html">mailing list</a> or
|
||||
<a href="https://gitlab.com/buildroot.org/buildroot/-/issues">bug tracker</a>.</p>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
<li class="timeline-inverted">
|
||||
<div class="timeline-badge"><i class="glyphicon glyphicon-thumbs-up"></i></div>
|
||||
<div class="timeline-panel">
|
||||
|
||||
+5
-1
@@ -36,6 +36,8 @@ config BR2_LINUX_KERNEL_LATEST_VERSION
|
||||
|
||||
config BR2_LINUX_KERNEL_LATEST_CIP_VERSION
|
||||
bool "Latest CIP SLTS version (5.10.162-cip24)"
|
||||
# Support was introduced in Linux 5.19
|
||||
depends on !BR2_loongarch64
|
||||
select BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_10 if BR2_KERNEL_HEADERS_AS_KERNEL
|
||||
help
|
||||
CIP launched in the spring of 2016 to address the needs of
|
||||
@@ -56,6 +58,8 @@ config BR2_LINUX_KERNEL_LATEST_CIP_VERSION
|
||||
|
||||
config BR2_LINUX_KERNEL_LATEST_CIP_RT_VERSION
|
||||
bool "Latest CIP RT SLTS version (5.10.162-cip24-rt10)"
|
||||
# Support was introduced in Linux 5.19
|
||||
depends on !BR2_loongarch64
|
||||
select BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_10 if BR2_KERNEL_HEADERS_AS_KERNEL
|
||||
help
|
||||
Same as the CIP version, but this is the PREEMPT_RT realtime
|
||||
@@ -137,7 +141,7 @@ config BR2_LINUX_KERNEL_CUSTOM_REPO_GIT_SUBMODULES
|
||||
|
||||
config BR2_LINUX_KERNEL_VERSION
|
||||
string
|
||||
default "6.16" if BR2_LINUX_KERNEL_LATEST_VERSION
|
||||
default "6.16.2" if BR2_LINUX_KERNEL_LATEST_VERSION
|
||||
default "5.10.162-cip24" if BR2_LINUX_KERNEL_LATEST_CIP_VERSION
|
||||
default "5.10.162-cip24-rt10" if BR2_LINUX_KERNEL_LATEST_CIP_RT_VERSION
|
||||
default BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE \
|
||||
|
||||
+4
-5
@@ -1,9 +1,8 @@
|
||||
# From https://www.kernel.org/pub/linux/kernel/v6.x/sha256sums.asc
|
||||
sha256 1a4be2fe6b5246aa4ac8987a8a4af34c42a8dd7d08b46ab48516bcc1befbcd83 linux-6.16.tar.xz
|
||||
sha256 e94f3af85492302f7a819441458f80bca0ad9912e5a4c83c699ff3c63c52957d linux-6.15.9.tar.xz
|
||||
sha256 6b19a3ae99423de2416964d67251d745910277af258b4c4c63e88fd87dbf0e27 linux-6.12.41.tar.xz
|
||||
sha256 8c4ff2869736538b9b0d88ea8dbf0332b79c6ecc40a32066768a754df1fae1c0 linux-6.6.101.tar.xz
|
||||
sha256 218f25663a41e3d811e84fa1c4acec50684898b2f6d0c8c0deb531d937e466f7 linux-6.1.147.tar.xz
|
||||
sha256 b760a6fa793d774fbd3b7fa0bea3efd5c4f5294dfb98ef1bd5f6d5f7cef4f06d linux-6.16.2.tar.xz
|
||||
sha256 0fcbbbbcd456e87bbbfc8bf37af541fda62ccfcce76903503424fd101ef7bdee linux-6.12.43.tar.xz
|
||||
sha256 80d2feb7334c30bacbe1e7dafa9ea415efb2c0ea4f4740ecbd1467cf5d94de5c linux-6.6.102.tar.xz
|
||||
sha256 d9a03d3a2771c60fc726c58d3bba61123e5fd22d45ed27f6cf7a308c171180a1 linux-6.1.148.tar.xz
|
||||
# From https://www.kernel.org/pub/linux/kernel/v5.x/sha256sums.asc
|
||||
sha256 e3d0025b87278e14733cb326700f17c7cceb54d920622b0d5fcd58a88c6850c3 linux-5.15.189.tar.xz
|
||||
sha256 8d88c3977226d666554b75f480d1e6c5f4e4d2acdf2a3462840c6bac88634d13 linux-5.10.240.tar.xz
|
||||
|
||||
@@ -2093,7 +2093,6 @@ menu "Networking"
|
||||
source "package/libnids/Config.in"
|
||||
source "package/libnl/Config.in"
|
||||
source "package/libnpupnp/Config.in"
|
||||
source "package/liboauth/Config.in"
|
||||
source "package/liboping/Config.in"
|
||||
source "package/libosip2/Config.in"
|
||||
source "package/libpagekite/Config.in"
|
||||
|
||||
@@ -0,0 +1,770 @@
|
||||
From 0cec0418dacd30f4215d0d778b4e5d23f6a93801 Mon Sep 17 00:00:00 2001
|
||||
From: Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
|
||||
Date: Tue, 3 Sep 2024 21:30:31 -0700
|
||||
Subject: [PATCH] Fix 32097 Warnings when building gprofng with Clang
|
||||
|
||||
gprofng/ChangeLog
|
||||
2024-09-03 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>.
|
||||
|
||||
PR gprofng/32097
|
||||
* common/hwcdrv.c: Fix -Wempty-body warnings.
|
||||
* common/hwcentry.h: Fix -Wdeprecated-non-prototype warnings.
|
||||
* common/hwctable.c: Fix -Wdeprecated-non-prototype warnings.
|
||||
* libcollector/collector.c: Likewise.
|
||||
* libcollector/collector.h: Likewise.
|
||||
* libcollector/collectorAPI.c: Likewise.
|
||||
* libcollector/dispatcher.c: Likewise.
|
||||
* libcollector/iotrace.c: Likewise.
|
||||
* libcollector/libcol_util.c: Fix -Wunused-but-set-variable warnings.
|
||||
* libcollector/libcol_util.h: Remove unused declarations.
|
||||
* libcollector/linetrace.c: Fix -Wdeprecated-non-prototype warnings.
|
||||
* src/BaseMetricTreeNode.h: Fix -Wunused-private-field warnings.
|
||||
* src/Dbe.cc: Fix -Wself-assign warnings.
|
||||
* src/DbeSession.cc: Fix -Wunused-but-set-variable warnings.
|
||||
* src/Disasm.cc: Fix -Wunused-const-variable warnings.
|
||||
* src/Experiment.cc: Fix -Wunused-private-field warnings.
|
||||
* src/HashMap.h: Fix -Wself-assign warnings.
|
||||
* src/IOActivity.h: Fix -Wunused-private-field warnings.
|
||||
* src/collctrl.cc: Fix -Wself-assign, -Wparentheses-equality warnings.
|
||||
* src/collctrl.h: Fix -Wunused-private-field warnings.
|
||||
* src/collector_module.h: Fix -Wdeprecated-non-prototype warnings.
|
||||
* src/gp-display-src.cc: Fix -Wunused-private-field warnings.
|
||||
* src/gp-print.h: Fix -Wheader-guard warnings.
|
||||
* src/hwc_intel_icelake.h: Fix -Winitializer-overrides warnings.
|
||||
* src/util.cc: Fix -Wunused-but-set-variable warnings.
|
||||
|
||||
Upstream: b79c457ca01df82dbe1facb708e45def4584c903
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
gprofng/common/hwcdrv.c | 3 ++-
|
||||
gprofng/common/hwcentry.h | 7 +----
|
||||
gprofng/common/hwctable.c | 13 +---------
|
||||
gprofng/libcollector/collector.c | 15 ++++-------
|
||||
gprofng/libcollector/collector.h | 2 +-
|
||||
gprofng/libcollector/collectorAPI.c | 15 ++++++-----
|
||||
gprofng/libcollector/dispatcher.c | 19 ++++++++------
|
||||
gprofng/libcollector/iotrace.c | 12 ++++-----
|
||||
gprofng/libcollector/libcol_util.c | 2 --
|
||||
gprofng/libcollector/libcol_util.h | 6 -----
|
||||
gprofng/libcollector/linetrace.c | 40 +++++++++++++++++------------
|
||||
gprofng/src/BaseMetricTreeNode.h | 1 -
|
||||
gprofng/src/Dbe.cc | 12 ++++-----
|
||||
gprofng/src/DbeSession.cc | 3 ---
|
||||
gprofng/src/Disasm.cc | 1 -
|
||||
gprofng/src/Experiment.cc | 2 --
|
||||
gprofng/src/HashMap.h | 3 +--
|
||||
gprofng/src/IOActivity.h | 1 -
|
||||
gprofng/src/collctrl.cc | 14 +++++-----
|
||||
gprofng/src/collector_module.h | 20 +++++++--------
|
||||
gprofng/src/gp-display-src.cc | 8 ------
|
||||
gprofng/src/gp-print.h | 2 +-
|
||||
gprofng/src/util.cc | 10 +++-----
|
||||
23 files changed, 84 insertions(+), 127 deletions(-)
|
||||
|
||||
diff --git a/gprofng/common/hwcdrv.c b/gprofng/common/hwcdrv.c
|
||||
index 2d549b0d6a5..fa1ad32430b 100644
|
||||
--- a/gprofng/common/hwcdrv.c
|
||||
+++ b/gprofng/common/hwcdrv.c
|
||||
@@ -650,6 +650,7 @@ read_sample (counter_state_t *ctr_state, int msgsz, uint64_t *rvalue,
|
||||
static void
|
||||
dump_perf_event_attr (struct perf_event_attr *at)
|
||||
{
|
||||
+#if defined(DEBUG)
|
||||
TprintfT (DBG_LT2, "dump_perf_event_attr: size=%d type=%d sample_period=%lld\n"
|
||||
" config=0x%llx config1=0x%llx config2=0x%llx wakeup_events=%lld __reserved_1=%lld\n",
|
||||
(int) at->size, (int) at->type, (unsigned long long) at->sample_period,
|
||||
@@ -665,13 +666,13 @@ dump_perf_event_attr (struct perf_event_attr *at)
|
||||
DUMP_F (exclude_kernel);
|
||||
DUMP_F (exclude_hv);
|
||||
DUMP_F (exclude_idle);
|
||||
- // DUMP_F(xmmap);
|
||||
DUMP_F (comm);
|
||||
DUMP_F (freq);
|
||||
DUMP_F (inherit_stat);
|
||||
DUMP_F (enable_on_exec);
|
||||
DUMP_F (task);
|
||||
DUMP_F (watermark);
|
||||
+#endif
|
||||
}
|
||||
|
||||
static void
|
||||
diff --git a/gprofng/common/hwcentry.h b/gprofng/common/hwcentry.h
|
||||
index a35a363e693..7899875cf96 100644
|
||||
--- a/gprofng/common/hwcentry.h
|
||||
+++ b/gprofng/common/hwcentry.h
|
||||
@@ -202,17 +202,12 @@ extern "C"
|
||||
extern char *hwc_get_docref (char *buf, size_t buflen);
|
||||
/* Return a CPU HWC document reference, or NULL. */
|
||||
|
||||
- // TBR
|
||||
- extern char *hwc_get_default_cntrs ();
|
||||
- /* Return a default HW counter string; may be NULL, or zero-length */
|
||||
- /* NULL means none is defined in the table; or zero-length means string defined could not be loaded */
|
||||
-
|
||||
extern char *hwc_get_default_cntrs2 (int forKernel, int style);
|
||||
/* like hwc_get_default_cntrs() for style==1 */
|
||||
/* but allows other styles of formatting as well */
|
||||
/* deprecate and eventually remove hwc_get_default_cntrs() */
|
||||
|
||||
- extern char *hwc_get_orig_default_cntrs ();
|
||||
+ extern char *hwc_get_orig_default_cntrs (int forKernel);
|
||||
/* Get the default HW counter string as set in the table */
|
||||
/* NULL means none is defined in the table */
|
||||
|
||||
diff --git a/gprofng/common/hwctable.c b/gprofng/common/hwctable.c
|
||||
index d0735132fac..fe9153190e7 100644
|
||||
--- a/gprofng/common/hwctable.c
|
||||
+++ b/gprofng/common/hwctable.c
|
||||
@@ -3231,7 +3231,7 @@ check_tables ()
|
||||
}
|
||||
#endif
|
||||
|
||||
-static int try_a_counter ();
|
||||
+static int try_a_counter (int forKernel);
|
||||
static void hwc_process_raw_ctrs (int forKernel, Hwcentry ***pstd_out,
|
||||
Hwcentry ***praw_out, Hwcentry ***phidden_out,
|
||||
Hwcentry**static_tables,
|
||||
@@ -4321,17 +4321,6 @@ hwc_get_docref (char *buf, size_t buflen)
|
||||
return buf;
|
||||
}
|
||||
|
||||
-//TBR:
|
||||
-
|
||||
-extern char*
|
||||
-hwc_get_default_cntrs ()
|
||||
-{
|
||||
- setup_cpcx ();
|
||||
- if (cpcx_default_hwcs[0] != NULL)
|
||||
- return strdup (cpcx_default_hwcs[0]); // TBR deprecate this
|
||||
- return NULL;
|
||||
-}
|
||||
-
|
||||
extern char*
|
||||
hwc_get_default_cntrs2 (int forKernel, int style)
|
||||
{
|
||||
diff --git a/gprofng/libcollector/collector.c b/gprofng/libcollector/collector.c
|
||||
index 39529758600..ef580dcbdd9 100644
|
||||
--- a/gprofng/libcollector/collector.c
|
||||
+++ b/gprofng/libcollector/collector.c
|
||||
@@ -210,15 +210,10 @@ get_collector_interface ()
|
||||
static void
|
||||
collector_module_init (CollectorInterface *col_intf)
|
||||
{
|
||||
- int nmodules = 0;
|
||||
-
|
||||
ModuleInitFunc next_init = (ModuleInitFunc) dlsym (RTLD_DEFAULT, "__collector_module_init");
|
||||
if (next_init != NULL)
|
||||
- {
|
||||
- nmodules++;
|
||||
- next_init (col_intf);
|
||||
- }
|
||||
- TprintfT (DBG_LT1, "collector_module_init: %d modules\n", nmodules);
|
||||
+ next_init (col_intf);
|
||||
+ TprintfT (DBG_LT1, "collector_module_init: %d modules\n", next_init ? 1 : 0);
|
||||
}
|
||||
|
||||
/* Routines concerned with general experiment start and stop */
|
||||
@@ -1784,7 +1779,7 @@ __collector_pause ()
|
||||
}
|
||||
|
||||
void
|
||||
-__collector_pause_m (char *reason)
|
||||
+__collector_pause_m (const char *reason)
|
||||
{
|
||||
hrtime_t now;
|
||||
char xreason[MAXPATHLEN];
|
||||
@@ -2451,8 +2446,8 @@ __collector_dlog (int tflag, int level, char *format, ...)
|
||||
|
||||
static void (*__real__exit) (int status) = NULL; /* libc only: _exit */
|
||||
static void (*__real__Exit) (int status) = NULL; /* libc only: _Exit */
|
||||
-void _exit () __attribute__ ((weak, alias ("__collector_exit")));
|
||||
-void _Exit () __attribute__ ((weak, alias ("__collector_Exit")));
|
||||
+void _exit (int status) __attribute__ ((weak, alias ("__collector_exit")));
|
||||
+void _Exit (int status) __attribute__ ((weak, alias ("__collector_Exit")));
|
||||
|
||||
void
|
||||
__collector_exit (int status)
|
||||
diff --git a/gprofng/libcollector/collector.h b/gprofng/libcollector/collector.h
|
||||
index 07a03bdd17a..eda68a0e4f5 100644
|
||||
--- a/gprofng/libcollector/collector.h
|
||||
+++ b/gprofng/libcollector/collector.h
|
||||
@@ -123,7 +123,7 @@ extern void __collector_terminate_expt ();
|
||||
extern void __collector_terminate_hook ();
|
||||
extern void __collector_sample (char *name);
|
||||
extern void __collector_pause ();
|
||||
-extern void __collector_pause_m ();
|
||||
+extern void __collector_pause_m (const char *reason);
|
||||
extern void __collector_resume ();
|
||||
extern int collector_sigemt_sigaction (const struct sigaction*,
|
||||
struct sigaction*);
|
||||
diff --git a/gprofng/libcollector/collectorAPI.c b/gprofng/libcollector/collectorAPI.c
|
||||
index 5fa6403ad49..449bbbaab65 100644
|
||||
--- a/gprofng/libcollector/collectorAPI.c
|
||||
+++ b/gprofng/libcollector/collectorAPI.c
|
||||
@@ -26,16 +26,17 @@
|
||||
#include "collectorAPI.h"
|
||||
#include "gp-experiment.h"
|
||||
|
||||
-static void *__real_collector_sample = NULL;
|
||||
-static void *__real_collector_pause = NULL;
|
||||
-static void *__real_collector_resume = NULL;
|
||||
-static void *__real_collector_terminate_expt = NULL;
|
||||
-static void *__real_collector_func_load = NULL;
|
||||
-static void *__real_collector_func_unload = NULL;
|
||||
+static void (*__real_collector_sample)(const char *) = NULL;
|
||||
+static void (*__real_collector_pause)() = NULL;
|
||||
+static void (*__real_collector_resume)() = NULL;
|
||||
+static void (*__real_collector_terminate_expt)() = NULL;
|
||||
+static void (*__real_collector_func_load)(const char *, const char *,
|
||||
+ const char *, void *, int, int, Lineno *) = NULL;
|
||||
+static void (*__real_collector_func_unload)(void *) = NULL;
|
||||
|
||||
#define INIT_API if (init_API == 0) collectorAPI_initAPI()
|
||||
#define NULL_PTR(x) (__real_##x == NULL)
|
||||
-#define CALL_REAL(x) (*(void(*)())__real_##x)
|
||||
+#define CALL_REAL(x) (__real_##x)
|
||||
#define CALL_IF_REAL(x) INIT_API; if (!NULL_PTR(x)) CALL_REAL(x)
|
||||
|
||||
static int init_API = 0;
|
||||
diff --git a/gprofng/libcollector/dispatcher.c b/gprofng/libcollector/dispatcher.c
|
||||
index d2a4ad0b60b..867753a22ec 100644
|
||||
--- a/gprofng/libcollector/dispatcher.c
|
||||
+++ b/gprofng/libcollector/dispatcher.c
|
||||
@@ -909,8 +909,9 @@ sigset (int sig, sighandler_t handler)
|
||||
|
||||
// map interposed symbol versions
|
||||
static int
|
||||
-gprofng_timer_create (int (real_func) (), clockid_t clockid,
|
||||
- struct sigevent *sevp, timer_t *timerid)
|
||||
+gprofng_timer_create (int (real_func) (clockid_t, struct sigevent *, timer_t *),
|
||||
+ clockid_t clockid,
|
||||
+ struct sigevent *sevp, timer_t *timerid)
|
||||
{
|
||||
// collector reserves SIGPROF
|
||||
if (sevp == NULL || sevp->sigev_notify != SIGEV_SIGNAL ||
|
||||
@@ -1045,7 +1046,7 @@ __collector_thr_sigsetmask (int how, const sigset_t* iset, sigset_t* oset)
|
||||
// map interposed symbol versions
|
||||
|
||||
static int
|
||||
-gprofng_pthread_sigmask (int (real_func) (),
|
||||
+gprofng_pthread_sigmask (int (real_func) (int, const sigset_t *, sigset_t*),
|
||||
int how, const sigset_t *iset, sigset_t* oset)
|
||||
{
|
||||
sigset_t lsigset;
|
||||
@@ -1140,9 +1141,10 @@ collector_root (void *cargs)
|
||||
// map interposed symbol versions
|
||||
|
||||
static int
|
||||
-gprofng_pthread_create (int (real_func) (), pthread_t *thread,
|
||||
- const pthread_attr_t *attr,
|
||||
- void *(*func)(void*), void *arg)
|
||||
+gprofng_pthread_create (int (real_func) (pthread_t *, const pthread_attr_t *,
|
||||
+ void *(*)(void *), void *),
|
||||
+ pthread_t *thread, const pthread_attr_t *attr,
|
||||
+ void *(*func)(void*), void *arg)
|
||||
{
|
||||
TprintfT (DBG_LTT, "gprofng_pthread_create @%p\n", real_func);
|
||||
if (dispatch_mode != DISPATCH_ON)
|
||||
@@ -1277,6 +1279,7 @@ __collector_ext_clone_pthread (int (*fn)(void *), void *child_stack, int flags,
|
||||
}
|
||||
|
||||
// weak symbols:
|
||||
-int sigprocmask () __attribute__ ((weak, alias ("__collector_sigprocmask")));
|
||||
-int thr_sigsetmask () __attribute__ ((weak, alias ("__collector_thr_sigsetmask")));
|
||||
+int sigprocmask (int, const sigset_t*, sigset_t*) __attribute__ ((weak, alias ("__collector_sigprocmask")));
|
||||
+int thr_sigsetmask (int, const sigset_t*, sigset_t*) __attribute__ ((weak, alias ("__collector_thr_sigsetmask")));
|
||||
int setitimer () __attribute__ ((weak, alias ("_setitimer")));
|
||||
+
|
||||
diff --git a/gprofng/libcollector/iotrace.c b/gprofng/libcollector/iotrace.c
|
||||
index 18060864796..3deb441d9c7 100644
|
||||
--- a/gprofng/libcollector/iotrace.c
|
||||
+++ b/gprofng/libcollector/iotrace.c
|
||||
@@ -1350,7 +1350,7 @@ mkstemp (char *template)
|
||||
unsigned pktSize;
|
||||
if (NULL_PTR (mkstemp))
|
||||
init_io_intf ();
|
||||
- if (CHCK_REENTRANCE (guard) || template == NULL)
|
||||
+ if (CHCK_REENTRANCE (guard))
|
||||
return CALL_REAL (mkstemp)(template);
|
||||
PUSH_REENTRANCE (guard);
|
||||
hrtime_t reqt = gethrtime ();
|
||||
@@ -1405,7 +1405,7 @@ mkstemps (char *template, int slen)
|
||||
unsigned pktSize;
|
||||
if (NULL_PTR (mkstemps))
|
||||
init_io_intf ();
|
||||
- if (CHCK_REENTRANCE (guard) || template == NULL)
|
||||
+ if (CHCK_REENTRANCE (guard))
|
||||
return CALL_REAL (mkstemps)(template, slen);
|
||||
PUSH_REENTRANCE (guard);
|
||||
hrtime_t reqt = gethrtime ();
|
||||
@@ -1485,7 +1485,7 @@ close (int fildes)
|
||||
|
||||
/*------------------------------------------------------------- fopen */
|
||||
static FILE*
|
||||
-gprofng_fopen (FILE*(real_fopen) (), const char *filename, const char *mode)
|
||||
+gprofng_fopen (FILE*(real_fopen) (const char *, const char *), const char *filename, const char *mode)
|
||||
{
|
||||
int *guard;
|
||||
FILE *fp = NULL;
|
||||
@@ -1559,7 +1559,7 @@ DCL_FOPEN (fopen)
|
||||
|
||||
/*------------------------------------------------------------- fclose */
|
||||
static int
|
||||
-gprofng_fclose (int(real_fclose) (), FILE *stream)
|
||||
+gprofng_fclose (int(real_fclose) (FILE *), FILE *stream)
|
||||
{
|
||||
int *guard;
|
||||
int stat;
|
||||
@@ -1645,7 +1645,7 @@ fflush (FILE *stream)
|
||||
|
||||
/*------------------------------------------------------------- fdopen */
|
||||
static FILE*
|
||||
-gprofng_fdopen (FILE*(real_fdopen) (), int fildes, const char *mode)
|
||||
+gprofng_fdopen (FILE*(real_fdopen) (int, const char *), int fildes, const char *mode)
|
||||
{
|
||||
int *guard;
|
||||
FILE *fp = NULL;
|
||||
@@ -2957,7 +2957,7 @@ DCL_FGETPOS (fgetpos)
|
||||
|
||||
/*------------------------------------------------------------- fgetpos64 */
|
||||
static int
|
||||
-gprofng_fgetpos64 (int(real_fgetpos64) (), FILE *stream, fpos64_t *pos)
|
||||
+gprofng_fgetpos64 (int(real_fgetpos64) (FILE *, fpos64_t *), FILE *stream, fpos64_t *pos)
|
||||
{
|
||||
int *guard;
|
||||
int ret;
|
||||
diff --git a/gprofng/libcollector/libcol_util.c b/gprofng/libcollector/libcol_util.c
|
||||
index 15ba24d2ab5..c2b82894e6b 100644
|
||||
--- a/gprofng/libcollector/libcol_util.c
|
||||
+++ b/gprofng/libcollector/libcol_util.c
|
||||
@@ -1013,7 +1013,6 @@ __collector_open (const char *path, int oflag, ...)
|
||||
mode_t mode = 0;
|
||||
|
||||
hrtime_t t_timeout = __collector_gethrtime () + 5 * ((hrtime_t) NANOSEC);
|
||||
- int nretries = 0;
|
||||
long long delay = 100; /* start at some small, arbitrary value */
|
||||
|
||||
/* get optional mode argument if it's expected/required */
|
||||
@@ -1058,7 +1057,6 @@ __collector_open (const char *path, int oflag, ...)
|
||||
delay *= 2;
|
||||
if (delay > 100000000)
|
||||
delay = 100000000; /* cap at some large, arbitrary value */
|
||||
- nretries++;
|
||||
}
|
||||
return fd;
|
||||
}
|
||||
diff --git a/gprofng/libcollector/libcol_util.h b/gprofng/libcollector/libcol_util.h
|
||||
index 2eeeaeed50b..1b1b928180a 100644
|
||||
--- a/gprofng/libcollector/libcol_util.h
|
||||
+++ b/gprofng/libcollector/libcol_util.h
|
||||
@@ -81,12 +81,6 @@ extern int __collector_mutex_trylock (collector_mutex_t *mp);
|
||||
#define __collector_mutex_init(xx) \
|
||||
do { collector_mutex_t tmp=COLLECTOR_MUTEX_INITIALIZER; *(xx)=tmp; } while(0)
|
||||
|
||||
-void __collector_sample (char *name);
|
||||
-void __collector_terminate_expt ();
|
||||
-void __collector_pause ();
|
||||
-void __collector_pause_m ();
|
||||
-void __collector_resume ();
|
||||
-
|
||||
struct DT_lineno;
|
||||
|
||||
typedef enum
|
||||
diff --git a/gprofng/libcollector/linetrace.c b/gprofng/libcollector/linetrace.c
|
||||
index 67b2d7e9030..66844bc1337 100644
|
||||
--- a/gprofng/libcollector/linetrace.c
|
||||
+++ b/gprofng/libcollector/linetrace.c
|
||||
@@ -1207,7 +1207,7 @@ __collector_vfork (void)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------- execve */
|
||||
-int execve () __attribute__ ((weak, alias ("__collector_execve")));
|
||||
+int execve (const char *, char *const [], char *const []) __attribute__ ((weak, alias ("__collector_execve")));
|
||||
|
||||
int
|
||||
__collector_execve (const char* path, char *const argv[], char *const envp[])
|
||||
@@ -1237,7 +1237,7 @@ __collector_execve (const char* path, char *const argv[], char *const envp[])
|
||||
return ret;
|
||||
}
|
||||
|
||||
-int execvp () __attribute__ ((weak, alias ("__collector_execvp")));
|
||||
+int execvp (const char *, char *const []) __attribute__ ((weak, alias ("__collector_execvp")));
|
||||
|
||||
int
|
||||
__collector_execvp (const char* file, char *const argv[])
|
||||
@@ -1269,7 +1269,7 @@ __collector_execvp (const char* file, char *const argv[])
|
||||
return ret;
|
||||
}
|
||||
|
||||
-int execv () __attribute__ ((weak, alias ("__collector_execv")));
|
||||
+int execv (const char *, char *const []) __attribute__ ((weak, alias ("__collector_execv")));
|
||||
|
||||
int
|
||||
__collector_execv (const char* path, char *const argv[])
|
||||
@@ -1408,7 +1408,10 @@ __collector_execl (const char* path, const char *arg0, ...)
|
||||
/*-------------------------------------------------------- posix_spawn */
|
||||
// map interposed symbol versions
|
||||
static int
|
||||
-gprofng_posix_spawn (int(real_posix_spawn) (),
|
||||
+gprofng_posix_spawn (int(real_posix_spawn) (pid_t *, const char *,
|
||||
+ const posix_spawn_file_actions_t *,
|
||||
+ const posix_spawnattr_t *,
|
||||
+ char *const [], char *const []),
|
||||
pid_t *pidp, const char *path,
|
||||
const posix_spawn_file_actions_t *file_actions,
|
||||
const posix_spawnattr_t *attrp,
|
||||
@@ -1466,7 +1469,10 @@ DCL_POSIX_SPAWN (posix_spawn)
|
||||
|
||||
/*-------------------------------------------------------- posix_spawnp */
|
||||
static int
|
||||
-gprofng_posix_spawnp (int (real_posix_spawnp) (),
|
||||
+gprofng_posix_spawnp (int (real_posix_spawnp) (pid_t *, const char *,
|
||||
+ const posix_spawn_file_actions_t *,
|
||||
+ const posix_spawnattr_t *,
|
||||
+ char *const [], char *const []),
|
||||
pid_t *pidp, const char *path,
|
||||
const posix_spawn_file_actions_t *file_actions,
|
||||
const posix_spawnattr_t *attrp,
|
||||
@@ -1754,8 +1760,8 @@ __collector_clone (int (*fn)(void *), void *child_stack, int flags, void *arg,
|
||||
}
|
||||
|
||||
/*-------------------------------------------------------------------- setuid */
|
||||
-int setuid () __attribute__ ((weak, alias ("__collector_setuid")));
|
||||
-int _setuid () __attribute__ ((weak, alias ("__collector_setuid")));
|
||||
+int setuid (uid_t) __attribute__ ((weak, alias ("__collector_setuid")));
|
||||
+int _setuid (uid_t) __attribute__ ((weak, alias ("__collector_setuid")));
|
||||
|
||||
int
|
||||
__collector_setuid (uid_t ruid)
|
||||
@@ -1770,8 +1776,8 @@ __collector_setuid (uid_t ruid)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------- seteuid */
|
||||
-int seteuid () __attribute__ ((weak, alias ("__collector_seteuid")));
|
||||
-int _seteuid () __attribute__ ((weak, alias ("__collector_seteuid")));
|
||||
+int seteuid (uid_t) __attribute__ ((weak, alias ("__collector_seteuid")));
|
||||
+int _seteuid (uid_t) __attribute__ ((weak, alias ("__collector_seteuid")));
|
||||
|
||||
int
|
||||
__collector_seteuid (uid_t euid)
|
||||
@@ -1786,8 +1792,8 @@ __collector_seteuid (uid_t euid)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------ setreuid */
|
||||
-int setreuid () __attribute__ ((weak, alias ("__collector_setreuid")));
|
||||
-int _setreuid () __attribute__ ((weak, alias ("__collector_setreuid")));
|
||||
+int setreuid (uid_t, uid_t) __attribute__ ((weak, alias ("__collector_setreuid")));
|
||||
+int _setreuid (uid_t, uid_t) __attribute__ ((weak, alias ("__collector_setreuid")));
|
||||
|
||||
int
|
||||
__collector_setreuid (uid_t ruid, uid_t euid)
|
||||
@@ -1802,8 +1808,8 @@ __collector_setreuid (uid_t ruid, uid_t euid)
|
||||
}
|
||||
|
||||
/*-------------------------------------------------------------------- setgid */
|
||||
-int setgid () __attribute__ ((weak, alias ("__collector_setgid")));
|
||||
-int _setgid () __attribute__ ((weak, alias ("__collector_setgid")));
|
||||
+int setgid (gid_t) __attribute__ ((weak, alias ("__collector_setgid")));
|
||||
+int _setgid (gid_t) __attribute__ ((weak, alias ("__collector_setgid")));
|
||||
|
||||
int
|
||||
__collector_setgid (gid_t rgid)
|
||||
@@ -1818,8 +1824,8 @@ __collector_setgid (gid_t rgid)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------- setegid */
|
||||
-int setegid () __attribute__ ((weak, alias ("__collector_setegid")));
|
||||
-int _setegid () __attribute__ ((weak, alias ("__collector_setegid")));
|
||||
+int setegid (gid_t) __attribute__ ((weak, alias ("__collector_setegid")));
|
||||
+int _setegid (gid_t) __attribute__ ((weak, alias ("__collector_setegid")));
|
||||
|
||||
int
|
||||
__collector_setegid (gid_t egid)
|
||||
@@ -1834,8 +1840,8 @@ __collector_setegid (gid_t egid)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------ setregid */
|
||||
-int setregid () __attribute__ ((weak, alias ("__collector_setregid")));
|
||||
-int _setregid () __attribute__ ((weak, alias ("__collector_setregid")));
|
||||
+int setregid (gid_t, gid_t) __attribute__ ((weak, alias ("__collector_setregid")));
|
||||
+int _setregid (gid_t, gid_t) __attribute__ ((weak, alias ("__collector_setregid")));
|
||||
|
||||
int
|
||||
__collector_setregid (gid_t rgid, gid_t egid)
|
||||
diff --git a/gprofng/src/BaseMetricTreeNode.h b/gprofng/src/BaseMetricTreeNode.h
|
||||
index d73d244e27e..7698f9c6eaf 100644
|
||||
--- a/gprofng/src/BaseMetricTreeNode.h
|
||||
+++ b/gprofng/src/BaseMetricTreeNode.h
|
||||
@@ -85,7 +85,6 @@ private:
|
||||
|
||||
BaseMetricTreeNode *root; // root of tree
|
||||
BaseMetricTreeNode *parent; // my parent
|
||||
- bool aggregation; // value is based on children's values
|
||||
char *name; // bm->get_cmd() for metrics, unique string otherwise
|
||||
char *uname; // user-visible text
|
||||
char *unit; // see UNIT_* defines
|
||||
diff --git a/gprofng/src/Dbe.cc b/gprofng/src/Dbe.cc
|
||||
index 91a5aa5ef05..bcbf4694565 100644
|
||||
--- a/gprofng/src/Dbe.cc
|
||||
+++ b/gprofng/src/Dbe.cc
|
||||
@@ -9594,14 +9594,12 @@ dbeGetTLDataRepVals (VMode view_mode, hrtime_t start_ts, hrtime_t delta,
|
||||
}
|
||||
if (sampleVals != NULL)
|
||||
{
|
||||
- Sample* sample = (Sample*) packets->getObjValue (PROP_SMPLOBJ, packetIdx);
|
||||
- if (!sample || !sample->get_usage ())
|
||||
- sample = sample;
|
||||
- else
|
||||
+ Sample *sample = (Sample*) packets->getObjValue (PROP_SMPLOBJ, packetIdx);
|
||||
+ if (sample != NULL)
|
||||
{
|
||||
- PrUsage* prusage = sample->get_usage ();
|
||||
- Vector<long long> *mstateVals = prusage->getMstateValues ();
|
||||
- sampleVals->store (eventIdx, mstateVals);
|
||||
+ PrUsage *prusage = sample->get_usage ();
|
||||
+ if (prusage != NULL)
|
||||
+ sampleVals->store (eventIdx, prusage->getMstateValues ());
|
||||
}
|
||||
}
|
||||
}
|
||||
diff --git a/gprofng/src/DbeSession.cc b/gprofng/src/DbeSession.cc
|
||||
index 20329091167..5d6bab75638 100644
|
||||
--- a/gprofng/src/DbeSession.cc
|
||||
+++ b/gprofng/src/DbeSession.cc
|
||||
@@ -1162,8 +1162,6 @@ DbeSession::open_experiment (Experiment *exp, char *path)
|
||||
closedir (exp_dir);
|
||||
exp_names->sort (dir_name_cmp);
|
||||
Experiment **t_exp_list = new Experiment *[exp_names->size ()];
|
||||
- int nsubexps = 0;
|
||||
-
|
||||
for (int j = 0, jsz = exp_names->size (); j < jsz; j++)
|
||||
{
|
||||
t_exp_list[j] = NULL;
|
||||
@@ -1220,7 +1218,6 @@ DbeSession::open_experiment (Experiment *exp, char *path)
|
||||
dexp->open (dpath);
|
||||
append (dexp);
|
||||
t_exp_list[j] = dexp;
|
||||
- nsubexps++;
|
||||
dexp->set_clock (exp->clock);
|
||||
|
||||
// DbeView add_experiment() is split into two parts
|
||||
diff --git a/gprofng/src/Disasm.cc b/gprofng/src/Disasm.cc
|
||||
index 1396e4fb072..d78212cee39 100644
|
||||
--- a/gprofng/src/Disasm.cc
|
||||
+++ b/gprofng/src/Disasm.cc
|
||||
@@ -49,7 +49,6 @@ struct DisContext
|
||||
};
|
||||
|
||||
static const int MAX_DISASM_STR = 2048;
|
||||
-static const int MAX_INSTR_SIZE = 8;
|
||||
|
||||
Disasm::Disasm (char *fname)
|
||||
{
|
||||
diff --git a/gprofng/src/Experiment.cc b/gprofng/src/Experiment.cc
|
||||
index 02a24ebc40d..a31550aff66 100644
|
||||
--- a/gprofng/src/Experiment.cc
|
||||
+++ b/gprofng/src/Experiment.cc
|
||||
@@ -1935,8 +1935,6 @@ private:
|
||||
}
|
||||
|
||||
Experiment *exp;
|
||||
- char *hostname;
|
||||
- hrtime_t time, tstamp;
|
||||
};
|
||||
|
||||
void
|
||||
diff --git a/gprofng/src/HashMap.h b/gprofng/src/HashMap.h
|
||||
index 918c0dc95f9..c5fdd345ba8 100644
|
||||
--- a/gprofng/src/HashMap.h
|
||||
+++ b/gprofng/src/HashMap.h
|
||||
@@ -78,9 +78,8 @@ copy_key (uint64_t a)
|
||||
}
|
||||
|
||||
template<> inline void
|
||||
-delete_key (uint64_t a)
|
||||
+delete_key (uint64_t)
|
||||
{
|
||||
- a = a;
|
||||
}
|
||||
|
||||
template<> inline int
|
||||
diff --git a/gprofng/src/IOActivity.h b/gprofng/src/IOActivity.h
|
||||
index cf462cf8d55..f3a22ada6b1 100644
|
||||
--- a/gprofng/src/IOActivity.h
|
||||
+++ b/gprofng/src/IOActivity.h
|
||||
@@ -78,7 +78,6 @@ private:
|
||||
Hist_data *hist_data_file_all;
|
||||
Hist_data *hist_data_vfd_all;
|
||||
Hist_data *hist_data_callstack_all;
|
||||
- Hist_data *hist_data_callstack;
|
||||
|
||||
DbeView *dbev;
|
||||
};
|
||||
diff --git a/gprofng/src/collctrl.cc b/gprofng/src/collctrl.cc
|
||||
index ebf888c5a20..b0ed66efcdc 100644
|
||||
--- a/gprofng/src/collctrl.cc
|
||||
+++ b/gprofng/src/collctrl.cc
|
||||
@@ -952,9 +952,7 @@ Coll_Ctrl::set_clkprof (const char *string, char** warn)
|
||||
double dval = strtod (string, &endchar);
|
||||
if (*endchar == 'm' || *endchar == 0) /* user specified milliseconds */
|
||||
dval = dval * 1000.;
|
||||
- else if (*endchar == 'u') /* user specified microseconds */
|
||||
- dval = dval;
|
||||
- else
|
||||
+ else if (*endchar != 'u')
|
||||
return dbe_sprintf (GTXT ("Unrecognized clock-profiling interval `%s'\n"), string);
|
||||
nclkprof_timer = (int) (dval + 0.5);
|
||||
}
|
||||
@@ -2901,7 +2899,7 @@ Coll_Ctrl::get (char * control)
|
||||
}
|
||||
if (!strncmp (control, ipc_str_javaprof, len))
|
||||
{
|
||||
- if ((java_mode == 0))
|
||||
+ if (java_mode == 0)
|
||||
return strdup (ipc_str_off);
|
||||
return strdup (ipc_str_on);
|
||||
}
|
||||
@@ -2917,7 +2915,7 @@ Coll_Ctrl::get (char * control)
|
||||
}
|
||||
if (!strncmp (control, ipc_str_sample_sig, len))
|
||||
{
|
||||
- if ((sample_sig == 0))
|
||||
+ if (sample_sig == 0)
|
||||
return strdup (ipc_str_off);
|
||||
char *str_signal = find_signal_name (sample_sig);
|
||||
if (str_signal != NULL)
|
||||
@@ -2951,15 +2949,15 @@ Coll_Ctrl::get (char * control)
|
||||
}
|
||||
if (!strncmp (control, ipc_str_iotrace, len))
|
||||
{
|
||||
- if ((iotrace_enabled == 0))
|
||||
+ if (iotrace_enabled == 0)
|
||||
return strdup (ipc_str_off);
|
||||
return strdup (ipc_str_on);
|
||||
}
|
||||
if (!strncmp (control, ipc_str_count, len))
|
||||
{
|
||||
- if ((count_enabled == 0))
|
||||
+ if (count_enabled == 0)
|
||||
return strdup (ipc_str_off);
|
||||
- if ((count_enabled < 0))
|
||||
+ if (count_enabled < 0)
|
||||
return strdup ("on\nstatic");
|
||||
return strdup (ipc_str_on);
|
||||
}
|
||||
diff --git a/gprofng/src/collector_module.h b/gprofng/src/collector_module.h
|
||||
index bb48eadb9f8..ebcdbca561f 100644
|
||||
--- a/gprofng/src/collector_module.h
|
||||
+++ b/gprofng/src/collector_module.h
|
||||
@@ -40,12 +40,12 @@ struct tm;
|
||||
* If you add any, please put it in the right place */
|
||||
typedef struct CollectorUtilFuncs
|
||||
{
|
||||
- int (*access)();
|
||||
+ int (*access)(const char *, int);
|
||||
int (*atoi)(const char *nptr);
|
||||
void *(*calloc)(size_t nelem, size_t elsize);
|
||||
int (*clearenv)(void);
|
||||
int (*close)(int);
|
||||
- int (*closedir)();
|
||||
+ int (*closedir)(DIR *);
|
||||
int (*execv)(const char *path, char *const argv[]);
|
||||
void (*exit)(int status);
|
||||
int (*fclose)(FILE *stream);
|
||||
@@ -66,20 +66,20 @@ typedef struct CollectorUtilFuncs
|
||||
off_t (*lseek)(int fd, off_t offset, int whence);
|
||||
void *(*malloc)(size_t size);
|
||||
void *(*memset)(void *s1, int c, size_t n);
|
||||
- int (*mkdir)();
|
||||
+ int (*mkdir)(const char *, mode_t);
|
||||
time_t (*mktime)(struct tm *timeptr);
|
||||
void *(*mmap)(void *, size_t, int, int, int, off_t);
|
||||
- void *(*mmap64_)();
|
||||
- int (*munmap)();
|
||||
+ void *(*mmap64_)(void *, size_t, int, int, int, off_t);
|
||||
+ int (*munmap)(void *, size_t);
|
||||
int (*open)(const char *, int, ...);
|
||||
int (*open_bare)(const char *, int, ...);
|
||||
- DIR *(*opendir)();
|
||||
+ DIR *(*opendir)(const char *);
|
||||
int (*pclose)(FILE *stream);
|
||||
FILE *(*popen)(const char *command, const char *mode);
|
||||
int (*putenv)(char *string);
|
||||
- ssize_t (*pwrite)();
|
||||
- ssize_t (*pwrite64_)();
|
||||
- ssize_t (*read)();
|
||||
+ ssize_t (*pwrite)(int, const void *, size_t, off_t);
|
||||
+ ssize_t (*pwrite64_)(int, const void *, size_t, off_t);
|
||||
+ ssize_t (*read)(int, void *, size_t);
|
||||
int (*setenv)(const char *name, const char *value, int overwrite);
|
||||
int (*sigfillset)(sigset_t *set);
|
||||
int (*sigprocmask)(int how, const sigset_t *set, sigset_t *oldset);
|
||||
@@ -112,7 +112,7 @@ typedef struct CollectorUtilFuncs
|
||||
int (*unsetenv)(const char *name);
|
||||
int (*vsnprintf)(char *str, size_t size, const char *format, va_list ap);
|
||||
pid_t (*waitpid)(pid_t pid, int *stat_loc, int options);
|
||||
- ssize_t (*write)();
|
||||
+ ssize_t (*write)(int, void *, size_t);
|
||||
double (*atof)();
|
||||
void *n_a;
|
||||
} CollectorUtilFuncs;
|
||||
diff --git a/gprofng/src/gp-display-src.cc b/gprofng/src/gp-display-src.cc
|
||||
index 200e6080d2e..24af375edf1 100644
|
||||
--- a/gprofng/src/gp-display-src.cc
|
||||
+++ b/gprofng/src/gp-display-src.cc
|
||||
@@ -75,14 +75,6 @@ private:
|
||||
bool v_opt;
|
||||
int multiple;
|
||||
char *str_compcom;
|
||||
- bool hex_visible;
|
||||
- int src_visible;
|
||||
- int vis_src;
|
||||
- int vis_dis;
|
||||
- int threshold_src;
|
||||
- int threshold_dis;
|
||||
- int threshold;
|
||||
- int vis_bits;
|
||||
};
|
||||
|
||||
static int
|
||||
diff --git a/gprofng/src/gp-print.h b/gprofng/src/gp-print.h
|
||||
index 1b748ea60a3..1a8ad3b6c13 100644
|
||||
--- a/gprofng/src/gp-print.h
|
||||
+++ b/gprofng/src/gp-print.h
|
||||
@@ -19,7 +19,7 @@
|
||||
MA 02110-1301, USA. */
|
||||
|
||||
#ifndef _GP_PRINT_H
|
||||
-#define _ER_PRINT_H
|
||||
+#define _GP_PRINT_H
|
||||
|
||||
#include "Command.h"
|
||||
#include "DbeApplication.h"
|
||||
diff --git a/gprofng/src/util.cc b/gprofng/src/util.cc
|
||||
index 201f7088b66..228140b61ae 100644
|
||||
--- a/gprofng/src/util.cc
|
||||
+++ b/gprofng/src/util.cc
|
||||
@@ -741,17 +741,13 @@ get_relative_link (const char *path_from, const char *path_to)
|
||||
s2 = canonical_path (s2);
|
||||
long l = dbe_sstrlen (s1);
|
||||
// try to find common directories
|
||||
- int common_slashes = 0;
|
||||
int last_common_slash = -1;
|
||||
for (int i = 0; i < l; i++)
|
||||
{
|
||||
- if (s1[i] != s2[i]) break;
|
||||
- if (s1[i] == 0) break;
|
||||
+ if (s1[i] != s2[i] || s1[i] == 0)
|
||||
+ break;
|
||||
if (s1[i] == '/')
|
||||
- {
|
||||
- common_slashes++;
|
||||
- last_common_slash = i;
|
||||
- }
|
||||
+ last_common_slash = i;
|
||||
}
|
||||
// find slashes in remaining path_to
|
||||
int slashes = 0;
|
||||
--
|
||||
2.50.1
|
||||
|
||||
+619
@@ -0,0 +1,619 @@
|
||||
From 2e59be3bc9dad69af4f62d26107b6ace23e9998a Mon Sep 17 00:00:00 2001
|
||||
From: Sam James <sam@gentoo.org>
|
||||
Date: Sat, 16 Nov 2024 05:13:48 +0000
|
||||
Subject: [PATCH] gprofng: fix -std=gnu23 compatibility wrt unprototyped
|
||||
functions
|
||||
|
||||
C23 removes support for unprototyped functions. Fix function pointer types
|
||||
accordingly.
|
||||
|
||||
This does not fix all instances, there's a few left as I commented on in
|
||||
PR32374 (e.g. setitimer which I have a local workaround for but it involves
|
||||
a glibc implementation detail; the Linaro precommit CI tester pointed that
|
||||
out too, so dropped that).
|
||||
|
||||
ChangeLog:
|
||||
PR gprofng/32374
|
||||
|
||||
* libcollector/collector.c (collector_sample): Fix prototype.
|
||||
* libcollector/envmgmt.c (putenv): Ditto.
|
||||
(_putenv): Ditto.
|
||||
(__collector_putenv): Ditto.
|
||||
(setenv): Ditto.
|
||||
(_setenv): Ditto.
|
||||
(__collector_setenv): Ditto.
|
||||
(unsetenv): Ditto.
|
||||
(_unsetenv): Ditto.
|
||||
(__collector_unsetenv): Ditto.
|
||||
* libcollector/jprofile.c (open_experiment): Ditto.
|
||||
(__collector_jprofile_enable_synctrace): Ditto.
|
||||
(jprof_find_asyncgetcalltrace): Ditto.
|
||||
* libcollector/libcol_util.c (__collector_util_init): Ditto.
|
||||
(ARCH): Ditto.
|
||||
* libcollector/mmaptrace.c (collector_func_load): Ditto.
|
||||
(collector_func_unload): Ditto.
|
||||
* libcollector/unwind.c (__collector_ext_unwind_init): Ditto.
|
||||
* src/collector_module.h: Ditto.
|
||||
|
||||
Upstream: a2f774427e078f3da2c06bdea25f77a61979a695
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
gprofng/libcollector/collector.c | 2 +-
|
||||
gprofng/libcollector/dispatcher.c | 1 -
|
||||
gprofng/libcollector/envmgmt.c | 24 ++++-----
|
||||
gprofng/libcollector/jprofile.c | 10 ++--
|
||||
gprofng/libcollector/libcol_util.c | 84 +++++++++++++++---------------
|
||||
gprofng/libcollector/mmaptrace.c | 4 +-
|
||||
gprofng/libcollector/unwind.c | 2 +-
|
||||
gprofng/src/collector_module.h | 2 +-
|
||||
8 files changed, 64 insertions(+), 65 deletions(-)
|
||||
|
||||
diff --git a/gprofng/libcollector/collector.c b/gprofng/libcollector/collector.c
|
||||
index ef580dcbdd9..899f08a5381 100644
|
||||
--- a/gprofng/libcollector/collector.c
|
||||
+++ b/gprofng/libcollector/collector.c
|
||||
@@ -1579,7 +1579,7 @@ __collector_resume_experiment ()
|
||||
}
|
||||
|
||||
/* Code to support Samples and Pause/Resume */
|
||||
-void collector_sample () __attribute__ ((weak, alias ("__collector_sample")));
|
||||
+void collector_sample (char *name) __attribute__ ((weak, alias ("__collector_sample")));
|
||||
void
|
||||
__collector_sample (char *name)
|
||||
{
|
||||
diff --git a/gprofng/libcollector/dispatcher.c b/gprofng/libcollector/dispatcher.c
|
||||
index 867753a22ec..5ee0bf895bf 100644
|
||||
--- a/gprofng/libcollector/dispatcher.c
|
||||
+++ b/gprofng/libcollector/dispatcher.c
|
||||
@@ -1282,4 +1282,3 @@ __collector_ext_clone_pthread (int (*fn)(void *), void *child_stack, int flags,
|
||||
int sigprocmask (int, const sigset_t*, sigset_t*) __attribute__ ((weak, alias ("__collector_sigprocmask")));
|
||||
int thr_sigsetmask (int, const sigset_t*, sigset_t*) __attribute__ ((weak, alias ("__collector_thr_sigsetmask")));
|
||||
int setitimer () __attribute__ ((weak, alias ("_setitimer")));
|
||||
-
|
||||
diff --git a/gprofng/libcollector/envmgmt.c b/gprofng/libcollector/envmgmt.c
|
||||
index ebe08f82007..0ff7621070d 100644
|
||||
--- a/gprofng/libcollector/envmgmt.c
|
||||
+++ b/gprofng/libcollector/envmgmt.c
|
||||
@@ -692,8 +692,8 @@ __collector_env_update (char *envp[])
|
||||
|
||||
|
||||
/*------------------------------------------------------------- putenv */
|
||||
-int putenv () __attribute__ ((weak, alias ("__collector_putenv")));
|
||||
-int _putenv () __attribute__ ((weak, alias ("__collector_putenv")));
|
||||
+int putenv (char*) __attribute__ ((weak, alias ("__collector_putenv")));
|
||||
+int _putenv (char*) __attribute__ ((weak, alias ("__collector_putenv")));
|
||||
|
||||
int
|
||||
__collector_putenv (char * string)
|
||||
@@ -701,9 +701,9 @@ __collector_putenv (char * string)
|
||||
if (CALL_UTIL (putenv) == __collector_putenv ||
|
||||
CALL_UTIL (putenv) == NULL)
|
||||
{ // __collector_libc_funcs_init failed
|
||||
- CALL_UTIL (putenv) = (int(*)())dlsym (RTLD_NEXT, "putenv");
|
||||
+ CALL_UTIL (putenv) = (int(*)(char*))dlsym (RTLD_NEXT, "putenv");
|
||||
if (CALL_UTIL (putenv) == NULL || CALL_UTIL (putenv) == __collector_putenv)
|
||||
- CALL_UTIL (putenv) = (int(*)())dlsym (RTLD_DEFAULT, "putenv");
|
||||
+ CALL_UTIL (putenv) = (int(*)(char*))dlsym (RTLD_DEFAULT, "putenv");
|
||||
if (CALL_UTIL (putenv) == NULL || CALL_UTIL (putenv) == __collector_putenv)
|
||||
{
|
||||
TprintfT (DBG_LT2, "__collector_putenv(): ERROR: no pointer found.\n");
|
||||
@@ -719,8 +719,8 @@ __collector_putenv (char * string)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------- setenv */
|
||||
-int setenv () __attribute__ ((weak, alias ("__collector_setenv")));
|
||||
-int _setenv () __attribute__ ((weak, alias ("__collector_setenv")));
|
||||
+int setenv (const char*, const char*, int) __attribute__ ((weak, alias ("__collector_setenv")));
|
||||
+int _setenv (const char*, const char*, int) __attribute__ ((weak, alias ("__collector_setenv")));
|
||||
|
||||
int
|
||||
__collector_setenv (const char *name, const char *value, int overwrite)
|
||||
@@ -728,9 +728,9 @@ __collector_setenv (const char *name, const char *value, int overwrite)
|
||||
if (CALL_UTIL (setenv) == __collector_setenv ||
|
||||
CALL_UTIL (setenv) == NULL)
|
||||
{ // __collector_libc_funcs_init failed
|
||||
- CALL_UTIL (setenv) = (int(*)())dlsym (RTLD_NEXT, "setenv");
|
||||
+ CALL_UTIL (setenv) = (int(*)(const char*, const char*, int))dlsym (RTLD_NEXT, "setenv");
|
||||
if (CALL_UTIL (setenv) == NULL || CALL_UTIL (setenv) == __collector_setenv)
|
||||
- CALL_UTIL (setenv) = (int(*)())dlsym (RTLD_DEFAULT, "setenv");
|
||||
+ CALL_UTIL (setenv) = (int(*)(const char*, const char*, int))dlsym (RTLD_DEFAULT, "setenv");
|
||||
if (CALL_UTIL (setenv) == NULL || CALL_UTIL (setenv) == __collector_setenv)
|
||||
{
|
||||
TprintfT (DBG_LT2, "__collector_setenv(): ERROR: no pointer found.\n");
|
||||
@@ -765,8 +765,8 @@ __collector_setenv (const char *name, const char *value, int overwrite)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------- unsetenv */
|
||||
-int unsetenv () __attribute__ ((weak, alias ("__collector_unsetenv")));
|
||||
-int _unsetenv () __attribute__ ((weak, alias ("__collector_unsetenv")));
|
||||
+int unsetenv (const char*) __attribute__ ((weak, alias ("__collector_unsetenv")));
|
||||
+int _unsetenv (const char*) __attribute__ ((weak, alias ("__collector_unsetenv")));
|
||||
|
||||
int
|
||||
__collector_unsetenv (const char *name)
|
||||
@@ -774,9 +774,9 @@ __collector_unsetenv (const char *name)
|
||||
if (CALL_UTIL (unsetenv) == __collector_unsetenv ||
|
||||
CALL_UTIL (unsetenv) == NULL)
|
||||
{ // __collector_libc_funcs_init failed
|
||||
- CALL_UTIL (unsetenv) = (int(*)())dlsym (RTLD_NEXT, "unsetenv");
|
||||
+ CALL_UTIL (unsetenv) = (int(*)(const char*))dlsym (RTLD_NEXT, "unsetenv");
|
||||
if (CALL_UTIL (unsetenv) == NULL || CALL_UTIL (unsetenv) == __collector_unsetenv)
|
||||
- CALL_UTIL (unsetenv) = (int(*)())dlsym (RTLD_DEFAULT, "unsetenv");
|
||||
+ CALL_UTIL (unsetenv) = (int(*)(const char*))dlsym (RTLD_DEFAULT, "unsetenv");
|
||||
if (CALL_UTIL (unsetenv) == NULL || CALL_UTIL (unsetenv) == __collector_unsetenv)
|
||||
{
|
||||
TprintfT (DBG_LT2, "__collector_unsetenv(): ERROR: no pointer found.\n");
|
||||
diff --git a/gprofng/libcollector/jprofile.c b/gprofng/libcollector/jprofile.c
|
||||
index 1bacacc1a2a..11051f937ef 100644
|
||||
--- a/gprofng/libcollector/jprofile.c
|
||||
+++ b/gprofng/libcollector/jprofile.c
|
||||
@@ -105,8 +105,8 @@ static void rwrite (int fd, const void *buf, size_t nbyte);
|
||||
static void addToDynamicArchive (const char* name, const unsigned char* class_data, int class_data_len);
|
||||
static void (*AsyncGetCallTrace)(JVMPI_CallTrace*, jint, ucontext_t*) = NULL;
|
||||
static void (*collector_heap_record)(int, int, void*) = NULL;
|
||||
-static void (*collector_jsync_begin)() = NULL;
|
||||
-static void (*collector_jsync_end)(hrtime_t, void *) = NULL;
|
||||
+static void (*collector_jsync_begin)(void) = NULL;
|
||||
+static void (*collector_jsync_end)(hrtime_t, void*) = NULL;
|
||||
|
||||
#define gethrtime collector_interface->getHiResTime
|
||||
|
||||
@@ -230,7 +230,7 @@ open_experiment (const char *exp)
|
||||
else if (__collector_strStartWith (args, "s:") == 0)
|
||||
{
|
||||
java_sync_mode = 1;
|
||||
- collector_jsync_begin = (void(*)(hrtime_t, void *))dlsym (RTLD_DEFAULT, "__collector_jsync_begin");
|
||||
+ collector_jsync_begin = (void(*)(void))dlsym (RTLD_DEFAULT, "__collector_jsync_begin");
|
||||
collector_jsync_end = (void(*)(hrtime_t, void *))dlsym (RTLD_DEFAULT, "__collector_jsync_end");
|
||||
}
|
||||
#endif
|
||||
@@ -255,7 +255,7 @@ __collector_jprofile_enable_synctrace ()
|
||||
return;
|
||||
}
|
||||
java_sync_mode = 1;
|
||||
- collector_jsync_begin = (void(*)(hrtime_t, void *))dlsym (RTLD_DEFAULT, "__collector_jsync_begin");
|
||||
+ collector_jsync_begin = (void(*)(void))dlsym (RTLD_DEFAULT, "__collector_jsync_begin");
|
||||
collector_jsync_end = (void(*)(hrtime_t, void *))dlsym (RTLD_DEFAULT, "__collector_jsync_end");
|
||||
TprintfT (DBG_LT1, "jprofile: turning on Java synctrace, and requesting events\n");
|
||||
}
|
||||
@@ -1129,7 +1129,7 @@ jprof_find_asyncgetcalltrace ()
|
||||
{
|
||||
void *jvmhandle;
|
||||
if (__collector_VM_ReadByteInstruction == NULL)
|
||||
- __collector_VM_ReadByteInstruction = (int(*)()) dlsym (RTLD_DEFAULT, "Async_VM_ReadByteInstruction");
|
||||
+ __collector_VM_ReadByteInstruction = (int(*)(unsigned char*)) dlsym (RTLD_DEFAULT, "Async_VM_ReadByteInstruction");
|
||||
|
||||
/* look for stack unwind function using default path */
|
||||
AsyncGetCallTrace = (void (*)(JVMPI_CallTrace*, jint, ucontext_t*))
|
||||
diff --git a/gprofng/libcollector/libcol_util.c b/gprofng/libcollector/libcol_util.c
|
||||
index c2b82894e6b..688bdf19c6d 100644
|
||||
--- a/gprofng/libcollector/libcol_util.c
|
||||
+++ b/gprofng/libcollector/libcol_util.c
|
||||
@@ -1114,7 +1114,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "munmap");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.munmap = (int(*)())ptr;
|
||||
+ __collector_util_funcs.munmap = (int(*)(void *, size_t))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT munmap: %s\n", dlerror ());
|
||||
@@ -1123,7 +1123,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "close");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.close = (int(*)())ptr;
|
||||
+ __collector_util_funcs.close = (int(*)(int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT close: %s\n", dlerror ());
|
||||
@@ -1158,7 +1158,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "close");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.close = (int(*)())ptr;
|
||||
+ __collector_util_funcs.close = (int(*)(int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT close: %s\n", dlerror ());
|
||||
@@ -1167,7 +1167,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "read");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.read = (ssize_t (*)())ptr;
|
||||
+ __collector_util_funcs.read = (ssize_t (*)(int, void*, size_t))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT read: %s\n", dlerror ());
|
||||
@@ -1176,7 +1176,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "write");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.write = (ssize_t (*)())ptr;
|
||||
+ __collector_util_funcs.write = (ssize_t (*)(int, void*, size_t))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT write: %s\n", dlerror ());
|
||||
@@ -1186,14 +1186,14 @@ __collector_util_init ()
|
||||
#if ARCH(Intel) && WSIZE(32)
|
||||
ptr = dlvsym (libc, "pwrite", "GLIBC_2.2"); // it is in /lib/libpthread.so.0
|
||||
if (ptr)
|
||||
- __collector_util_funcs.pwrite = (ssize_t (*)())ptr;
|
||||
+ __collector_util_funcs.pwrite = (ssize_t (*)(int, void*, size_t, off_t))ptr;
|
||||
else
|
||||
{
|
||||
Tprintf (DBG_LT0, "libcol_util: WARNING: dlvsym for %s@%s failed. Using dlsym() instead.", "pwrite", "GLIBC_2.2");
|
||||
#endif /* ARCH(Intel) && WSIZE(32) */
|
||||
ptr = dlsym (libc, "pwrite");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.pwrite = (ssize_t (*)())ptr;
|
||||
+ __collector_util_funcs.pwrite = (ssize_t (*)(int, const void*, size_t, off_t))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT pwrite: %s\n", dlerror ());
|
||||
@@ -1213,7 +1213,7 @@ __collector_util_init ()
|
||||
#endif /* ARCH(Intel) && WSIZE(32) */
|
||||
ptr = dlsym (libc, "pwrite64");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.pwrite64_ = (ssize_t (*)())ptr;
|
||||
+ __collector_util_funcs.pwrite64_ = (ssize_t (*)(int, const void*, size_t, off_t))ptr;
|
||||
else
|
||||
__collector_util_funcs.pwrite64_ = __collector_util_funcs.pwrite;
|
||||
#if ARCH(Intel) && WSIZE(32)
|
||||
@@ -1222,7 +1222,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "lseek");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.lseek = (off_t (*)())ptr;
|
||||
+ __collector_util_funcs.lseek = (off_t (*)(int, off_t, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT lseek: %s\n", dlerror ());
|
||||
@@ -1231,7 +1231,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "access");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.access = (int(*)())ptr;
|
||||
+ __collector_util_funcs.access = (int(*)(const char*, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT access: %s\n", dlerror ());
|
||||
@@ -1240,7 +1240,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "mkdir");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.mkdir = (int(*)())ptr;
|
||||
+ __collector_util_funcs.mkdir = (int(*)(const char*, mode_t))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT mkdir: %s\n", dlerror ());
|
||||
@@ -1249,7 +1249,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "opendir");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.opendir = (DIR * (*)())ptr;
|
||||
+ __collector_util_funcs.opendir = (DIR * (*)(const char*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT opendir: %s\n", dlerror ());
|
||||
@@ -1258,7 +1258,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "closedir");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.closedir = (int(*)())ptr;
|
||||
+ __collector_util_funcs.closedir = (int(*)(DIR*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT closedir: %s\n", dlerror ());
|
||||
@@ -1267,7 +1267,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "execv");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.execv = (int(*)())ptr;
|
||||
+ __collector_util_funcs.execv = (int(*)(const char*, char* const*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT execv: %s\n", dlerror ());
|
||||
@@ -1276,7 +1276,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "exit");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.exit = (void(*)())ptr;
|
||||
+ __collector_util_funcs.exit = (void(*)(int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT exit: %s\n", dlerror ());
|
||||
@@ -1285,7 +1285,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "vfork");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.vfork = (pid_t (*)())ptr;
|
||||
+ __collector_util_funcs.vfork = (pid_t (*)(void))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT vfork: %s\n", dlerror ());
|
||||
@@ -1294,7 +1294,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "waitpid");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.waitpid = (pid_t (*)())ptr;
|
||||
+ __collector_util_funcs.waitpid = (pid_t (*)(pid_t, int*, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT waitpid: %s\n", dlerror ());
|
||||
@@ -1313,7 +1313,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "getcontext");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.getcontext = (int(*)())ptr;
|
||||
+ __collector_util_funcs.getcontext = (int(*)(ucontext_t*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT getcontext: %s\n", dlerror ());
|
||||
@@ -1331,7 +1331,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "putenv");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.putenv = (int(*)())ptr;
|
||||
+ __collector_util_funcs.putenv = (int(*)(char*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT putenv: %s\n", dlerror ());
|
||||
@@ -1340,7 +1340,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "getenv");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.getenv = (char*(*)())ptr;
|
||||
+ __collector_util_funcs.getenv = (char*(*)(const char*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT getenv: %s\n", dlerror ());
|
||||
@@ -1349,7 +1349,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "time");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.time = (time_t (*)())ptr;
|
||||
+ __collector_util_funcs.time = (time_t (*)(time_t*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT time: %s\n", dlerror ());
|
||||
@@ -1358,7 +1358,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "mktime");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.mktime = (time_t (*)())ptr;
|
||||
+ __collector_util_funcs.mktime = (time_t (*)(struct tm*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT mktime: %s\n", dlerror ());
|
||||
@@ -1372,7 +1372,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "gmtime_r");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.gmtime_r = (struct tm * (*)())ptr;
|
||||
+ __collector_util_funcs.gmtime_r = (struct tm * (*)(const time_t*, struct tm*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT gmtime_r: %s\n", dlerror ());
|
||||
@@ -1381,7 +1381,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "strtol");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.strtol = (long (*)())ptr;
|
||||
+ __collector_util_funcs.strtol = (long (*)(const char*, char**, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strtol: %s\n", dlerror ());
|
||||
@@ -1390,7 +1390,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "strtoll");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.strtoll = (long long (*)())ptr;
|
||||
+ __collector_util_funcs.strtoll = (long long (*)(const char*, char**, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strtoll: %s\n", dlerror ());
|
||||
@@ -1402,7 +1402,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "setenv");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.setenv = (int(*)())ptr;
|
||||
+ __collector_util_funcs.setenv = (int(*)(const char*, const char*, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT setenv: %s\n", dlerror ());
|
||||
@@ -1411,7 +1411,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "unsetenv");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.unsetenv = (int(*)())ptr;
|
||||
+ __collector_util_funcs.unsetenv = (int(*)(const char*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT unsetenv: %s\n", dlerror ());
|
||||
@@ -1498,7 +1498,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "pclose");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.pclose = (int(*)())ptr;
|
||||
+ __collector_util_funcs.pclose = (int(*)(FILE*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT pclose: %s\n", dlerror ());
|
||||
@@ -1507,7 +1507,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "fgets");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.fgets = (char*(*)())ptr;
|
||||
+ __collector_util_funcs.fgets = (char*(*)(char*, int, FILE*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT fgets: %s\n", dlerror ());
|
||||
@@ -1534,7 +1534,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "vsnprintf");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.vsnprintf = (int(*)())ptr;
|
||||
+ __collector_util_funcs.vsnprintf = (int(*)(char*, size_t, const char*, ...))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT vsnprintf: %s\n", dlerror ());
|
||||
@@ -1543,7 +1543,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "atoi");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.atoi = (int(*)())ptr;
|
||||
+ __collector_util_funcs.atoi = (int(*)(const char*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT atoi: %s\n", dlerror ());
|
||||
@@ -1552,7 +1552,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "calloc");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.calloc = (void*(*)())ptr;
|
||||
+ __collector_util_funcs.calloc = (void*(*)(size_t, size_t))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT calloc: %s\n", dlerror ());
|
||||
@@ -1562,7 +1562,7 @@ __collector_util_init ()
|
||||
ptr = dlsym (libc, "free");
|
||||
if (ptr)
|
||||
{
|
||||
- __collector_util_funcs.free = (void(*)())ptr;
|
||||
+ __collector_util_funcs.free = (void(*)(void*))ptr;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -1572,7 +1572,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "strdup");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.libc_strdup = (char*(*)())ptr;
|
||||
+ __collector_util_funcs.libc_strdup = (char*(*)(const char*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strdup: %s\n", dlerror ());
|
||||
@@ -1585,7 +1585,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "strerror");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.strerror = (char*(*)())ptr;
|
||||
+ __collector_util_funcs.strerror = (char*(*)(int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strerror: %s\n", dlerror ());
|
||||
@@ -1593,7 +1593,7 @@ __collector_util_init ()
|
||||
}
|
||||
ptr = dlsym (libc, "strerror_r");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.strerror_r = (int(*)())ptr;
|
||||
+ __collector_util_funcs.strerror_r = (int(*)(int, char*, size_t))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strerror_r: %s\n", dlerror ());
|
||||
@@ -1601,7 +1601,7 @@ __collector_util_init ()
|
||||
}
|
||||
ptr = dlsym (libc, "strspn");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.strspn = (size_t (*)())ptr;
|
||||
+ __collector_util_funcs.strspn = (size_t (*)(const char*, const char*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strspn: %s\n", dlerror ());
|
||||
@@ -1610,7 +1610,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "strtoul");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.strtoul = (unsigned long int(*)())ptr;
|
||||
+ __collector_util_funcs.strtoul = (unsigned long int(*)(const char*, char**, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strtoul: %s\n", dlerror ());
|
||||
@@ -1619,7 +1619,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "strtoull");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.strtoull = (unsigned long long int(*)())ptr;
|
||||
+ __collector_util_funcs.strtoull = (unsigned long long int(*)(const char*, char**, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strtoull: %s\n", dlerror ());
|
||||
@@ -1664,7 +1664,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "sysconf");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.sysconf = (long(*)())ptr;
|
||||
+ __collector_util_funcs.sysconf = (long(*)(int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT sysconf: %s\n", dlerror ());
|
||||
@@ -1673,7 +1673,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "sigfillset");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.sigfillset = (int(*)())ptr;
|
||||
+ __collector_util_funcs.sigfillset = (int(*)(sigset_t*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT sigfillset: %s\n", dlerror ());
|
||||
@@ -1682,7 +1682,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "sigprocmask");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.sigprocmask = (int(*)())ptr;
|
||||
+ __collector_util_funcs.sigprocmask = (int(*)(int, const sigset_t*, sigset_t*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT sigprocmask: %s\n", dlerror ());
|
||||
diff --git a/gprofng/libcollector/mmaptrace.c b/gprofng/libcollector/mmaptrace.c
|
||||
index f07f4d76513..2a6857ab58e 100644
|
||||
--- a/gprofng/libcollector/mmaptrace.c
|
||||
+++ b/gprofng/libcollector/mmaptrace.c
|
||||
@@ -1209,7 +1209,7 @@ process_vsyscall_page ()
|
||||
/*
|
||||
* collector API for dynamic functions
|
||||
*/
|
||||
-void collector_func_load () __attribute__ ((weak, alias ("__collector_func_load")));
|
||||
+void collector_func_load (char*, char*, char*, void*, int, int, DT_lineno *) __attribute__ ((weak, alias ("__collector_func_load")));
|
||||
void
|
||||
__collector_func_load (char *name, char *alias, char *sourcename,
|
||||
void *vaddr, int size, int lntsize, DT_lineno *lntable)
|
||||
@@ -1218,7 +1218,7 @@ __collector_func_load (char *name, char *alias, char *sourcename,
|
||||
vaddr, size, lntsize, lntable);
|
||||
}
|
||||
|
||||
-void collector_func_unload () __attribute__ ((weak, alias ("__collector_func_unload")));
|
||||
+void collector_func_unload (void *vaddr) __attribute__ ((weak, alias ("__collector_func_unload")));
|
||||
void
|
||||
__collector_func_unload (void *vaddr)
|
||||
{
|
||||
diff --git a/gprofng/libcollector/unwind.c b/gprofng/libcollector/unwind.c
|
||||
index 91678b1e334..cd47d4fbe0f 100644
|
||||
--- a/gprofng/libcollector/unwind.c
|
||||
+++ b/gprofng/libcollector/unwind.c
|
||||
@@ -416,7 +416,7 @@ __collector_ext_unwind_init (int record)
|
||||
omp_no_walk = 1;
|
||||
|
||||
if (__collector_VM_ReadByteInstruction == NULL)
|
||||
- __collector_VM_ReadByteInstruction = (int(*)()) dlsym (RTLD_DEFAULT, "Async_VM_ReadByteInstruction");
|
||||
+ __collector_VM_ReadByteInstruction = (int(*)(unsigned char*)) dlsym (RTLD_DEFAULT, "Async_VM_ReadByteInstruction");
|
||||
|
||||
#if ARCH(SPARC)
|
||||
#if WSIZE(64)
|
||||
diff --git a/gprofng/src/collector_module.h b/gprofng/src/collector_module.h
|
||||
index ebcdbca561f..fd888cd58dd 100644
|
||||
--- a/gprofng/src/collector_module.h
|
||||
+++ b/gprofng/src/collector_module.h
|
||||
@@ -110,7 +110,7 @@ typedef struct CollectorUtilFuncs
|
||||
long (*sysinfo)(int command, char *buf, long count);
|
||||
time_t (*time)(time_t *tloc);
|
||||
int (*unsetenv)(const char *name);
|
||||
- int (*vsnprintf)(char *str, size_t size, const char *format, va_list ap);
|
||||
+ int (*vsnprintf)(char *str, size_t size, const char *format, ...);
|
||||
pid_t (*waitpid)(pid_t pid, int *stat_loc, int options);
|
||||
ssize_t (*write)(int, void *, size_t);
|
||||
double (*atof)();
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -0,0 +1,199 @@
|
||||
From e91e1fd342c9ded87f53bc7e9e8d5d693b9a570a Mon Sep 17 00:00:00 2001
|
||||
From: Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
|
||||
Date: Thu, 21 Nov 2024 14:48:20 -0800
|
||||
Subject: [PATCH] gprofng: fix build with -std=gnu23
|
||||
|
||||
Fix function pointer types accordingly.
|
||||
Remove unused function pointers.
|
||||
|
||||
gprofng/ChangeLog
|
||||
2024-11-21 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
|
||||
|
||||
PR gprofng/32374
|
||||
PR gprofng/32373
|
||||
* common/cpuid.c: Define ATTRIBUTE_UNUSED if necessary.
|
||||
* libcollector/libcol_util.c (sysinfo): Remove unused pointer.
|
||||
* src/collector_module.h: Likewise.
|
||||
* libcollector/dispatcher.c (setitimer): Fix prototype.
|
||||
* libcollector/linetrace.c (system, grantpt, ptsname): Likewise.
|
||||
* testsuite/gprofng.display/mttest/mttest.c (dump_arrays): Likewise.
|
||||
* testsuite/gprofng.display/synprog/endcases.c (xinline_code,
|
||||
s_inline_code): Likewise.
|
||||
* testsuite/gprofng.display/synprog/inc_inline.h (ext_inline_code):
|
||||
Likewise.
|
||||
* testsuite/gprofng.display/synprog/synprog.c (doabort): Rename nullptr.
|
||||
|
||||
Upstream: 4e943705e3e8a5a9448d087502bcb390a694ad02
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
gprofng/common/cpuid.c | 2 ++
|
||||
gprofng/libcollector/dispatcher.c | 2 +-
|
||||
gprofng/libcollector/libcol_util.c | 9 ---------
|
||||
gprofng/libcollector/linetrace.c | 10 +++++-----
|
||||
gprofng/src/collector_module.h | 1 -
|
||||
gprofng/testsuite/gprofng.display/mttest/mttest.c | 2 +-
|
||||
gprofng/testsuite/gprofng.display/synprog/endcases.c | 4 ++--
|
||||
gprofng/testsuite/gprofng.display/synprog/inc_inline.h | 2 +-
|
||||
gprofng/testsuite/gprofng.display/synprog/synprog.c | 4 ++--
|
||||
9 files changed, 14 insertions(+), 22 deletions(-)
|
||||
|
||||
diff --git a/gprofng/common/cpuid.c b/gprofng/common/cpuid.c
|
||||
index af15439eb27..0373969693b 100644
|
||||
--- a/gprofng/common/cpuid.c
|
||||
+++ b/gprofng/common/cpuid.c
|
||||
@@ -21,7 +21,9 @@
|
||||
#if defined(__i386__) || defined(__x86_64)
|
||||
#include <cpuid.h> /* GCC-provided */
|
||||
#elif defined(__aarch64__)
|
||||
+#if !defined(ATTRIBUTE_UNUSED)
|
||||
#define ATTRIBUTE_UNUSED __attribute__((unused))
|
||||
+#endif
|
||||
|
||||
static inline uint_t __attribute_const__
|
||||
__get_cpuid (unsigned int op ATTRIBUTE_UNUSED, unsigned int *eax,
|
||||
diff --git a/gprofng/libcollector/dispatcher.c b/gprofng/libcollector/dispatcher.c
|
||||
index 5ee0bf895bf..e85c343c776 100644
|
||||
--- a/gprofng/libcollector/dispatcher.c
|
||||
+++ b/gprofng/libcollector/dispatcher.c
|
||||
@@ -1281,4 +1281,4 @@ __collector_ext_clone_pthread (int (*fn)(void *), void *child_stack, int flags,
|
||||
// weak symbols:
|
||||
int sigprocmask (int, const sigset_t*, sigset_t*) __attribute__ ((weak, alias ("__collector_sigprocmask")));
|
||||
int thr_sigsetmask (int, const sigset_t*, sigset_t*) __attribute__ ((weak, alias ("__collector_thr_sigsetmask")));
|
||||
-int setitimer () __attribute__ ((weak, alias ("_setitimer")));
|
||||
+__typeof(setitimer) setitimer __attribute__ ((weak, alias ("_setitimer")));
|
||||
diff --git a/gprofng/libcollector/libcol_util.c b/gprofng/libcollector/libcol_util.c
|
||||
index 688bdf19c6d..46f8b80ccb4 100644
|
||||
--- a/gprofng/libcollector/libcol_util.c
|
||||
+++ b/gprofng/libcollector/libcol_util.c
|
||||
@@ -1427,15 +1427,6 @@ __collector_util_init ()
|
||||
err = COL_ERROR_UTIL_INIT;
|
||||
}
|
||||
|
||||
- ptr = dlsym (libc, "sysinfo");
|
||||
- if (ptr)
|
||||
- __collector_util_funcs.sysinfo = (long (*)())ptr;
|
||||
- else
|
||||
- {
|
||||
- CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT sysinfo: %s\n", dlerror ());
|
||||
- err = COL_ERROR_UTIL_INIT;
|
||||
- }
|
||||
-
|
||||
ptr = dlsym (libc, "clearenv");
|
||||
if (ptr)
|
||||
__collector_util_funcs.clearenv = (int(*)())ptr;
|
||||
diff --git a/gprofng/libcollector/linetrace.c b/gprofng/libcollector/linetrace.c
|
||||
index 66844bc1337..c81ae1a2272 100644
|
||||
--- a/gprofng/libcollector/linetrace.c
|
||||
+++ b/gprofng/libcollector/linetrace.c
|
||||
@@ -1527,7 +1527,7 @@ DCL_FUNC_VER (DCL_POSIX_SPAWNP, posix_spawnp_2_2, posix_spawnp@GLIBC_2.2)
|
||||
DCL_POSIX_SPAWNP (posix_spawnp)
|
||||
|
||||
/*------------------------------------------------------------- system */
|
||||
-int system () __attribute__ ((weak, alias ("__collector_system")));
|
||||
+int system (const char *cmd) __attribute__ ((weak, alias ("__collector_system")));
|
||||
|
||||
int
|
||||
__collector_system (const char *cmd)
|
||||
@@ -1582,10 +1582,10 @@ DCL_FUNC_VER (DCL_POPEN, popen_2_0, popen@GLIBC_2.0)
|
||||
DCL_POPEN (popen)
|
||||
|
||||
/*------------------------------------------------------------- grantpt */
|
||||
-int grantpt () __attribute__ ((weak, alias ("__collector_grantpt")));
|
||||
+int grantpt (int fildes) __attribute__ ((weak, alias ("__collector_grantpt")));
|
||||
|
||||
int
|
||||
-__collector_grantpt (const int fildes)
|
||||
+__collector_grantpt (int fildes)
|
||||
{
|
||||
if (NULL_PTR (grantpt))
|
||||
init_lineage_intf ();
|
||||
@@ -1607,10 +1607,10 @@ __collector_grantpt (const int fildes)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------- ptsname */
|
||||
-char *ptsname () __attribute__ ((weak, alias ("__collector_ptsname")));
|
||||
+char *ptsname (int fildes) __attribute__ ((weak, alias ("__collector_ptsname")));
|
||||
|
||||
char *
|
||||
-__collector_ptsname (const int fildes)
|
||||
+__collector_ptsname (int fildes)
|
||||
{
|
||||
if (NULL_PTR (ptsname))
|
||||
init_lineage_intf ();
|
||||
diff --git a/gprofng/src/collector_module.h b/gprofng/src/collector_module.h
|
||||
index fd888cd58dd..6640f12fa3c 100644
|
||||
--- a/gprofng/src/collector_module.h
|
||||
+++ b/gprofng/src/collector_module.h
|
||||
@@ -107,7 +107,6 @@ typedef struct CollectorUtilFuncs
|
||||
int (*symlink)(const char *s1, const char *s2);
|
||||
int (*syscall)(int number, ...);
|
||||
long (*sysconf)(int name);
|
||||
- long (*sysinfo)(int command, char *buf, long count);
|
||||
time_t (*time)(time_t *tloc);
|
||||
int (*unsetenv)(const char *name);
|
||||
int (*vsnprintf)(char *str, size_t size, const char *format, ...);
|
||||
diff --git a/gprofng/testsuite/gprofng.display/mttest/mttest.c b/gprofng/testsuite/gprofng.display/mttest/mttest.c
|
||||
index e0835c833e5..3db5b8d8e86 100644
|
||||
--- a/gprofng/testsuite/gprofng.display/mttest/mttest.c
|
||||
+++ b/gprofng/testsuite/gprofng.display/mttest/mttest.c
|
||||
@@ -171,7 +171,7 @@ void computeJ (workStruct_t *x);
|
||||
void computeK (workStruct_t *x);
|
||||
void addone (workCtr_t *x);
|
||||
void init_arrays (int strat);
|
||||
-void dump_arrays ();
|
||||
+void dump_arrays (hrtime_t real, hrtime_t cpu, int case_index);
|
||||
void *do_work (void *v);
|
||||
void thread_work ();
|
||||
void nothreads (Workblk *array, struct scripttab *k);
|
||||
diff --git a/gprofng/testsuite/gprofng.display/synprog/endcases.c b/gprofng/testsuite/gprofng.display/synprog/endcases.c
|
||||
index a6a1389658a..6f1c83b6859 100644
|
||||
--- a/gprofng/testsuite/gprofng.display/synprog/endcases.c
|
||||
+++ b/gprofng/testsuite/gprofng.display/synprog/endcases.c
|
||||
@@ -40,8 +40,8 @@ static void s_inline_code (int);
|
||||
void ext_inline_code (int);
|
||||
|
||||
#ifndef NO_INLINE
|
||||
-void xinline_code () __attribute__ ((always_inline));
|
||||
-void s_inline_code () __attribute__ ((always_inline));
|
||||
+void xinline_code (int) __attribute__ ((always_inline));
|
||||
+void s_inline_code (int) __attribute__ ((always_inline));
|
||||
#endif
|
||||
|
||||
#include "inc_inline.h"
|
||||
diff --git a/gprofng/testsuite/gprofng.display/synprog/inc_inline.h b/gprofng/testsuite/gprofng.display/synprog/inc_inline.h
|
||||
index da42563c828..6600eacb66d 100644
|
||||
--- a/gprofng/testsuite/gprofng.display/synprog/inc_inline.h
|
||||
+++ b/gprofng/testsuite/gprofng.display/synprog/inc_inline.h
|
||||
@@ -19,7 +19,7 @@
|
||||
MA 02110-1301, USA. */
|
||||
|
||||
#ifndef NO_INLINE
|
||||
-void ext_inline_code() __attribute__ ((always_inline));
|
||||
+void ext_inline_code(int) __attribute__ ((always_inline));
|
||||
#endif
|
||||
|
||||
void
|
||||
diff --git a/gprofng/testsuite/gprofng.display/synprog/synprog.c b/gprofng/testsuite/gprofng.display/synprog/synprog.c
|
||||
index cf1bc5b0909..05920dc7419 100644
|
||||
--- a/gprofng/testsuite/gprofng.display/synprog/synprog.c
|
||||
+++ b/gprofng/testsuite/gprofng.display/synprog/synprog.c
|
||||
@@ -528,14 +528,14 @@ reapchildren ()
|
||||
int
|
||||
doabort (int k)
|
||||
{
|
||||
- char *nullptr = NULL;
|
||||
+ char *p = NULL;
|
||||
char c;
|
||||
|
||||
/* Log the event */
|
||||
wlog ("start of doabort", NULL);
|
||||
|
||||
/* and dereference a NULL */
|
||||
- c = *nullptr;
|
||||
+ c = *p;
|
||||
|
||||
/* this should never be reached */
|
||||
return (int) c;
|
||||
--
|
||||
2.50.1
|
||||
|
||||
+801
@@ -0,0 +1,801 @@
|
||||
From 3e8c6e03675963d65a2f98eb006336c5cd375ec3 Mon Sep 17 00:00:00 2001
|
||||
From: Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
|
||||
Date: Tue, 3 Sep 2024 21:30:31 -0700
|
||||
Subject: [PATCH] Fix 32097 Warnings when building gprofng with Clang
|
||||
|
||||
gprofng/ChangeLog
|
||||
2024-09-03 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>.
|
||||
|
||||
PR gprofng/32097
|
||||
* common/hwcdrv.c: Fix -Wempty-body warnings.
|
||||
* common/hwcentry.h: Fix -Wdeprecated-non-prototype warnings.
|
||||
* common/hwctable.c: Fix -Wdeprecated-non-prototype warnings.
|
||||
* libcollector/collector.c: Likewise.
|
||||
* libcollector/collector.h: Likewise.
|
||||
* libcollector/collectorAPI.c: Likewise.
|
||||
* libcollector/dispatcher.c: Likewise.
|
||||
* libcollector/iotrace.c: Likewise.
|
||||
* libcollector/libcol_util.c: Fix -Wunused-but-set-variable warnings.
|
||||
* libcollector/libcol_util.h: Remove unused declarations.
|
||||
* libcollector/linetrace.c: Fix -Wdeprecated-non-prototype warnings.
|
||||
* src/BaseMetricTreeNode.h: Fix -Wunused-private-field warnings.
|
||||
* src/Dbe.cc: Fix -Wself-assign warnings.
|
||||
* src/DbeSession.cc: Fix -Wunused-but-set-variable warnings.
|
||||
* src/Disasm.cc: Fix -Wunused-const-variable warnings.
|
||||
* src/Experiment.cc: Fix -Wunused-private-field warnings.
|
||||
* src/HashMap.h: Fix -Wself-assign warnings.
|
||||
* src/IOActivity.h: Fix -Wunused-private-field warnings.
|
||||
* src/collctrl.cc: Fix -Wself-assign, -Wparentheses-equality warnings.
|
||||
* src/collctrl.h: Fix -Wunused-private-field warnings.
|
||||
* src/collector_module.h: Fix -Wdeprecated-non-prototype warnings.
|
||||
* src/gp-display-src.cc: Fix -Wunused-private-field warnings.
|
||||
* src/gp-print.h: Fix -Wheader-guard warnings.
|
||||
* src/hwc_intel_icelake.h: Fix -Winitializer-overrides warnings.
|
||||
* src/util.cc: Fix -Wunused-but-set-variable warnings.
|
||||
|
||||
Upstream: b79c457ca01df82dbe1facb708e45def4584c903
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
gprofng/common/hwcdrv.c | 3 ++-
|
||||
gprofng/common/hwcentry.h | 7 +----
|
||||
gprofng/common/hwctable.c | 13 +---------
|
||||
gprofng/libcollector/collector.c | 15 ++++-------
|
||||
gprofng/libcollector/collector.h | 2 +-
|
||||
gprofng/libcollector/collectorAPI.c | 15 ++++++-----
|
||||
gprofng/libcollector/dispatcher.c | 19 ++++++++------
|
||||
gprofng/libcollector/iotrace.c | 12 ++++-----
|
||||
gprofng/libcollector/libcol_util.c | 2 --
|
||||
gprofng/libcollector/libcol_util.h | 6 -----
|
||||
gprofng/libcollector/linetrace.c | 40 +++++++++++++++++------------
|
||||
gprofng/src/BaseMetricTreeNode.h | 1 -
|
||||
gprofng/src/Dbe.cc | 12 ++++-----
|
||||
gprofng/src/DbeSession.cc | 3 ---
|
||||
gprofng/src/Disasm.cc | 1 -
|
||||
gprofng/src/Experiment.cc | 2 --
|
||||
gprofng/src/HashMap.h | 3 +--
|
||||
gprofng/src/IOActivity.h | 1 -
|
||||
gprofng/src/collctrl.cc | 14 +++++-----
|
||||
gprofng/src/collctrl.h | 1 -
|
||||
gprofng/src/collector_module.h | 20 +++++++--------
|
||||
gprofng/src/gp-display-src.cc | 8 ------
|
||||
gprofng/src/gp-print.h | 2 +-
|
||||
gprofng/src/hwc_intel_icelake.h | 6 +++--
|
||||
gprofng/src/util.cc | 10 +++-----
|
||||
25 files changed, 88 insertions(+), 130 deletions(-)
|
||||
|
||||
diff --git a/gprofng/common/hwcdrv.c b/gprofng/common/hwcdrv.c
|
||||
index aaf3acdf9cd..51492a8d35c 100644
|
||||
--- a/gprofng/common/hwcdrv.c
|
||||
+++ b/gprofng/common/hwcdrv.c
|
||||
@@ -574,6 +574,7 @@ read_sample (counter_state_t *ctr_state, int msgsz, uint64_t *rvalue,
|
||||
static void
|
||||
dump_perf_event_attr (struct perf_event_attr *at)
|
||||
{
|
||||
+#if defined(DEBUG)
|
||||
TprintfT (DBG_LT2, "dump_perf_event_attr: size=%d type=%d sample_period=%lld\n"
|
||||
" config=0x%llx config1=0x%llx config2=0x%llx wakeup_events=%lld __reserved_1=%lld\n",
|
||||
(int) at->size, (int) at->type, (unsigned long long) at->sample_period,
|
||||
@@ -589,13 +590,13 @@ dump_perf_event_attr (struct perf_event_attr *at)
|
||||
DUMP_F (exclude_kernel);
|
||||
DUMP_F (exclude_hv);
|
||||
DUMP_F (exclude_idle);
|
||||
- // DUMP_F(xmmap);
|
||||
DUMP_F (comm);
|
||||
DUMP_F (freq);
|
||||
DUMP_F (inherit_stat);
|
||||
DUMP_F (enable_on_exec);
|
||||
DUMP_F (task);
|
||||
DUMP_F (watermark);
|
||||
+#endif
|
||||
}
|
||||
|
||||
static void
|
||||
diff --git a/gprofng/common/hwcentry.h b/gprofng/common/hwcentry.h
|
||||
index b2ab8b9b22c..0b923fc3576 100644
|
||||
--- a/gprofng/common/hwcentry.h
|
||||
+++ b/gprofng/common/hwcentry.h
|
||||
@@ -200,17 +200,12 @@ extern "C"
|
||||
extern char *hwc_get_docref (char *buf, size_t buflen);
|
||||
/* Return a CPU HWC document reference, or NULL. */
|
||||
|
||||
- // TBR
|
||||
- extern char *hwc_get_default_cntrs ();
|
||||
- /* Return a default HW counter string; may be NULL, or zero-length */
|
||||
- /* NULL means none is defined in the table; or zero-length means string defined could not be loaded */
|
||||
-
|
||||
extern char *hwc_get_default_cntrs2 (int forKernel, int style);
|
||||
/* like hwc_get_default_cntrs() for style==1 */
|
||||
/* but allows other styles of formatting as well */
|
||||
/* deprecate and eventually remove hwc_get_default_cntrs() */
|
||||
|
||||
- extern char *hwc_get_orig_default_cntrs ();
|
||||
+ extern char *hwc_get_orig_default_cntrs (int forKernel);
|
||||
/* Get the default HW counter string as set in the table */
|
||||
/* NULL means none is defined in the table */
|
||||
|
||||
diff --git a/gprofng/common/hwctable.c b/gprofng/common/hwctable.c
|
||||
index 0baf63b1805..338a1ea86f4 100644
|
||||
--- a/gprofng/common/hwctable.c
|
||||
+++ b/gprofng/common/hwctable.c
|
||||
@@ -1783,7 +1783,7 @@ check_tables ()
|
||||
}
|
||||
#endif
|
||||
|
||||
-static int try_a_counter ();
|
||||
+static int try_a_counter (int forKernel);
|
||||
static void hwc_process_raw_ctrs (int forKernel, Hwcentry ***pstd_out,
|
||||
Hwcentry ***praw_out, Hwcentry ***phidden_out,
|
||||
Hwcentry**static_tables,
|
||||
@@ -2824,17 +2824,6 @@ hwc_get_docref (char *buf, size_t buflen)
|
||||
return buf;
|
||||
}
|
||||
|
||||
-//TBR:
|
||||
-
|
||||
-extern char*
|
||||
-hwc_get_default_cntrs ()
|
||||
-{
|
||||
- setup_cpcx ();
|
||||
- if (cpcx_default_hwcs[0] != NULL)
|
||||
- return strdup (cpcx_default_hwcs[0]); // TBR deprecate this
|
||||
- return NULL;
|
||||
-}
|
||||
-
|
||||
extern char*
|
||||
hwc_get_default_cntrs2 (int forKernel, int style)
|
||||
{
|
||||
diff --git a/gprofng/libcollector/collector.c b/gprofng/libcollector/collector.c
|
||||
index 3a8f27a719d..2ff95e58fde 100644
|
||||
--- a/gprofng/libcollector/collector.c
|
||||
+++ b/gprofng/libcollector/collector.c
|
||||
@@ -210,15 +210,10 @@ get_collector_interface ()
|
||||
static void
|
||||
collector_module_init (CollectorInterface *col_intf)
|
||||
{
|
||||
- int nmodules = 0;
|
||||
-
|
||||
ModuleInitFunc next_init = (ModuleInitFunc) dlsym (RTLD_DEFAULT, "__collector_module_init");
|
||||
if (next_init != NULL)
|
||||
- {
|
||||
- nmodules++;
|
||||
- next_init (col_intf);
|
||||
- }
|
||||
- TprintfT (DBG_LT1, "collector_module_init: %d modules\n", nmodules);
|
||||
+ next_init (col_intf);
|
||||
+ TprintfT (DBG_LT1, "collector_module_init: %d modules\n", next_init ? 1 : 0);
|
||||
}
|
||||
|
||||
/* Routines concerned with general experiment start and stop */
|
||||
@@ -1783,7 +1778,7 @@ __collector_pause ()
|
||||
}
|
||||
|
||||
void
|
||||
-__collector_pause_m (char *reason)
|
||||
+__collector_pause_m (const char *reason)
|
||||
{
|
||||
hrtime_t now;
|
||||
char xreason[MAXPATHLEN];
|
||||
@@ -2449,8 +2444,8 @@ __collector_dlog (int tflag, int level, char *format, ...)
|
||||
|
||||
static void (*__real__exit) (int status) = NULL; /* libc only: _exit */
|
||||
static void (*__real__Exit) (int status) = NULL; /* libc only: _Exit */
|
||||
-void _exit () __attribute__ ((weak, alias ("__collector_exit")));
|
||||
-void _Exit () __attribute__ ((weak, alias ("__collector_Exit")));
|
||||
+void _exit (int status) __attribute__ ((weak, alias ("__collector_exit")));
|
||||
+void _Exit (int status) __attribute__ ((weak, alias ("__collector_Exit")));
|
||||
|
||||
void
|
||||
__collector_exit (int status)
|
||||
diff --git a/gprofng/libcollector/collector.h b/gprofng/libcollector/collector.h
|
||||
index 07a03bdd17a..eda68a0e4f5 100644
|
||||
--- a/gprofng/libcollector/collector.h
|
||||
+++ b/gprofng/libcollector/collector.h
|
||||
@@ -123,7 +123,7 @@ extern void __collector_terminate_expt ();
|
||||
extern void __collector_terminate_hook ();
|
||||
extern void __collector_sample (char *name);
|
||||
extern void __collector_pause ();
|
||||
-extern void __collector_pause_m ();
|
||||
+extern void __collector_pause_m (const char *reason);
|
||||
extern void __collector_resume ();
|
||||
extern int collector_sigemt_sigaction (const struct sigaction*,
|
||||
struct sigaction*);
|
||||
diff --git a/gprofng/libcollector/collectorAPI.c b/gprofng/libcollector/collectorAPI.c
|
||||
index 5fa6403ad49..449bbbaab65 100644
|
||||
--- a/gprofng/libcollector/collectorAPI.c
|
||||
+++ b/gprofng/libcollector/collectorAPI.c
|
||||
@@ -26,16 +26,17 @@
|
||||
#include "collectorAPI.h"
|
||||
#include "gp-experiment.h"
|
||||
|
||||
-static void *__real_collector_sample = NULL;
|
||||
-static void *__real_collector_pause = NULL;
|
||||
-static void *__real_collector_resume = NULL;
|
||||
-static void *__real_collector_terminate_expt = NULL;
|
||||
-static void *__real_collector_func_load = NULL;
|
||||
-static void *__real_collector_func_unload = NULL;
|
||||
+static void (*__real_collector_sample)(const char *) = NULL;
|
||||
+static void (*__real_collector_pause)() = NULL;
|
||||
+static void (*__real_collector_resume)() = NULL;
|
||||
+static void (*__real_collector_terminate_expt)() = NULL;
|
||||
+static void (*__real_collector_func_load)(const char *, const char *,
|
||||
+ const char *, void *, int, int, Lineno *) = NULL;
|
||||
+static void (*__real_collector_func_unload)(void *) = NULL;
|
||||
|
||||
#define INIT_API if (init_API == 0) collectorAPI_initAPI()
|
||||
#define NULL_PTR(x) (__real_##x == NULL)
|
||||
-#define CALL_REAL(x) (*(void(*)())__real_##x)
|
||||
+#define CALL_REAL(x) (__real_##x)
|
||||
#define CALL_IF_REAL(x) INIT_API; if (!NULL_PTR(x)) CALL_REAL(x)
|
||||
|
||||
static int init_API = 0;
|
||||
diff --git a/gprofng/libcollector/dispatcher.c b/gprofng/libcollector/dispatcher.c
|
||||
index 8b8ad77b5ee..f7cd46e7e6b 100644
|
||||
--- a/gprofng/libcollector/dispatcher.c
|
||||
+++ b/gprofng/libcollector/dispatcher.c
|
||||
@@ -908,8 +908,9 @@ sigset (int sig, sighandler_t handler)
|
||||
|
||||
// map interposed symbol versions
|
||||
static int
|
||||
-gprofng_timer_create (int (real_func) (), clockid_t clockid,
|
||||
- struct sigevent *sevp, timer_t *timerid)
|
||||
+gprofng_timer_create (int (real_func) (clockid_t, struct sigevent *, timer_t *),
|
||||
+ clockid_t clockid,
|
||||
+ struct sigevent *sevp, timer_t *timerid)
|
||||
{
|
||||
// collector reserves SIGPROF
|
||||
if (sevp == NULL || sevp->sigev_notify != SIGEV_SIGNAL ||
|
||||
@@ -1044,7 +1045,7 @@ __collector_thr_sigsetmask (int how, const sigset_t* iset, sigset_t* oset)
|
||||
// map interposed symbol versions
|
||||
|
||||
static int
|
||||
-gprofng_pthread_sigmask (int (real_func) (),
|
||||
+gprofng_pthread_sigmask (int (real_func) (int, const sigset_t *, sigset_t*),
|
||||
int how, const sigset_t *iset, sigset_t* oset)
|
||||
{
|
||||
sigset_t lsigset;
|
||||
@@ -1139,9 +1140,10 @@ collector_root (void *cargs)
|
||||
// map interposed symbol versions
|
||||
|
||||
static int
|
||||
-gprofng_pthread_create (int (real_func) (), pthread_t *thread,
|
||||
- const pthread_attr_t *attr,
|
||||
- void *(*func)(void*), void *arg)
|
||||
+gprofng_pthread_create (int (real_func) (pthread_t *, const pthread_attr_t *,
|
||||
+ void *(*)(void *), void *),
|
||||
+ pthread_t *thread, const pthread_attr_t *attr,
|
||||
+ void *(*func)(void*), void *arg)
|
||||
{
|
||||
TprintfT (DBG_LTT, "gprofng_pthread_create @%p\n", real_func);
|
||||
if (dispatch_mode != DISPATCH_ON)
|
||||
@@ -1276,6 +1278,7 @@ __collector_ext_clone_pthread (int (*fn)(void *), void *child_stack, int flags,
|
||||
}
|
||||
|
||||
// weak symbols:
|
||||
-int sigprocmask () __attribute__ ((weak, alias ("__collector_sigprocmask")));
|
||||
-int thr_sigsetmask () __attribute__ ((weak, alias ("__collector_thr_sigsetmask")));
|
||||
+int sigprocmask (int, const sigset_t*, sigset_t*) __attribute__ ((weak, alias ("__collector_sigprocmask")));
|
||||
+int thr_sigsetmask (int, const sigset_t*, sigset_t*) __attribute__ ((weak, alias ("__collector_thr_sigsetmask")));
|
||||
int setitimer () __attribute__ ((weak, alias ("_setitimer")));
|
||||
+
|
||||
diff --git a/gprofng/libcollector/iotrace.c b/gprofng/libcollector/iotrace.c
|
||||
index 18060864796..3deb441d9c7 100644
|
||||
--- a/gprofng/libcollector/iotrace.c
|
||||
+++ b/gprofng/libcollector/iotrace.c
|
||||
@@ -1350,7 +1350,7 @@ mkstemp (char *template)
|
||||
unsigned pktSize;
|
||||
if (NULL_PTR (mkstemp))
|
||||
init_io_intf ();
|
||||
- if (CHCK_REENTRANCE (guard) || template == NULL)
|
||||
+ if (CHCK_REENTRANCE (guard))
|
||||
return CALL_REAL (mkstemp)(template);
|
||||
PUSH_REENTRANCE (guard);
|
||||
hrtime_t reqt = gethrtime ();
|
||||
@@ -1405,7 +1405,7 @@ mkstemps (char *template, int slen)
|
||||
unsigned pktSize;
|
||||
if (NULL_PTR (mkstemps))
|
||||
init_io_intf ();
|
||||
- if (CHCK_REENTRANCE (guard) || template == NULL)
|
||||
+ if (CHCK_REENTRANCE (guard))
|
||||
return CALL_REAL (mkstemps)(template, slen);
|
||||
PUSH_REENTRANCE (guard);
|
||||
hrtime_t reqt = gethrtime ();
|
||||
@@ -1485,7 +1485,7 @@ close (int fildes)
|
||||
|
||||
/*------------------------------------------------------------- fopen */
|
||||
static FILE*
|
||||
-gprofng_fopen (FILE*(real_fopen) (), const char *filename, const char *mode)
|
||||
+gprofng_fopen (FILE*(real_fopen) (const char *, const char *), const char *filename, const char *mode)
|
||||
{
|
||||
int *guard;
|
||||
FILE *fp = NULL;
|
||||
@@ -1559,7 +1559,7 @@ DCL_FOPEN (fopen)
|
||||
|
||||
/*------------------------------------------------------------- fclose */
|
||||
static int
|
||||
-gprofng_fclose (int(real_fclose) (), FILE *stream)
|
||||
+gprofng_fclose (int(real_fclose) (FILE *), FILE *stream)
|
||||
{
|
||||
int *guard;
|
||||
int stat;
|
||||
@@ -1645,7 +1645,7 @@ fflush (FILE *stream)
|
||||
|
||||
/*------------------------------------------------------------- fdopen */
|
||||
static FILE*
|
||||
-gprofng_fdopen (FILE*(real_fdopen) (), int fildes, const char *mode)
|
||||
+gprofng_fdopen (FILE*(real_fdopen) (int, const char *), int fildes, const char *mode)
|
||||
{
|
||||
int *guard;
|
||||
FILE *fp = NULL;
|
||||
@@ -2957,7 +2957,7 @@ DCL_FGETPOS (fgetpos)
|
||||
|
||||
/*------------------------------------------------------------- fgetpos64 */
|
||||
static int
|
||||
-gprofng_fgetpos64 (int(real_fgetpos64) (), FILE *stream, fpos64_t *pos)
|
||||
+gprofng_fgetpos64 (int(real_fgetpos64) (FILE *, fpos64_t *), FILE *stream, fpos64_t *pos)
|
||||
{
|
||||
int *guard;
|
||||
int ret;
|
||||
diff --git a/gprofng/libcollector/libcol_util.c b/gprofng/libcollector/libcol_util.c
|
||||
index 1e58cf491a1..baac15db5c4 100644
|
||||
--- a/gprofng/libcollector/libcol_util.c
|
||||
+++ b/gprofng/libcollector/libcol_util.c
|
||||
@@ -1013,7 +1013,6 @@ __collector_open (const char *path, int oflag, ...)
|
||||
mode_t mode = 0;
|
||||
|
||||
hrtime_t t_timeout = __collector_gethrtime () + 5 * ((hrtime_t) NANOSEC);
|
||||
- int nretries = 0;
|
||||
long long delay = 100; /* start at some small, arbitrary value */
|
||||
|
||||
/* get optional mode argument if it's expected/required */
|
||||
@@ -1058,7 +1057,6 @@ __collector_open (const char *path, int oflag, ...)
|
||||
delay *= 2;
|
||||
if (delay > 100000000)
|
||||
delay = 100000000; /* cap at some large, arbitrary value */
|
||||
- nretries++;
|
||||
}
|
||||
return fd;
|
||||
}
|
||||
diff --git a/gprofng/libcollector/libcol_util.h b/gprofng/libcollector/libcol_util.h
|
||||
index c8ec83ff0d9..aa30db72bcc 100644
|
||||
--- a/gprofng/libcollector/libcol_util.h
|
||||
+++ b/gprofng/libcollector/libcol_util.h
|
||||
@@ -81,12 +81,6 @@ extern int __collector_mutex_trylock (collector_mutex_t *mp);
|
||||
#define __collector_mutex_init(xx) \
|
||||
do { collector_mutex_t tmp=COLLECTOR_MUTEX_INITIALIZER; *(xx)=tmp; } while(0)
|
||||
|
||||
-void __collector_sample (char *name);
|
||||
-void __collector_terminate_expt ();
|
||||
-void __collector_pause ();
|
||||
-void __collector_pause_m ();
|
||||
-void __collector_resume ();
|
||||
-
|
||||
struct DT_lineno;
|
||||
|
||||
typedef enum
|
||||
diff --git a/gprofng/libcollector/linetrace.c b/gprofng/libcollector/linetrace.c
|
||||
index 67b2d7e9030..66844bc1337 100644
|
||||
--- a/gprofng/libcollector/linetrace.c
|
||||
+++ b/gprofng/libcollector/linetrace.c
|
||||
@@ -1207,7 +1207,7 @@ __collector_vfork (void)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------- execve */
|
||||
-int execve () __attribute__ ((weak, alias ("__collector_execve")));
|
||||
+int execve (const char *, char *const [], char *const []) __attribute__ ((weak, alias ("__collector_execve")));
|
||||
|
||||
int
|
||||
__collector_execve (const char* path, char *const argv[], char *const envp[])
|
||||
@@ -1237,7 +1237,7 @@ __collector_execve (const char* path, char *const argv[], char *const envp[])
|
||||
return ret;
|
||||
}
|
||||
|
||||
-int execvp () __attribute__ ((weak, alias ("__collector_execvp")));
|
||||
+int execvp (const char *, char *const []) __attribute__ ((weak, alias ("__collector_execvp")));
|
||||
|
||||
int
|
||||
__collector_execvp (const char* file, char *const argv[])
|
||||
@@ -1269,7 +1269,7 @@ __collector_execvp (const char* file, char *const argv[])
|
||||
return ret;
|
||||
}
|
||||
|
||||
-int execv () __attribute__ ((weak, alias ("__collector_execv")));
|
||||
+int execv (const char *, char *const []) __attribute__ ((weak, alias ("__collector_execv")));
|
||||
|
||||
int
|
||||
__collector_execv (const char* path, char *const argv[])
|
||||
@@ -1408,7 +1408,10 @@ __collector_execl (const char* path, const char *arg0, ...)
|
||||
/*-------------------------------------------------------- posix_spawn */
|
||||
// map interposed symbol versions
|
||||
static int
|
||||
-gprofng_posix_spawn (int(real_posix_spawn) (),
|
||||
+gprofng_posix_spawn (int(real_posix_spawn) (pid_t *, const char *,
|
||||
+ const posix_spawn_file_actions_t *,
|
||||
+ const posix_spawnattr_t *,
|
||||
+ char *const [], char *const []),
|
||||
pid_t *pidp, const char *path,
|
||||
const posix_spawn_file_actions_t *file_actions,
|
||||
const posix_spawnattr_t *attrp,
|
||||
@@ -1466,7 +1469,10 @@ DCL_POSIX_SPAWN (posix_spawn)
|
||||
|
||||
/*-------------------------------------------------------- posix_spawnp */
|
||||
static int
|
||||
-gprofng_posix_spawnp (int (real_posix_spawnp) (),
|
||||
+gprofng_posix_spawnp (int (real_posix_spawnp) (pid_t *, const char *,
|
||||
+ const posix_spawn_file_actions_t *,
|
||||
+ const posix_spawnattr_t *,
|
||||
+ char *const [], char *const []),
|
||||
pid_t *pidp, const char *path,
|
||||
const posix_spawn_file_actions_t *file_actions,
|
||||
const posix_spawnattr_t *attrp,
|
||||
@@ -1754,8 +1760,8 @@ __collector_clone (int (*fn)(void *), void *child_stack, int flags, void *arg,
|
||||
}
|
||||
|
||||
/*-------------------------------------------------------------------- setuid */
|
||||
-int setuid () __attribute__ ((weak, alias ("__collector_setuid")));
|
||||
-int _setuid () __attribute__ ((weak, alias ("__collector_setuid")));
|
||||
+int setuid (uid_t) __attribute__ ((weak, alias ("__collector_setuid")));
|
||||
+int _setuid (uid_t) __attribute__ ((weak, alias ("__collector_setuid")));
|
||||
|
||||
int
|
||||
__collector_setuid (uid_t ruid)
|
||||
@@ -1770,8 +1776,8 @@ __collector_setuid (uid_t ruid)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------- seteuid */
|
||||
-int seteuid () __attribute__ ((weak, alias ("__collector_seteuid")));
|
||||
-int _seteuid () __attribute__ ((weak, alias ("__collector_seteuid")));
|
||||
+int seteuid (uid_t) __attribute__ ((weak, alias ("__collector_seteuid")));
|
||||
+int _seteuid (uid_t) __attribute__ ((weak, alias ("__collector_seteuid")));
|
||||
|
||||
int
|
||||
__collector_seteuid (uid_t euid)
|
||||
@@ -1786,8 +1792,8 @@ __collector_seteuid (uid_t euid)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------ setreuid */
|
||||
-int setreuid () __attribute__ ((weak, alias ("__collector_setreuid")));
|
||||
-int _setreuid () __attribute__ ((weak, alias ("__collector_setreuid")));
|
||||
+int setreuid (uid_t, uid_t) __attribute__ ((weak, alias ("__collector_setreuid")));
|
||||
+int _setreuid (uid_t, uid_t) __attribute__ ((weak, alias ("__collector_setreuid")));
|
||||
|
||||
int
|
||||
__collector_setreuid (uid_t ruid, uid_t euid)
|
||||
@@ -1802,8 +1808,8 @@ __collector_setreuid (uid_t ruid, uid_t euid)
|
||||
}
|
||||
|
||||
/*-------------------------------------------------------------------- setgid */
|
||||
-int setgid () __attribute__ ((weak, alias ("__collector_setgid")));
|
||||
-int _setgid () __attribute__ ((weak, alias ("__collector_setgid")));
|
||||
+int setgid (gid_t) __attribute__ ((weak, alias ("__collector_setgid")));
|
||||
+int _setgid (gid_t) __attribute__ ((weak, alias ("__collector_setgid")));
|
||||
|
||||
int
|
||||
__collector_setgid (gid_t rgid)
|
||||
@@ -1818,8 +1824,8 @@ __collector_setgid (gid_t rgid)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------- setegid */
|
||||
-int setegid () __attribute__ ((weak, alias ("__collector_setegid")));
|
||||
-int _setegid () __attribute__ ((weak, alias ("__collector_setegid")));
|
||||
+int setegid (gid_t) __attribute__ ((weak, alias ("__collector_setegid")));
|
||||
+int _setegid (gid_t) __attribute__ ((weak, alias ("__collector_setegid")));
|
||||
|
||||
int
|
||||
__collector_setegid (gid_t egid)
|
||||
@@ -1834,8 +1840,8 @@ __collector_setegid (gid_t egid)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------ setregid */
|
||||
-int setregid () __attribute__ ((weak, alias ("__collector_setregid")));
|
||||
-int _setregid () __attribute__ ((weak, alias ("__collector_setregid")));
|
||||
+int setregid (gid_t, gid_t) __attribute__ ((weak, alias ("__collector_setregid")));
|
||||
+int _setregid (gid_t, gid_t) __attribute__ ((weak, alias ("__collector_setregid")));
|
||||
|
||||
int
|
||||
__collector_setregid (gid_t rgid, gid_t egid)
|
||||
diff --git a/gprofng/src/BaseMetricTreeNode.h b/gprofng/src/BaseMetricTreeNode.h
|
||||
index d73d244e27e..7698f9c6eaf 100644
|
||||
--- a/gprofng/src/BaseMetricTreeNode.h
|
||||
+++ b/gprofng/src/BaseMetricTreeNode.h
|
||||
@@ -85,7 +85,6 @@ private:
|
||||
|
||||
BaseMetricTreeNode *root; // root of tree
|
||||
BaseMetricTreeNode *parent; // my parent
|
||||
- bool aggregation; // value is based on children's values
|
||||
char *name; // bm->get_cmd() for metrics, unique string otherwise
|
||||
char *uname; // user-visible text
|
||||
char *unit; // see UNIT_* defines
|
||||
diff --git a/gprofng/src/Dbe.cc b/gprofng/src/Dbe.cc
|
||||
index 95daa727186..09b7f94eaa8 100644
|
||||
--- a/gprofng/src/Dbe.cc
|
||||
+++ b/gprofng/src/Dbe.cc
|
||||
@@ -9591,14 +9591,12 @@ dbeGetTLDataRepVals (VMode view_mode, hrtime_t start_ts, hrtime_t delta,
|
||||
}
|
||||
if (sampleVals != NULL)
|
||||
{
|
||||
- Sample* sample = (Sample*) packets->getObjValue (PROP_SMPLOBJ, packetIdx);
|
||||
- if (!sample || !sample->get_usage ())
|
||||
- sample = sample;
|
||||
- else
|
||||
+ Sample *sample = (Sample*) packets->getObjValue (PROP_SMPLOBJ, packetIdx);
|
||||
+ if (sample != NULL)
|
||||
{
|
||||
- PrUsage* prusage = sample->get_usage ();
|
||||
- Vector<long long> *mstateVals = prusage->getMstateValues ();
|
||||
- sampleVals->store (eventIdx, mstateVals);
|
||||
+ PrUsage *prusage = sample->get_usage ();
|
||||
+ if (prusage != NULL)
|
||||
+ sampleVals->store (eventIdx, prusage->getMstateValues ());
|
||||
}
|
||||
}
|
||||
}
|
||||
diff --git a/gprofng/src/DbeSession.cc b/gprofng/src/DbeSession.cc
|
||||
index a6808d8d8f6..3649357bc79 100644
|
||||
--- a/gprofng/src/DbeSession.cc
|
||||
+++ b/gprofng/src/DbeSession.cc
|
||||
@@ -1164,8 +1164,6 @@ DbeSession::open_experiment (Experiment *exp, char *path)
|
||||
closedir (exp_dir);
|
||||
exp_names->sort (dir_name_cmp);
|
||||
Experiment **t_exp_list = new Experiment *[exp_names->size ()];
|
||||
- int nsubexps = 0;
|
||||
-
|
||||
for (int j = 0, jsz = exp_names->size (); j < jsz; j++)
|
||||
{
|
||||
t_exp_list[j] = NULL;
|
||||
@@ -1222,7 +1220,6 @@ DbeSession::open_experiment (Experiment *exp, char *path)
|
||||
dexp->open (dpath);
|
||||
append (dexp);
|
||||
t_exp_list[j] = dexp;
|
||||
- nsubexps++;
|
||||
dexp->set_clock (exp->clock);
|
||||
|
||||
// DbeView add_experiment() is split into two parts
|
||||
diff --git a/gprofng/src/Disasm.cc b/gprofng/src/Disasm.cc
|
||||
index e41bf679292..19f2174d536 100644
|
||||
--- a/gprofng/src/Disasm.cc
|
||||
+++ b/gprofng/src/Disasm.cc
|
||||
@@ -49,7 +49,6 @@ struct DisContext
|
||||
};
|
||||
|
||||
static const int MAX_DISASM_STR = 2048;
|
||||
-static const int MAX_INSTR_SIZE = 8;
|
||||
|
||||
Disasm::Disasm (char *fname)
|
||||
{
|
||||
diff --git a/gprofng/src/Experiment.cc b/gprofng/src/Experiment.cc
|
||||
index a1f78fc0cde..627a755c88c 100644
|
||||
--- a/gprofng/src/Experiment.cc
|
||||
+++ b/gprofng/src/Experiment.cc
|
||||
@@ -1937,8 +1937,6 @@ private:
|
||||
}
|
||||
|
||||
Experiment *exp;
|
||||
- char *hostname;
|
||||
- hrtime_t time, tstamp;
|
||||
};
|
||||
|
||||
void
|
||||
diff --git a/gprofng/src/HashMap.h b/gprofng/src/HashMap.h
|
||||
index 918c0dc95f9..c5fdd345ba8 100644
|
||||
--- a/gprofng/src/HashMap.h
|
||||
+++ b/gprofng/src/HashMap.h
|
||||
@@ -78,9 +78,8 @@ copy_key (uint64_t a)
|
||||
}
|
||||
|
||||
template<> inline void
|
||||
-delete_key (uint64_t a)
|
||||
+delete_key (uint64_t)
|
||||
{
|
||||
- a = a;
|
||||
}
|
||||
|
||||
template<> inline int
|
||||
diff --git a/gprofng/src/IOActivity.h b/gprofng/src/IOActivity.h
|
||||
index cf462cf8d55..f3a22ada6b1 100644
|
||||
--- a/gprofng/src/IOActivity.h
|
||||
+++ b/gprofng/src/IOActivity.h
|
||||
@@ -78,7 +78,6 @@ private:
|
||||
Hist_data *hist_data_file_all;
|
||||
Hist_data *hist_data_vfd_all;
|
||||
Hist_data *hist_data_callstack_all;
|
||||
- Hist_data *hist_data_callstack;
|
||||
|
||||
DbeView *dbev;
|
||||
};
|
||||
diff --git a/gprofng/src/collctrl.cc b/gprofng/src/collctrl.cc
|
||||
index 029c0387f19..c0234130f00 100644
|
||||
--- a/gprofng/src/collctrl.cc
|
||||
+++ b/gprofng/src/collctrl.cc
|
||||
@@ -880,9 +880,7 @@ Coll_Ctrl::set_clkprof (const char *string, char** warn)
|
||||
double dval = strtod (string, &endchar);
|
||||
if (*endchar == 'm' || *endchar == 0) /* user specified milliseconds */
|
||||
dval = dval * 1000.;
|
||||
- else if (*endchar == 'u') /* user specified microseconds */
|
||||
- dval = dval;
|
||||
- else
|
||||
+ else if (*endchar != 'u')
|
||||
return dbe_sprintf (GTXT ("Unrecognized clock-profiling interval `%s'\n"), string);
|
||||
nclkprof_timer = (int) (dval + 0.5);
|
||||
}
|
||||
@@ -2791,7 +2789,7 @@ Coll_Ctrl::get (char * control)
|
||||
}
|
||||
if (!strncmp (control, ipc_str_javaprof, len))
|
||||
{
|
||||
- if ((java_mode == 0))
|
||||
+ if (java_mode == 0)
|
||||
return strdup (ipc_str_off);
|
||||
return strdup (ipc_str_on);
|
||||
}
|
||||
@@ -2807,7 +2805,7 @@ Coll_Ctrl::get (char * control)
|
||||
}
|
||||
if (!strncmp (control, ipc_str_sample_sig, len))
|
||||
{
|
||||
- if ((sample_sig == 0))
|
||||
+ if (sample_sig == 0)
|
||||
return strdup (ipc_str_off);
|
||||
char *str_signal = find_signal_name (sample_sig);
|
||||
if (str_signal != NULL)
|
||||
@@ -2841,15 +2839,15 @@ Coll_Ctrl::get (char * control)
|
||||
}
|
||||
if (!strncmp (control, ipc_str_iotrace, len))
|
||||
{
|
||||
- if ((iotrace_enabled == 0))
|
||||
+ if (iotrace_enabled == 0)
|
||||
return strdup (ipc_str_off);
|
||||
return strdup (ipc_str_on);
|
||||
}
|
||||
if (!strncmp (control, ipc_str_count, len))
|
||||
{
|
||||
- if ((count_enabled == 0))
|
||||
+ if (count_enabled == 0)
|
||||
return strdup (ipc_str_off);
|
||||
- if ((count_enabled < 0))
|
||||
+ if (count_enabled < 0)
|
||||
return strdup ("on\nstatic");
|
||||
return strdup (ipc_str_on);
|
||||
}
|
||||
diff --git a/gprofng/src/collctrl.h b/gprofng/src/collctrl.h
|
||||
index a41647440ac..e2a8e450890 100644
|
||||
--- a/gprofng/src/collctrl.h
|
||||
+++ b/gprofng/src/collctrl.h
|
||||
@@ -272,7 +272,6 @@ private:
|
||||
char *node_name; /* name of machine on which experiment is run */
|
||||
long ncpus; /* number of online CPUs */
|
||||
int cpu_clk_freq; /* chip clock (MHz.), as reported from processor_info */
|
||||
- int cpc_cpuver; /* chip version, as reported from libcpc */
|
||||
long sys_resolution; /* system clock resolution */
|
||||
int sample_period; /* period for sampling, seconds */
|
||||
int sample_default; /* if period for sampling set by default */
|
||||
diff --git a/gprofng/src/collector_module.h b/gprofng/src/collector_module.h
|
||||
index bb48eadb9f8..ebcdbca561f 100644
|
||||
--- a/gprofng/src/collector_module.h
|
||||
+++ b/gprofng/src/collector_module.h
|
||||
@@ -40,12 +40,12 @@ struct tm;
|
||||
* If you add any, please put it in the right place */
|
||||
typedef struct CollectorUtilFuncs
|
||||
{
|
||||
- int (*access)();
|
||||
+ int (*access)(const char *, int);
|
||||
int (*atoi)(const char *nptr);
|
||||
void *(*calloc)(size_t nelem, size_t elsize);
|
||||
int (*clearenv)(void);
|
||||
int (*close)(int);
|
||||
- int (*closedir)();
|
||||
+ int (*closedir)(DIR *);
|
||||
int (*execv)(const char *path, char *const argv[]);
|
||||
void (*exit)(int status);
|
||||
int (*fclose)(FILE *stream);
|
||||
@@ -66,20 +66,20 @@ typedef struct CollectorUtilFuncs
|
||||
off_t (*lseek)(int fd, off_t offset, int whence);
|
||||
void *(*malloc)(size_t size);
|
||||
void *(*memset)(void *s1, int c, size_t n);
|
||||
- int (*mkdir)();
|
||||
+ int (*mkdir)(const char *, mode_t);
|
||||
time_t (*mktime)(struct tm *timeptr);
|
||||
void *(*mmap)(void *, size_t, int, int, int, off_t);
|
||||
- void *(*mmap64_)();
|
||||
- int (*munmap)();
|
||||
+ void *(*mmap64_)(void *, size_t, int, int, int, off_t);
|
||||
+ int (*munmap)(void *, size_t);
|
||||
int (*open)(const char *, int, ...);
|
||||
int (*open_bare)(const char *, int, ...);
|
||||
- DIR *(*opendir)();
|
||||
+ DIR *(*opendir)(const char *);
|
||||
int (*pclose)(FILE *stream);
|
||||
FILE *(*popen)(const char *command, const char *mode);
|
||||
int (*putenv)(char *string);
|
||||
- ssize_t (*pwrite)();
|
||||
- ssize_t (*pwrite64_)();
|
||||
- ssize_t (*read)();
|
||||
+ ssize_t (*pwrite)(int, const void *, size_t, off_t);
|
||||
+ ssize_t (*pwrite64_)(int, const void *, size_t, off_t);
|
||||
+ ssize_t (*read)(int, void *, size_t);
|
||||
int (*setenv)(const char *name, const char *value, int overwrite);
|
||||
int (*sigfillset)(sigset_t *set);
|
||||
int (*sigprocmask)(int how, const sigset_t *set, sigset_t *oldset);
|
||||
@@ -112,7 +112,7 @@ typedef struct CollectorUtilFuncs
|
||||
int (*unsetenv)(const char *name);
|
||||
int (*vsnprintf)(char *str, size_t size, const char *format, va_list ap);
|
||||
pid_t (*waitpid)(pid_t pid, int *stat_loc, int options);
|
||||
- ssize_t (*write)();
|
||||
+ ssize_t (*write)(int, void *, size_t);
|
||||
double (*atof)();
|
||||
void *n_a;
|
||||
} CollectorUtilFuncs;
|
||||
diff --git a/gprofng/src/gp-display-src.cc b/gprofng/src/gp-display-src.cc
|
||||
index 200e6080d2e..24af375edf1 100644
|
||||
--- a/gprofng/src/gp-display-src.cc
|
||||
+++ b/gprofng/src/gp-display-src.cc
|
||||
@@ -75,14 +75,6 @@ private:
|
||||
bool v_opt;
|
||||
int multiple;
|
||||
char *str_compcom;
|
||||
- bool hex_visible;
|
||||
- int src_visible;
|
||||
- int vis_src;
|
||||
- int vis_dis;
|
||||
- int threshold_src;
|
||||
- int threshold_dis;
|
||||
- int threshold;
|
||||
- int vis_bits;
|
||||
};
|
||||
|
||||
static int
|
||||
diff --git a/gprofng/src/gp-print.h b/gprofng/src/gp-print.h
|
||||
index 1b748ea60a3..1a8ad3b6c13 100644
|
||||
--- a/gprofng/src/gp-print.h
|
||||
+++ b/gprofng/src/gp-print.h
|
||||
@@ -19,7 +19,7 @@
|
||||
MA 02110-1301, USA. */
|
||||
|
||||
#ifndef _GP_PRINT_H
|
||||
-#define _ER_PRINT_H
|
||||
+#define _GP_PRINT_H
|
||||
|
||||
#include "Command.h"
|
||||
#include "DbeApplication.h"
|
||||
diff --git a/gprofng/src/hwc_intel_icelake.h b/gprofng/src/hwc_intel_icelake.h
|
||||
index 46f4ac5005f..4fe2e26f63b 100644
|
||||
--- a/gprofng/src/hwc_intel_icelake.h
|
||||
+++ b/gprofng/src/hwc_intel_icelake.h
|
||||
@@ -24,8 +24,10 @@
|
||||
#define SH(val, n) (((unsigned long long) (val)) << n)
|
||||
#define I(nm, event, umask, edge, cmask, inv, \
|
||||
offcore_rsp, ldlat, frontend, period, mtr) \
|
||||
- INIT_HWC(nm, mtr, SH(event, 0) | SH(umask, 8) | SH(edge, 18) \
|
||||
- | SH(cmask, 24) | SH(inv, 23), PERF_TYPE_RAW), \
|
||||
+ .use_perf_event_type = 1, .type = PERF_TYPE_RAW, \
|
||||
+ .name = (nm), .metric = (mtr), .reg_num = REGNO_ANY, \
|
||||
+ .config = SH(event, 0) | SH(umask, 8) | SH(edge, 18) | SH(cmask, 24) \
|
||||
+ | SH(inv, 23), \
|
||||
.config1 = SH(offcore_rsp, 0) | SH(ldlat, 0) | SH(frontend, 0), \
|
||||
.val = period
|
||||
|
||||
diff --git a/gprofng/src/util.cc b/gprofng/src/util.cc
|
||||
index 201f7088b66..228140b61ae 100644
|
||||
--- a/gprofng/src/util.cc
|
||||
+++ b/gprofng/src/util.cc
|
||||
@@ -741,17 +741,13 @@ get_relative_link (const char *path_from, const char *path_to)
|
||||
s2 = canonical_path (s2);
|
||||
long l = dbe_sstrlen (s1);
|
||||
// try to find common directories
|
||||
- int common_slashes = 0;
|
||||
int last_common_slash = -1;
|
||||
for (int i = 0; i < l; i++)
|
||||
{
|
||||
- if (s1[i] != s2[i]) break;
|
||||
- if (s1[i] == 0) break;
|
||||
+ if (s1[i] != s2[i] || s1[i] == 0)
|
||||
+ break;
|
||||
if (s1[i] == '/')
|
||||
- {
|
||||
- common_slashes++;
|
||||
- last_common_slash = i;
|
||||
- }
|
||||
+ last_common_slash = i;
|
||||
}
|
||||
// find slashes in remaining path_to
|
||||
int slashes = 0;
|
||||
--
|
||||
2.50.1
|
||||
|
||||
+619
@@ -0,0 +1,619 @@
|
||||
From a5be89126b9bee78224be842e3086ce99dc045e6 Mon Sep 17 00:00:00 2001
|
||||
From: Sam James <sam@gentoo.org>
|
||||
Date: Sat, 16 Nov 2024 05:13:48 +0000
|
||||
Subject: [PATCH] gprofng: fix -std=gnu23 compatibility wrt unprototyped
|
||||
functions
|
||||
|
||||
C23 removes support for unprototyped functions. Fix function pointer types
|
||||
accordingly.
|
||||
|
||||
This does not fix all instances, there's a few left as I commented on in
|
||||
PR32374 (e.g. setitimer which I have a local workaround for but it involves
|
||||
a glibc implementation detail; the Linaro precommit CI tester pointed that
|
||||
out too, so dropped that).
|
||||
|
||||
ChangeLog:
|
||||
PR gprofng/32374
|
||||
|
||||
* libcollector/collector.c (collector_sample): Fix prototype.
|
||||
* libcollector/envmgmt.c (putenv): Ditto.
|
||||
(_putenv): Ditto.
|
||||
(__collector_putenv): Ditto.
|
||||
(setenv): Ditto.
|
||||
(_setenv): Ditto.
|
||||
(__collector_setenv): Ditto.
|
||||
(unsetenv): Ditto.
|
||||
(_unsetenv): Ditto.
|
||||
(__collector_unsetenv): Ditto.
|
||||
* libcollector/jprofile.c (open_experiment): Ditto.
|
||||
(__collector_jprofile_enable_synctrace): Ditto.
|
||||
(jprof_find_asyncgetcalltrace): Ditto.
|
||||
* libcollector/libcol_util.c (__collector_util_init): Ditto.
|
||||
(ARCH): Ditto.
|
||||
* libcollector/mmaptrace.c (collector_func_load): Ditto.
|
||||
(collector_func_unload): Ditto.
|
||||
* libcollector/unwind.c (__collector_ext_unwind_init): Ditto.
|
||||
* src/collector_module.h: Ditto.
|
||||
|
||||
Upstream: a2f774427e078f3da2c06bdea25f77a61979a695
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
gprofng/libcollector/collector.c | 2 +-
|
||||
gprofng/libcollector/dispatcher.c | 1 -
|
||||
gprofng/libcollector/envmgmt.c | 24 ++++-----
|
||||
gprofng/libcollector/jprofile.c | 10 ++--
|
||||
gprofng/libcollector/libcol_util.c | 84 +++++++++++++++---------------
|
||||
gprofng/libcollector/mmaptrace.c | 4 +-
|
||||
gprofng/libcollector/unwind.c | 2 +-
|
||||
gprofng/src/collector_module.h | 2 +-
|
||||
8 files changed, 64 insertions(+), 65 deletions(-)
|
||||
|
||||
diff --git a/gprofng/libcollector/collector.c b/gprofng/libcollector/collector.c
|
||||
index 2ff95e58fde..3cab346e7dc 100644
|
||||
--- a/gprofng/libcollector/collector.c
|
||||
+++ b/gprofng/libcollector/collector.c
|
||||
@@ -1578,7 +1578,7 @@ __collector_resume_experiment ()
|
||||
}
|
||||
|
||||
/* Code to support Samples and Pause/Resume */
|
||||
-void collector_sample () __attribute__ ((weak, alias ("__collector_sample")));
|
||||
+void collector_sample (char *name) __attribute__ ((weak, alias ("__collector_sample")));
|
||||
void
|
||||
__collector_sample (char *name)
|
||||
{
|
||||
diff --git a/gprofng/libcollector/dispatcher.c b/gprofng/libcollector/dispatcher.c
|
||||
index f7cd46e7e6b..4eda18ec324 100644
|
||||
--- a/gprofng/libcollector/dispatcher.c
|
||||
+++ b/gprofng/libcollector/dispatcher.c
|
||||
@@ -1281,4 +1281,3 @@ __collector_ext_clone_pthread (int (*fn)(void *), void *child_stack, int flags,
|
||||
int sigprocmask (int, const sigset_t*, sigset_t*) __attribute__ ((weak, alias ("__collector_sigprocmask")));
|
||||
int thr_sigsetmask (int, const sigset_t*, sigset_t*) __attribute__ ((weak, alias ("__collector_thr_sigsetmask")));
|
||||
int setitimer () __attribute__ ((weak, alias ("_setitimer")));
|
||||
-
|
||||
diff --git a/gprofng/libcollector/envmgmt.c b/gprofng/libcollector/envmgmt.c
|
||||
index a399c0d0cb4..f2bf2c41bfb 100644
|
||||
--- a/gprofng/libcollector/envmgmt.c
|
||||
+++ b/gprofng/libcollector/envmgmt.c
|
||||
@@ -685,8 +685,8 @@ __collector_env_update (char *envp[])
|
||||
|
||||
|
||||
/*------------------------------------------------------------- putenv */
|
||||
-int putenv () __attribute__ ((weak, alias ("__collector_putenv")));
|
||||
-int _putenv () __attribute__ ((weak, alias ("__collector_putenv")));
|
||||
+int putenv (char*) __attribute__ ((weak, alias ("__collector_putenv")));
|
||||
+int _putenv (char*) __attribute__ ((weak, alias ("__collector_putenv")));
|
||||
|
||||
int
|
||||
__collector_putenv (char * string)
|
||||
@@ -694,9 +694,9 @@ __collector_putenv (char * string)
|
||||
if (CALL_UTIL (putenv) == __collector_putenv ||
|
||||
CALL_UTIL (putenv) == NULL)
|
||||
{ // __collector_libc_funcs_init failed
|
||||
- CALL_UTIL (putenv) = (int(*)())dlsym (RTLD_NEXT, "putenv");
|
||||
+ CALL_UTIL (putenv) = (int(*)(char*))dlsym (RTLD_NEXT, "putenv");
|
||||
if (CALL_UTIL (putenv) == NULL || CALL_UTIL (putenv) == __collector_putenv)
|
||||
- CALL_UTIL (putenv) = (int(*)())dlsym (RTLD_DEFAULT, "putenv");
|
||||
+ CALL_UTIL (putenv) = (int(*)(char*))dlsym (RTLD_DEFAULT, "putenv");
|
||||
if (CALL_UTIL (putenv) == NULL || CALL_UTIL (putenv) == __collector_putenv)
|
||||
{
|
||||
TprintfT (DBG_LT2, "__collector_putenv(): ERROR: no pointer found.\n");
|
||||
@@ -712,8 +712,8 @@ __collector_putenv (char * string)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------- setenv */
|
||||
-int setenv () __attribute__ ((weak, alias ("__collector_setenv")));
|
||||
-int _setenv () __attribute__ ((weak, alias ("__collector_setenv")));
|
||||
+int setenv (const char*, const char*, int) __attribute__ ((weak, alias ("__collector_setenv")));
|
||||
+int _setenv (const char*, const char*, int) __attribute__ ((weak, alias ("__collector_setenv")));
|
||||
|
||||
int
|
||||
__collector_setenv (const char *name, const char *value, int overwrite)
|
||||
@@ -721,9 +721,9 @@ __collector_setenv (const char *name, const char *value, int overwrite)
|
||||
if (CALL_UTIL (setenv) == __collector_setenv ||
|
||||
CALL_UTIL (setenv) == NULL)
|
||||
{ // __collector_libc_funcs_init failed
|
||||
- CALL_UTIL (setenv) = (int(*)())dlsym (RTLD_NEXT, "setenv");
|
||||
+ CALL_UTIL (setenv) = (int(*)(const char*, const char*, int))dlsym (RTLD_NEXT, "setenv");
|
||||
if (CALL_UTIL (setenv) == NULL || CALL_UTIL (setenv) == __collector_setenv)
|
||||
- CALL_UTIL (setenv) = (int(*)())dlsym (RTLD_DEFAULT, "setenv");
|
||||
+ CALL_UTIL (setenv) = (int(*)(const char*, const char*, int))dlsym (RTLD_DEFAULT, "setenv");
|
||||
if (CALL_UTIL (setenv) == NULL || CALL_UTIL (setenv) == __collector_setenv)
|
||||
{
|
||||
TprintfT (DBG_LT2, "__collector_setenv(): ERROR: no pointer found.\n");
|
||||
@@ -758,8 +758,8 @@ __collector_setenv (const char *name, const char *value, int overwrite)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------- unsetenv */
|
||||
-int unsetenv () __attribute__ ((weak, alias ("__collector_unsetenv")));
|
||||
-int _unsetenv () __attribute__ ((weak, alias ("__collector_unsetenv")));
|
||||
+int unsetenv (const char*) __attribute__ ((weak, alias ("__collector_unsetenv")));
|
||||
+int _unsetenv (const char*) __attribute__ ((weak, alias ("__collector_unsetenv")));
|
||||
|
||||
int
|
||||
__collector_unsetenv (const char *name)
|
||||
@@ -767,9 +767,9 @@ __collector_unsetenv (const char *name)
|
||||
if (CALL_UTIL (unsetenv) == __collector_unsetenv ||
|
||||
CALL_UTIL (unsetenv) == NULL)
|
||||
{ // __collector_libc_funcs_init failed
|
||||
- CALL_UTIL (unsetenv) = (int(*)())dlsym (RTLD_NEXT, "unsetenv");
|
||||
+ CALL_UTIL (unsetenv) = (int(*)(const char*))dlsym (RTLD_NEXT, "unsetenv");
|
||||
if (CALL_UTIL (unsetenv) == NULL || CALL_UTIL (unsetenv) == __collector_unsetenv)
|
||||
- CALL_UTIL (unsetenv) = (int(*)())dlsym (RTLD_DEFAULT, "unsetenv");
|
||||
+ CALL_UTIL (unsetenv) = (int(*)(const char*))dlsym (RTLD_DEFAULT, "unsetenv");
|
||||
if (CALL_UTIL (unsetenv) == NULL || CALL_UTIL (unsetenv) == __collector_unsetenv)
|
||||
{
|
||||
TprintfT (DBG_LT2, "__collector_unsetenv(): ERROR: no pointer found.\n");
|
||||
diff --git a/gprofng/libcollector/jprofile.c b/gprofng/libcollector/jprofile.c
|
||||
index cd498bed0a3..d8f2d049a84 100644
|
||||
--- a/gprofng/libcollector/jprofile.c
|
||||
+++ b/gprofng/libcollector/jprofile.c
|
||||
@@ -99,8 +99,8 @@ static void rwrite (int fd, const void *buf, size_t nbyte);
|
||||
static void addToDynamicArchive (const char* name, const unsigned char* class_data, int class_data_len);
|
||||
static void (*AsyncGetCallTrace)(JVMPI_CallTrace*, jint, ucontext_t*) = NULL;
|
||||
static void (*collector_heap_record)(int, int, void*) = NULL;
|
||||
-static void (*collector_jsync_begin)() = NULL;
|
||||
-static void (*collector_jsync_end)(hrtime_t, void *) = NULL;
|
||||
+static void (*collector_jsync_begin)(void) = NULL;
|
||||
+static void (*collector_jsync_end)(hrtime_t, void*) = NULL;
|
||||
|
||||
#define gethrtime collector_interface->getHiResTime
|
||||
|
||||
@@ -224,7 +224,7 @@ open_experiment (const char *exp)
|
||||
else if (__collector_strStartWith (args, "s:") == 0)
|
||||
{
|
||||
java_sync_mode = 1;
|
||||
- collector_jsync_begin = (void(*)(hrtime_t, void *))dlsym (RTLD_DEFAULT, "__collector_jsync_begin");
|
||||
+ collector_jsync_begin = (void(*)(void))dlsym (RTLD_DEFAULT, "__collector_jsync_begin");
|
||||
collector_jsync_end = (void(*)(hrtime_t, void *))dlsym (RTLD_DEFAULT, "__collector_jsync_end");
|
||||
}
|
||||
#endif
|
||||
@@ -249,7 +249,7 @@ __collector_jprofile_enable_synctrace ()
|
||||
return;
|
||||
}
|
||||
java_sync_mode = 1;
|
||||
- collector_jsync_begin = (void(*)(hrtime_t, void *))dlsym (RTLD_DEFAULT, "__collector_jsync_begin");
|
||||
+ collector_jsync_begin = (void(*)(void))dlsym (RTLD_DEFAULT, "__collector_jsync_begin");
|
||||
collector_jsync_end = (void(*)(hrtime_t, void *))dlsym (RTLD_DEFAULT, "__collector_jsync_end");
|
||||
TprintfT (DBG_LT1, "jprofile: turning on Java synctrace, and requesting events\n");
|
||||
}
|
||||
@@ -1123,7 +1123,7 @@ jprof_find_asyncgetcalltrace ()
|
||||
{
|
||||
void *jvmhandle;
|
||||
if (__collector_VM_ReadByteInstruction == NULL)
|
||||
- __collector_VM_ReadByteInstruction = (int(*)()) dlsym (RTLD_DEFAULT, "Async_VM_ReadByteInstruction");
|
||||
+ __collector_VM_ReadByteInstruction = (int(*)(unsigned char*)) dlsym (RTLD_DEFAULT, "Async_VM_ReadByteInstruction");
|
||||
|
||||
/* look for stack unwind function using default path */
|
||||
AsyncGetCallTrace = (void (*)(JVMPI_CallTrace*, jint, ucontext_t*))
|
||||
diff --git a/gprofng/libcollector/libcol_util.c b/gprofng/libcollector/libcol_util.c
|
||||
index baac15db5c4..a73488e3f60 100644
|
||||
--- a/gprofng/libcollector/libcol_util.c
|
||||
+++ b/gprofng/libcollector/libcol_util.c
|
||||
@@ -1114,7 +1114,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "munmap");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.munmap = (int(*)())ptr;
|
||||
+ __collector_util_funcs.munmap = (int(*)(void *, size_t))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT munmap: %s\n", dlerror ());
|
||||
@@ -1123,7 +1123,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "close");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.close = (int(*)())ptr;
|
||||
+ __collector_util_funcs.close = (int(*)(int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT close: %s\n", dlerror ());
|
||||
@@ -1158,7 +1158,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "close");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.close = (int(*)())ptr;
|
||||
+ __collector_util_funcs.close = (int(*)(int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT close: %s\n", dlerror ());
|
||||
@@ -1167,7 +1167,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "read");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.read = (ssize_t (*)())ptr;
|
||||
+ __collector_util_funcs.read = (ssize_t (*)(int, void*, size_t))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT read: %s\n", dlerror ());
|
||||
@@ -1176,7 +1176,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "write");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.write = (ssize_t (*)())ptr;
|
||||
+ __collector_util_funcs.write = (ssize_t (*)(int, void*, size_t))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT write: %s\n", dlerror ());
|
||||
@@ -1186,14 +1186,14 @@ __collector_util_init ()
|
||||
#if ARCH(Intel) && WSIZE(32)
|
||||
ptr = dlvsym (libc, "pwrite", "GLIBC_2.2"); // it is in /lib/libpthread.so.0
|
||||
if (ptr)
|
||||
- __collector_util_funcs.pwrite = (ssize_t (*)())ptr;
|
||||
+ __collector_util_funcs.pwrite = (ssize_t (*)(int, void*, size_t, off_t))ptr;
|
||||
else
|
||||
{
|
||||
Tprintf (DBG_LT0, "libcol_util: WARNING: dlvsym for %s@%s failed. Using dlsym() instead.", "pwrite", "GLIBC_2.2");
|
||||
#endif /* ARCH(Intel) && WSIZE(32) */
|
||||
ptr = dlsym (libc, "pwrite");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.pwrite = (ssize_t (*)())ptr;
|
||||
+ __collector_util_funcs.pwrite = (ssize_t (*)(int, const void*, size_t, off_t))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT pwrite: %s\n", dlerror ());
|
||||
@@ -1213,7 +1213,7 @@ __collector_util_init ()
|
||||
#endif /* ARCH(Intel) && WSIZE(32) */
|
||||
ptr = dlsym (libc, "pwrite64");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.pwrite64_ = (ssize_t (*)())ptr;
|
||||
+ __collector_util_funcs.pwrite64_ = (ssize_t (*)(int, const void*, size_t, off_t))ptr;
|
||||
else
|
||||
__collector_util_funcs.pwrite64_ = __collector_util_funcs.pwrite;
|
||||
#if ARCH(Intel) && WSIZE(32)
|
||||
@@ -1222,7 +1222,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "lseek");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.lseek = (off_t (*)())ptr;
|
||||
+ __collector_util_funcs.lseek = (off_t (*)(int, off_t, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT lseek: %s\n", dlerror ());
|
||||
@@ -1231,7 +1231,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "access");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.access = (int(*)())ptr;
|
||||
+ __collector_util_funcs.access = (int(*)(const char*, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT access: %s\n", dlerror ());
|
||||
@@ -1240,7 +1240,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "mkdir");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.mkdir = (int(*)())ptr;
|
||||
+ __collector_util_funcs.mkdir = (int(*)(const char*, mode_t))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT mkdir: %s\n", dlerror ());
|
||||
@@ -1249,7 +1249,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "opendir");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.opendir = (DIR * (*)())ptr;
|
||||
+ __collector_util_funcs.opendir = (DIR * (*)(const char*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT opendir: %s\n", dlerror ());
|
||||
@@ -1258,7 +1258,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "closedir");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.closedir = (int(*)())ptr;
|
||||
+ __collector_util_funcs.closedir = (int(*)(DIR*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT closedir: %s\n", dlerror ());
|
||||
@@ -1267,7 +1267,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "execv");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.execv = (int(*)())ptr;
|
||||
+ __collector_util_funcs.execv = (int(*)(const char*, char* const*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT execv: %s\n", dlerror ());
|
||||
@@ -1276,7 +1276,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "exit");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.exit = (void(*)())ptr;
|
||||
+ __collector_util_funcs.exit = (void(*)(int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT exit: %s\n", dlerror ());
|
||||
@@ -1285,7 +1285,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "vfork");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.vfork = (pid_t (*)())ptr;
|
||||
+ __collector_util_funcs.vfork = (pid_t (*)(void))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT vfork: %s\n", dlerror ());
|
||||
@@ -1294,7 +1294,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "waitpid");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.waitpid = (pid_t (*)())ptr;
|
||||
+ __collector_util_funcs.waitpid = (pid_t (*)(pid_t, int*, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT waitpid: %s\n", dlerror ());
|
||||
@@ -1313,7 +1313,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "getcontext");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.getcontext = (int(*)())ptr;
|
||||
+ __collector_util_funcs.getcontext = (int(*)(ucontext_t*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT getcontext: %s\n", dlerror ());
|
||||
@@ -1331,7 +1331,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "putenv");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.putenv = (int(*)())ptr;
|
||||
+ __collector_util_funcs.putenv = (int(*)(char*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT putenv: %s\n", dlerror ());
|
||||
@@ -1340,7 +1340,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "getenv");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.getenv = (char*(*)())ptr;
|
||||
+ __collector_util_funcs.getenv = (char*(*)(const char*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT getenv: %s\n", dlerror ());
|
||||
@@ -1349,7 +1349,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "time");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.time = (time_t (*)())ptr;
|
||||
+ __collector_util_funcs.time = (time_t (*)(time_t*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT time: %s\n", dlerror ());
|
||||
@@ -1358,7 +1358,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "mktime");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.mktime = (time_t (*)())ptr;
|
||||
+ __collector_util_funcs.mktime = (time_t (*)(struct tm*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT mktime: %s\n", dlerror ());
|
||||
@@ -1372,7 +1372,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "gmtime_r");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.gmtime_r = (struct tm * (*)())ptr;
|
||||
+ __collector_util_funcs.gmtime_r = (struct tm * (*)(const time_t*, struct tm*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT gmtime_r: %s\n", dlerror ());
|
||||
@@ -1381,7 +1381,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "strtol");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.strtol = (long (*)())ptr;
|
||||
+ __collector_util_funcs.strtol = (long (*)(const char*, char**, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strtol: %s\n", dlerror ());
|
||||
@@ -1390,7 +1390,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "strtoll");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.strtoll = (long long (*)())ptr;
|
||||
+ __collector_util_funcs.strtoll = (long long (*)(const char*, char**, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strtoll: %s\n", dlerror ());
|
||||
@@ -1402,7 +1402,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "setenv");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.setenv = (int(*)())ptr;
|
||||
+ __collector_util_funcs.setenv = (int(*)(const char*, const char*, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT setenv: %s\n", dlerror ());
|
||||
@@ -1411,7 +1411,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "unsetenv");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.unsetenv = (int(*)())ptr;
|
||||
+ __collector_util_funcs.unsetenv = (int(*)(const char*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT unsetenv: %s\n", dlerror ());
|
||||
@@ -1507,7 +1507,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "pclose");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.pclose = (int(*)())ptr;
|
||||
+ __collector_util_funcs.pclose = (int(*)(FILE*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT pclose: %s\n", dlerror ());
|
||||
@@ -1516,7 +1516,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "fgets");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.fgets = (char*(*)())ptr;
|
||||
+ __collector_util_funcs.fgets = (char*(*)(char*, int, FILE*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT fgets: %s\n", dlerror ());
|
||||
@@ -1543,7 +1543,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "vsnprintf");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.vsnprintf = (int(*)())ptr;
|
||||
+ __collector_util_funcs.vsnprintf = (int(*)(char*, size_t, const char*, ...))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT vsnprintf: %s\n", dlerror ());
|
||||
@@ -1552,7 +1552,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "atoi");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.atoi = (int(*)())ptr;
|
||||
+ __collector_util_funcs.atoi = (int(*)(const char*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT atoi: %s\n", dlerror ());
|
||||
@@ -1561,7 +1561,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "calloc");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.calloc = (void*(*)())ptr;
|
||||
+ __collector_util_funcs.calloc = (void*(*)(size_t, size_t))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT calloc: %s\n", dlerror ());
|
||||
@@ -1571,7 +1571,7 @@ __collector_util_init ()
|
||||
ptr = dlsym (libc, "free");
|
||||
if (ptr)
|
||||
{
|
||||
- __collector_util_funcs.free = (void(*)())ptr;
|
||||
+ __collector_util_funcs.free = (void(*)(void*))ptr;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -1581,7 +1581,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "strdup");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.libc_strdup = (char*(*)())ptr;
|
||||
+ __collector_util_funcs.libc_strdup = (char*(*)(const char*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strdup: %s\n", dlerror ());
|
||||
@@ -1594,7 +1594,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "strerror");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.strerror = (char*(*)())ptr;
|
||||
+ __collector_util_funcs.strerror = (char*(*)(int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strerror: %s\n", dlerror ());
|
||||
@@ -1602,7 +1602,7 @@ __collector_util_init ()
|
||||
}
|
||||
ptr = dlsym (libc, "strerror_r");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.strerror_r = (int(*)())ptr;
|
||||
+ __collector_util_funcs.strerror_r = (int(*)(int, char*, size_t))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strerror_r: %s\n", dlerror ());
|
||||
@@ -1610,7 +1610,7 @@ __collector_util_init ()
|
||||
}
|
||||
ptr = dlsym (libc, "strspn");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.strspn = (size_t (*)())ptr;
|
||||
+ __collector_util_funcs.strspn = (size_t (*)(const char*, const char*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strspn: %s\n", dlerror ());
|
||||
@@ -1619,7 +1619,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "strtoul");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.strtoul = (unsigned long int(*)())ptr;
|
||||
+ __collector_util_funcs.strtoul = (unsigned long int(*)(const char*, char**, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strtoul: %s\n", dlerror ());
|
||||
@@ -1628,7 +1628,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "strtoull");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.strtoull = (unsigned long long int(*)())ptr;
|
||||
+ __collector_util_funcs.strtoull = (unsigned long long int(*)(const char*, char**, int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT strtoull: %s\n", dlerror ());
|
||||
@@ -1673,7 +1673,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "sysconf");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.sysconf = (long(*)())ptr;
|
||||
+ __collector_util_funcs.sysconf = (long(*)(int))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT sysconf: %s\n", dlerror ());
|
||||
@@ -1682,7 +1682,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "sigfillset");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.sigfillset = (int(*)())ptr;
|
||||
+ __collector_util_funcs.sigfillset = (int(*)(sigset_t*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT sigfillset: %s\n", dlerror ());
|
||||
@@ -1691,7 +1691,7 @@ __collector_util_init ()
|
||||
|
||||
ptr = dlsym (libc, "sigprocmask");
|
||||
if (ptr)
|
||||
- __collector_util_funcs.sigprocmask = (int(*)())ptr;
|
||||
+ __collector_util_funcs.sigprocmask = (int(*)(int, const sigset_t*, sigset_t*))ptr;
|
||||
else
|
||||
{
|
||||
CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT sigprocmask: %s\n", dlerror ());
|
||||
diff --git a/gprofng/libcollector/mmaptrace.c b/gprofng/libcollector/mmaptrace.c
|
||||
index f07f4d76513..2a6857ab58e 100644
|
||||
--- a/gprofng/libcollector/mmaptrace.c
|
||||
+++ b/gprofng/libcollector/mmaptrace.c
|
||||
@@ -1209,7 +1209,7 @@ process_vsyscall_page ()
|
||||
/*
|
||||
* collector API for dynamic functions
|
||||
*/
|
||||
-void collector_func_load () __attribute__ ((weak, alias ("__collector_func_load")));
|
||||
+void collector_func_load (char*, char*, char*, void*, int, int, DT_lineno *) __attribute__ ((weak, alias ("__collector_func_load")));
|
||||
void
|
||||
__collector_func_load (char *name, char *alias, char *sourcename,
|
||||
void *vaddr, int size, int lntsize, DT_lineno *lntable)
|
||||
@@ -1218,7 +1218,7 @@ __collector_func_load (char *name, char *alias, char *sourcename,
|
||||
vaddr, size, lntsize, lntable);
|
||||
}
|
||||
|
||||
-void collector_func_unload () __attribute__ ((weak, alias ("__collector_func_unload")));
|
||||
+void collector_func_unload (void *vaddr) __attribute__ ((weak, alias ("__collector_func_unload")));
|
||||
void
|
||||
__collector_func_unload (void *vaddr)
|
||||
{
|
||||
diff --git a/gprofng/libcollector/unwind.c b/gprofng/libcollector/unwind.c
|
||||
index 55fa2e9e9e7..e08afa165d1 100644
|
||||
--- a/gprofng/libcollector/unwind.c
|
||||
+++ b/gprofng/libcollector/unwind.c
|
||||
@@ -421,7 +421,7 @@ __collector_ext_unwind_init (int record)
|
||||
omp_no_walk = 1;
|
||||
|
||||
if (__collector_VM_ReadByteInstruction == NULL)
|
||||
- __collector_VM_ReadByteInstruction = (int(*)()) dlsym (RTLD_DEFAULT, "Async_VM_ReadByteInstruction");
|
||||
+ __collector_VM_ReadByteInstruction = (int(*)(unsigned char*)) dlsym (RTLD_DEFAULT, "Async_VM_ReadByteInstruction");
|
||||
|
||||
#if ARCH(SPARC)
|
||||
#if WSIZE(64)
|
||||
diff --git a/gprofng/src/collector_module.h b/gprofng/src/collector_module.h
|
||||
index ebcdbca561f..fd888cd58dd 100644
|
||||
--- a/gprofng/src/collector_module.h
|
||||
+++ b/gprofng/src/collector_module.h
|
||||
@@ -110,7 +110,7 @@ typedef struct CollectorUtilFuncs
|
||||
long (*sysinfo)(int command, char *buf, long count);
|
||||
time_t (*time)(time_t *tloc);
|
||||
int (*unsetenv)(const char *name);
|
||||
- int (*vsnprintf)(char *str, size_t size, const char *format, va_list ap);
|
||||
+ int (*vsnprintf)(char *str, size_t size, const char *format, ...);
|
||||
pid_t (*waitpid)(pid_t pid, int *stat_loc, int options);
|
||||
ssize_t (*write)(int, void *, size_t);
|
||||
double (*atof)();
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -0,0 +1,199 @@
|
||||
From 9ca25799ea0e92855d19adc46634e6dd0675a0b7 Mon Sep 17 00:00:00 2001
|
||||
From: Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
|
||||
Date: Thu, 21 Nov 2024 14:48:20 -0800
|
||||
Subject: [PATCH] gprofng: fix build with -std=gnu23
|
||||
|
||||
Fix function pointer types accordingly.
|
||||
Remove unused function pointers.
|
||||
|
||||
gprofng/ChangeLog
|
||||
2024-11-21 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
|
||||
|
||||
PR gprofng/32374
|
||||
PR gprofng/32373
|
||||
* common/cpuid.c: Define ATTRIBUTE_UNUSED if necessary.
|
||||
* libcollector/libcol_util.c (sysinfo): Remove unused pointer.
|
||||
* src/collector_module.h: Likewise.
|
||||
* libcollector/dispatcher.c (setitimer): Fix prototype.
|
||||
* libcollector/linetrace.c (system, grantpt, ptsname): Likewise.
|
||||
* testsuite/gprofng.display/mttest/mttest.c (dump_arrays): Likewise.
|
||||
* testsuite/gprofng.display/synprog/endcases.c (xinline_code,
|
||||
s_inline_code): Likewise.
|
||||
* testsuite/gprofng.display/synprog/inc_inline.h (ext_inline_code):
|
||||
Likewise.
|
||||
* testsuite/gprofng.display/synprog/synprog.c (doabort): Rename nullptr.
|
||||
|
||||
Upstream: 4e943705e3e8a5a9448d087502bcb390a694ad02
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
gprofng/common/cpuid.c | 2 ++
|
||||
gprofng/libcollector/dispatcher.c | 2 +-
|
||||
gprofng/libcollector/libcol_util.c | 9 ---------
|
||||
gprofng/libcollector/linetrace.c | 10 +++++-----
|
||||
gprofng/src/collector_module.h | 1 -
|
||||
gprofng/testsuite/gprofng.display/mttest/mttest.c | 2 +-
|
||||
gprofng/testsuite/gprofng.display/synprog/endcases.c | 4 ++--
|
||||
gprofng/testsuite/gprofng.display/synprog/inc_inline.h | 2 +-
|
||||
gprofng/testsuite/gprofng.display/synprog/synprog.c | 4 ++--
|
||||
9 files changed, 14 insertions(+), 22 deletions(-)
|
||||
|
||||
diff --git a/gprofng/common/cpuid.c b/gprofng/common/cpuid.c
|
||||
index 891d5471335..b4caef54f57 100644
|
||||
--- a/gprofng/common/cpuid.c
|
||||
+++ b/gprofng/common/cpuid.c
|
||||
@@ -21,7 +21,9 @@
|
||||
#if defined(__i386__) || defined(__x86_64)
|
||||
#include <cpuid.h> /* GCC-provided */
|
||||
#elif defined(__aarch64__)
|
||||
+#if !defined(ATTRIBUTE_UNUSED)
|
||||
#define ATTRIBUTE_UNUSED __attribute__((unused))
|
||||
+#endif
|
||||
|
||||
static inline uint_t __attribute_const__
|
||||
__get_cpuid (unsigned int op ATTRIBUTE_UNUSED, unsigned int *eax,
|
||||
diff --git a/gprofng/libcollector/dispatcher.c b/gprofng/libcollector/dispatcher.c
|
||||
index 4eda18ec324..6f0364cc52c 100644
|
||||
--- a/gprofng/libcollector/dispatcher.c
|
||||
+++ b/gprofng/libcollector/dispatcher.c
|
||||
@@ -1280,4 +1280,4 @@ __collector_ext_clone_pthread (int (*fn)(void *), void *child_stack, int flags,
|
||||
// weak symbols:
|
||||
int sigprocmask (int, const sigset_t*, sigset_t*) __attribute__ ((weak, alias ("__collector_sigprocmask")));
|
||||
int thr_sigsetmask (int, const sigset_t*, sigset_t*) __attribute__ ((weak, alias ("__collector_thr_sigsetmask")));
|
||||
-int setitimer () __attribute__ ((weak, alias ("_setitimer")));
|
||||
+__typeof(setitimer) setitimer __attribute__ ((weak, alias ("_setitimer")));
|
||||
diff --git a/gprofng/libcollector/libcol_util.c b/gprofng/libcollector/libcol_util.c
|
||||
index a73488e3f60..77dc886be22 100644
|
||||
--- a/gprofng/libcollector/libcol_util.c
|
||||
+++ b/gprofng/libcollector/libcol_util.c
|
||||
@@ -1427,15 +1427,6 @@ __collector_util_init ()
|
||||
err = COL_ERROR_UTIL_INIT;
|
||||
}
|
||||
|
||||
- ptr = dlsym (libc, "sysinfo");
|
||||
- if (ptr)
|
||||
- __collector_util_funcs.sysinfo = (long (*)())ptr;
|
||||
- else
|
||||
- {
|
||||
- CALL_UTIL (fprintf)(stderr, "collector_util_init COL_ERROR_UTIL_INIT sysinfo: %s\n", dlerror ());
|
||||
- err = COL_ERROR_UTIL_INIT;
|
||||
- }
|
||||
-
|
||||
ptr = dlsym (libc, "clearenv");
|
||||
if (ptr)
|
||||
__collector_util_funcs.clearenv = (int(*)())ptr;
|
||||
diff --git a/gprofng/libcollector/linetrace.c b/gprofng/libcollector/linetrace.c
|
||||
index 66844bc1337..c81ae1a2272 100644
|
||||
--- a/gprofng/libcollector/linetrace.c
|
||||
+++ b/gprofng/libcollector/linetrace.c
|
||||
@@ -1527,7 +1527,7 @@ DCL_FUNC_VER (DCL_POSIX_SPAWNP, posix_spawnp_2_2, posix_spawnp@GLIBC_2.2)
|
||||
DCL_POSIX_SPAWNP (posix_spawnp)
|
||||
|
||||
/*------------------------------------------------------------- system */
|
||||
-int system () __attribute__ ((weak, alias ("__collector_system")));
|
||||
+int system (const char *cmd) __attribute__ ((weak, alias ("__collector_system")));
|
||||
|
||||
int
|
||||
__collector_system (const char *cmd)
|
||||
@@ -1582,10 +1582,10 @@ DCL_FUNC_VER (DCL_POPEN, popen_2_0, popen@GLIBC_2.0)
|
||||
DCL_POPEN (popen)
|
||||
|
||||
/*------------------------------------------------------------- grantpt */
|
||||
-int grantpt () __attribute__ ((weak, alias ("__collector_grantpt")));
|
||||
+int grantpt (int fildes) __attribute__ ((weak, alias ("__collector_grantpt")));
|
||||
|
||||
int
|
||||
-__collector_grantpt (const int fildes)
|
||||
+__collector_grantpt (int fildes)
|
||||
{
|
||||
if (NULL_PTR (grantpt))
|
||||
init_lineage_intf ();
|
||||
@@ -1607,10 +1607,10 @@ __collector_grantpt (const int fildes)
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------- ptsname */
|
||||
-char *ptsname () __attribute__ ((weak, alias ("__collector_ptsname")));
|
||||
+char *ptsname (int fildes) __attribute__ ((weak, alias ("__collector_ptsname")));
|
||||
|
||||
char *
|
||||
-__collector_ptsname (const int fildes)
|
||||
+__collector_ptsname (int fildes)
|
||||
{
|
||||
if (NULL_PTR (ptsname))
|
||||
init_lineage_intf ();
|
||||
diff --git a/gprofng/src/collector_module.h b/gprofng/src/collector_module.h
|
||||
index fd888cd58dd..6640f12fa3c 100644
|
||||
--- a/gprofng/src/collector_module.h
|
||||
+++ b/gprofng/src/collector_module.h
|
||||
@@ -107,7 +107,6 @@ typedef struct CollectorUtilFuncs
|
||||
int (*symlink)(const char *s1, const char *s2);
|
||||
int (*syscall)(int number, ...);
|
||||
long (*sysconf)(int name);
|
||||
- long (*sysinfo)(int command, char *buf, long count);
|
||||
time_t (*time)(time_t *tloc);
|
||||
int (*unsetenv)(const char *name);
|
||||
int (*vsnprintf)(char *str, size_t size, const char *format, ...);
|
||||
diff --git a/gprofng/testsuite/gprofng.display/mttest/mttest.c b/gprofng/testsuite/gprofng.display/mttest/mttest.c
|
||||
index e0835c833e5..3db5b8d8e86 100644
|
||||
--- a/gprofng/testsuite/gprofng.display/mttest/mttest.c
|
||||
+++ b/gprofng/testsuite/gprofng.display/mttest/mttest.c
|
||||
@@ -171,7 +171,7 @@ void computeJ (workStruct_t *x);
|
||||
void computeK (workStruct_t *x);
|
||||
void addone (workCtr_t *x);
|
||||
void init_arrays (int strat);
|
||||
-void dump_arrays ();
|
||||
+void dump_arrays (hrtime_t real, hrtime_t cpu, int case_index);
|
||||
void *do_work (void *v);
|
||||
void thread_work ();
|
||||
void nothreads (Workblk *array, struct scripttab *k);
|
||||
diff --git a/gprofng/testsuite/gprofng.display/synprog/endcases.c b/gprofng/testsuite/gprofng.display/synprog/endcases.c
|
||||
index a6a1389658a..6f1c83b6859 100644
|
||||
--- a/gprofng/testsuite/gprofng.display/synprog/endcases.c
|
||||
+++ b/gprofng/testsuite/gprofng.display/synprog/endcases.c
|
||||
@@ -40,8 +40,8 @@ static void s_inline_code (int);
|
||||
void ext_inline_code (int);
|
||||
|
||||
#ifndef NO_INLINE
|
||||
-void xinline_code () __attribute__ ((always_inline));
|
||||
-void s_inline_code () __attribute__ ((always_inline));
|
||||
+void xinline_code (int) __attribute__ ((always_inline));
|
||||
+void s_inline_code (int) __attribute__ ((always_inline));
|
||||
#endif
|
||||
|
||||
#include "inc_inline.h"
|
||||
diff --git a/gprofng/testsuite/gprofng.display/synprog/inc_inline.h b/gprofng/testsuite/gprofng.display/synprog/inc_inline.h
|
||||
index da42563c828..6600eacb66d 100644
|
||||
--- a/gprofng/testsuite/gprofng.display/synprog/inc_inline.h
|
||||
+++ b/gprofng/testsuite/gprofng.display/synprog/inc_inline.h
|
||||
@@ -19,7 +19,7 @@
|
||||
MA 02110-1301, USA. */
|
||||
|
||||
#ifndef NO_INLINE
|
||||
-void ext_inline_code() __attribute__ ((always_inline));
|
||||
+void ext_inline_code(int) __attribute__ ((always_inline));
|
||||
#endif
|
||||
|
||||
void
|
||||
diff --git a/gprofng/testsuite/gprofng.display/synprog/synprog.c b/gprofng/testsuite/gprofng.display/synprog/synprog.c
|
||||
index cf1bc5b0909..05920dc7419 100644
|
||||
--- a/gprofng/testsuite/gprofng.display/synprog/synprog.c
|
||||
+++ b/gprofng/testsuite/gprofng.display/synprog/synprog.c
|
||||
@@ -528,14 +528,14 @@ reapchildren ()
|
||||
int
|
||||
doabort (int k)
|
||||
{
|
||||
- char *nullptr = NULL;
|
||||
+ char *p = NULL;
|
||||
char c;
|
||||
|
||||
/* Log the event */
|
||||
wlog ("start of doabort", NULL);
|
||||
|
||||
/* and dereference a NULL */
|
||||
- c = *nullptr;
|
||||
+ c = *p;
|
||||
|
||||
/* this should never be reached */
|
||||
return (int) c;
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -47,6 +47,13 @@ BINUTILS_DISABLE_GDB_CONF_OPTS = \
|
||||
--disable-gdb
|
||||
|
||||
# We need to specify host & target to avoid breaking ARM EABI
|
||||
#
|
||||
# --with-system-readline to never build readline, as binutils doesn't
|
||||
# need it (only gdb does). For binutils release tarballs, readline
|
||||
# is not shipped, but when we get it from git, it is present and
|
||||
# gets built which can cause build issues, so force skipping
|
||||
# it. Note: the configure script will not check for readline as it
|
||||
# doesn't need it.
|
||||
BINUTILS_CONF_OPTS = \
|
||||
--disable-multilib \
|
||||
--disable-werror \
|
||||
@@ -58,7 +65,8 @@ BINUTILS_CONF_OPTS = \
|
||||
--disable-gprofng \
|
||||
$(BINUTILS_DISABLE_GDB_CONF_OPTS) \
|
||||
$(BINUTILS_EXTRA_CONFIG_OPTIONS) \
|
||||
--without-zstd
|
||||
--without-zstd \
|
||||
--with-system-readline
|
||||
|
||||
ifeq ($(BR2_STATIC_LIBS),y)
|
||||
BINUTILS_CONF_OPTS += --disable-plugins
|
||||
@@ -82,6 +90,13 @@ endif
|
||||
|
||||
# "host" binutils should actually be "cross"
|
||||
# We just keep the convention of "host utility" for now
|
||||
#
|
||||
# --with-system-readline to never build readline, as binutils doesn't
|
||||
# need it (only gdb does). For binutils release tarballs, readline
|
||||
# is not shipped, but when we get it from git, it is present and
|
||||
# gets built which can cause build issues, so force skipping
|
||||
# it. Note: the configure script will not check for readline as it
|
||||
# doesn't need it.
|
||||
HOST_BINUTILS_CONF_OPTS = \
|
||||
--disable-multilib \
|
||||
--disable-werror \
|
||||
@@ -95,7 +110,8 @@ HOST_BINUTILS_CONF_OPTS = \
|
||||
--enable-lto \
|
||||
$(BINUTILS_DISABLE_GDB_CONF_OPTS) \
|
||||
$(BINUTILS_EXTRA_CONFIG_OPTIONS) \
|
||||
--without-zstd
|
||||
--without-zstd \
|
||||
--with-system-readline
|
||||
|
||||
ifeq ($(BR2_BINUTILS_GPROFNG),y)
|
||||
HOST_BINUTILS_DEPENDENCIES += host-bison
|
||||
|
||||
@@ -0,0 +1,103 @@
|
||||
From 7b752106ac42bd5b907793950d9125a0972c8e8e Mon Sep 17 00:00:00 2001
|
||||
From: Ville Vesilehto <ville@vesilehto.fi>
|
||||
Date: Sat, 3 May 2025 11:39:01 +0300
|
||||
Subject: [PATCH] Merge commit from fork
|
||||
|
||||
* fix(parser): Limit line length in getline
|
||||
|
||||
Prevents potential infinite loop and memory exhaustion in
|
||||
stream_line_reader::getline by enforcing max line length.
|
||||
|
||||
Signed-off-by: Ville Vesilehto <ville@vesilehto.fi>
|
||||
|
||||
* fix: increase default max line length to 32k
|
||||
|
||||
LONG_QUERY_VALUE test is set at 25k.
|
||||
|
||||
Signed-off-by: Ville Vesilehto <ville@vesilehto.fi>
|
||||
|
||||
* test(client): expect read error with too long query
|
||||
|
||||
Adds a test case (`TooLongQueryValue`) to verify client behavior
|
||||
when the request URI is excessively long, exceeding
|
||||
`CPPHTTPLIB_MAX_LINE_LENGTH`. In this scenario, the server is
|
||||
expected to reset the connection.
|
||||
|
||||
Signed-off-by: Ville Vesilehto <ville@vesilehto.fi>
|
||||
|
||||
CVE: CVE-2025-46728
|
||||
Upstream: https://github.com/yhirose/cpp-httplib/commit/7b752106ac42bd5b907793950d9125a0972c8e8e
|
||||
[thomas: adapt lines numbers to v0.19.0]
|
||||
Signed-off-by: Thomas Perale <thomas.perale@mind.be>
|
||||
---
|
||||
httplib.h | 9 +++++++++
|
||||
test/test.cc | 15 +++++++++++++++
|
||||
2 files changed, 24 insertions(+)
|
||||
|
||||
diff --git a/httplib.h b/httplib.h
|
||||
index cb182c4129..a2aa24f96b 100644
|
||||
--- a/httplib.h
|
||||
+++ b/httplib.h
|
||||
@@ -145,6 +145,10 @@
|
||||
#define CPPHTTPLIB_LISTEN_BACKLOG 5
|
||||
#endif
|
||||
|
||||
+#ifndef CPPHTTPLIB_MAX_LINE_LENGTH
|
||||
+#define CPPHTTPLIB_MAX_LINE_LENGTH 32768
|
||||
+#endif
|
||||
+
|
||||
/*
|
||||
* Headers
|
||||
*/
|
||||
@@ -2998,6 +3002,11 @@ inline bool stream_line_reader::getline() {
|
||||
#endif
|
||||
|
||||
for (size_t i = 0;; i++) {
|
||||
+ if (size() >= CPPHTTPLIB_MAX_LINE_LENGTH) {
|
||||
+ // Treat exceptionally long lines as an error to
|
||||
+ // prevent infinite loops/memory exhaustion
|
||||
+ return false;
|
||||
+ }
|
||||
char byte;
|
||||
auto n = strm_.read(&byte, 1);
|
||||
|
||||
diff --git a/test/test.cc b/test/test.cc
|
||||
index 4fd9983bd8..7f5cc8a9d0 100644
|
||||
--- a/test/test.cc
|
||||
+++ b/test/test.cc
|
||||
@@ -42,6 +42,9 @@ const int PORT = 1234;
|
||||
const string LONG_QUERY_VALUE = string(25000, '@');
|
||||
const string LONG_QUERY_URL = "/long-query-value?key=" + LONG_QUERY_VALUE;
|
||||
|
||||
+const string TOO_LONG_QUERY_VALUE = string(35000, '@');
|
||||
+const string TOO_LONG_QUERY_URL = "/too-long-query-value?key=" + TOO_LONG_QUERY_VALUE;
|
||||
+
|
||||
const std::string JSON_DATA = "{\"hello\":\"world\"}";
|
||||
|
||||
const string LARGE_DATA = string(1024 * 1024 * 100, '@'); // 100MB
|
||||
@@ -2839,6 +2842,11 @@ class ServerTest : public ::testing::Test {
|
||||
EXPECT_EQ(LONG_QUERY_URL, req.target);
|
||||
EXPECT_EQ(LONG_QUERY_VALUE, req.get_param_value("key"));
|
||||
})
|
||||
+ .Get("/too-long-query-value",
|
||||
+ [&](const Request &req, Response & /*res*/) {
|
||||
+ EXPECT_EQ(TOO_LONG_QUERY_URL, req.target);
|
||||
+ EXPECT_EQ(TOO_LONG_QUERY_VALUE, req.get_param_value("key"));
|
||||
+ })
|
||||
.Get("/array-param",
|
||||
[&](const Request &req, Response & /*res*/) {
|
||||
EXPECT_EQ(3u, req.get_param_value_count("array"));
|
||||
@@ -3624,6 +3632,13 @@ TEST_F(ServerTest, LongQueryValue) {
|
||||
EXPECT_EQ(StatusCode::UriTooLong_414, res->status);
|
||||
}
|
||||
|
||||
+TEST_F(ServerTest, TooLongQueryValue) {
|
||||
+ auto res = cli_.Get(TOO_LONG_QUERY_URL.c_str());
|
||||
+
|
||||
+ ASSERT_FALSE(res);
|
||||
+ EXPECT_EQ(Error::Read, res.error());
|
||||
+}
|
||||
+
|
||||
TEST_F(ServerTest, TooLongHeader) {
|
||||
Request req;
|
||||
req.method = "GET";
|
||||
@@ -13,6 +13,9 @@ CPP_HTTPLIB_INSTALL_STAGING = YES
|
||||
CPP_HTTPLIB_CONF_OPTS = \
|
||||
-Dcpp-httplib_test=false
|
||||
|
||||
# 0001-merge-commit-from-fork.patch
|
||||
CPP_HTTPLIB_IGNORE_CVES += CVE-2025-46728
|
||||
|
||||
ifeq ($(BR2_PACKAGE_CPP_HTTPLIB_COMPILE),y)
|
||||
CPP_HTTPLIB_CONF_OPTS += -Dcpp-httplib_compile=true
|
||||
CPP_HTTPLIB_DEPENDENCIES += host-python3
|
||||
|
||||
@@ -0,0 +1,27 @@
|
||||
From 6d80909a8c0fd19717010a3c76fec560f988ca48 Mon Sep 17 00:00:00 2001
|
||||
From: Rudi Heitbaum <rudi@heitbaum.com>
|
||||
Date: Mon, 9 Dec 2024 12:35:09 +0000
|
||||
Subject: [PATCH] fix gcc-15 build
|
||||
|
||||
Upstream: https://github.com/crigler/dtach/commit/6d80909a8c0fd19717010a3c76fec560f988ca48
|
||||
Signed-off-by: Florian Larysch <fl@n621.de>
|
||||
---
|
||||
attach.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/attach.c b/attach.c
|
||||
index 41a696c..e4a46bd 100644
|
||||
--- a/attach.c
|
||||
+++ b/attach.c
|
||||
@@ -96,7 +96,7 @@ die(int sig)
|
||||
|
||||
/* Window size change. */
|
||||
static RETSIGTYPE
|
||||
-win_change()
|
||||
+win_change(int sig)
|
||||
{
|
||||
signal(SIGWINCH, win_change);
|
||||
win_changed = 1;
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -0,0 +1,50 @@
|
||||
From 93be1da123215e8ac15a0deaffedd480e8899f77 Mon Sep 17 00:00:00 2001
|
||||
From: Conrad Kostecki <conrad@kostecki.com>
|
||||
Date: Tue, 22 Apr 2025 00:41:31 +0200
|
||||
Subject: [PATCH] Fix compilation with GCC15
|
||||
|
||||
Upstream: https://github.com/flightaware/dump1090/pull/261
|
||||
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
|
||||
---
|
||||
ais_charset.c | 2 +-
|
||||
ais_charset.h | 2 +-
|
||||
interactive.c | 2 +-
|
||||
3 files changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/ais_charset.c b/ais_charset.c
|
||||
index a487e3c..0d3af03 100644
|
||||
--- a/ais_charset.c
|
||||
+++ b/ais_charset.c
|
||||
@@ -1,3 +1,3 @@
|
||||
#include "ais_charset.h"
|
||||
|
||||
-char ais_charset[64] = "@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_ !\"#$%&'()*+,-./0123456789:;<=>?";
|
||||
+char ais_charset[65] = "@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_ !\"#$%&'()*+,-./0123456789:;<=>?";
|
||||
diff --git a/ais_charset.h b/ais_charset.h
|
||||
index 93d4a72..95ef373 100644
|
||||
--- a/ais_charset.h
|
||||
+++ b/ais_charset.h
|
||||
@@ -1,6 +1,6 @@
|
||||
#ifndef AIS_CHARSET_H
|
||||
#define AIS_CHARSET_H
|
||||
|
||||
-extern char ais_charset[64];
|
||||
+extern char ais_charset[65];
|
||||
|
||||
#endif
|
||||
diff --git a/interactive.c b/interactive.c
|
||||
index 8761c95..75775ad 100644
|
||||
--- a/interactive.c
|
||||
+++ b/interactive.c
|
||||
@@ -140,7 +140,7 @@ void interactiveShowData(void) {
|
||||
static bool need_clear = true;
|
||||
uint64_t now = mstime();
|
||||
char progress;
|
||||
- char spinner[4] = "|/-\\";
|
||||
+ char spinner[5] = "|/-\\";
|
||||
int valid = 0;
|
||||
double signalMax = -100.0;
|
||||
double signalMin = +100.0;
|
||||
--
|
||||
2.39.5
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
# Locally calculated
|
||||
sha256 f0b2b07c7014b7aa8c4689095b83a49a85d41887049fc5302543aec0bef7d066 ffmpeg-n6.1.2-27-ge16ff06adb-git4.tar.gz
|
||||
sha256 bc5f1e4a4d283a6492354684ee1124129c52293bcfc6a9169193539fbece3487 ffmpeg-6.1.3.tar.xz
|
||||
sha256 8177f97513213526df2cf6184d8ff986c675afb514d4e68a404010521b880643 COPYING.GPLv2
|
||||
sha256 b634ab5640e258563c536e658cad87080553df6f34f62269a21d554844e58bfe COPYING.LGPLv2.1
|
||||
sha256 cb48bf09a11f5fb576cddb0431c8f5ed0a60157a9ec942adffc13907cbe083f2 LICENSE.md
|
||||
|
||||
@@ -4,12 +4,10 @@
|
||||
#
|
||||
################################################################################
|
||||
|
||||
# Update FFMPEG_CPE_ID_VERSION if needed
|
||||
FFMPEG_VERSION = n6.1.2-27-ge16ff06adb
|
||||
FFMPEG_SITE = https://git.ffmpeg.org/ffmpeg.git
|
||||
FFMPEG_SITE_METHOD = git
|
||||
FFMPEG_VERSION = 6.1.3
|
||||
FFMPEG_SOURCE = ffmpeg-$(FFMPEG_VERSION).tar.xz
|
||||
FFMPEG_SITE = https://ffmpeg.org/releases
|
||||
FFMPEG_INSTALL_STAGING = YES
|
||||
FFMPEG_CPE_ID_VERSION = 6.1.2
|
||||
|
||||
FFMPEG_LICENSE = LGPL-2.1+, libjpeg license
|
||||
FFMPEG_LICENSE_FILES = LICENSE.md COPYING.LGPLv2.1
|
||||
|
||||
@@ -0,0 +1,158 @@
|
||||
From 238315e9f4f547dff4f5b9dff2f903385a8048cb Mon Sep 17 00:00:00 2001
|
||||
From: Sergey Poznyakoff <gray@gnu.org>
|
||||
Date: Sun, 17 Nov 2024 22:58:54 +0200
|
||||
Subject: [PATCH] C23 compatibility fix
|
||||
|
||||
This fixes https://puszcza.gnu.org.ua/bugs/?642
|
||||
|
||||
* tools/var.c (union value): Rename bool to b.
|
||||
|
||||
Upstream: 734f69451392ffb6280d8a3aef51e2673c9b8554
|
||||
[Thomas: needed a few backporting adjustements]
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
tools/var.c | 32 ++++++++++++++++----------------
|
||||
1 file changed, 16 insertions(+), 16 deletions(-)
|
||||
|
||||
diff --git a/tools/var.c b/tools/var.c
|
||||
index 0f285f1..c553ae5 100644
|
||||
--- a/tools/var.c
|
||||
+++ b/tools/var.c
|
||||
@@ -27,7 +27,7 @@
|
||||
union value
|
||||
{
|
||||
char *string;
|
||||
- int bool;
|
||||
+ int b;
|
||||
int num;
|
||||
};
|
||||
|
||||
@@ -90,7 +90,7 @@ static struct variable vartab[] = {
|
||||
.name = "confirm",
|
||||
.type = VART_BOOL,
|
||||
.flags = VARF_INIT,
|
||||
- .init = { .bool = 1 }
|
||||
+ .init = { .b = 1 }
|
||||
},
|
||||
{
|
||||
.name = "cachesize",
|
||||
@@ -114,32 +114,32 @@ static struct variable vartab[] = {
|
||||
.name = "lock",
|
||||
.type = VART_BOOL,
|
||||
.flags = VARF_INIT,
|
||||
- .init = { .bool = 1 }
|
||||
+ .init = { .b = 1 }
|
||||
},
|
||||
{
|
||||
.name = "mmap",
|
||||
.type = VART_BOOL,
|
||||
.flags = VARF_INIT,
|
||||
- .init = { .bool = 1 }
|
||||
+ .init = { .b = 1 }
|
||||
},
|
||||
{
|
||||
.name = "sync",
|
||||
.type = VART_BOOL,
|
||||
.flags = VARF_INIT,
|
||||
- .init = { .bool = 0 }
|
||||
+ .init = { .b = 0 }
|
||||
},
|
||||
{
|
||||
.name = "coalesce",
|
||||
.type = VART_BOOL,
|
||||
.flags = VARF_INIT,
|
||||
- .init = { .bool = 0 },
|
||||
+ .init = { .b = 0 },
|
||||
.sethook = coalesce_sethook
|
||||
},
|
||||
{
|
||||
.name = "centfree",
|
||||
.type = VART_BOOL,
|
||||
.flags = VARF_INIT,
|
||||
- .init = { .bool = 0 },
|
||||
+ .init = { .b = 0 },
|
||||
.sethook = centfree_sethook
|
||||
},
|
||||
{
|
||||
@@ -252,21 +252,21 @@ s2b (union value *vp, void *val, int flags)
|
||||
for (i = 0; trueval[i]; i++)
|
||||
if (strcasecmp (trueval[i], val) == 0)
|
||||
{
|
||||
- vp->bool = 1;
|
||||
+ vp->b = 1;
|
||||
return VAR_OK;
|
||||
}
|
||||
|
||||
for (i = 0; falseval[i]; i++)
|
||||
if (strcasecmp (falseval[i], val) == 0)
|
||||
{
|
||||
- vp->bool = 0;
|
||||
+ vp->b = 0;
|
||||
return VAR_OK;
|
||||
}
|
||||
|
||||
n = strtoul (val, &p, 0);
|
||||
if (*p)
|
||||
return VAR_ERR_BADTYPE;
|
||||
- vp->bool = !!n;
|
||||
+ vp->b = !!n;
|
||||
return VAR_OK;
|
||||
}
|
||||
|
||||
@@ -286,7 +286,7 @@ s2i (union value *vp, void *val, int flags)
|
||||
static int
|
||||
b2b (union value *vp, void *val, int flags)
|
||||
{
|
||||
- vp->bool = !!*(int*)val;
|
||||
+ vp->b = !!*(int*)val;
|
||||
return VAR_OK;
|
||||
}
|
||||
|
||||
@@ -307,7 +307,7 @@ i2i (union value *vp, void *val, int flags)
|
||||
static int
|
||||
i2b (union value *vp, void *val, int flags)
|
||||
{
|
||||
- vp->bool = *(int*)val;
|
||||
+ vp->b = *(int*)val;
|
||||
return VAR_OK;
|
||||
}
|
||||
|
||||
@@ -414,7 +414,7 @@ variable_get (const char *name, int type, void **val)
|
||||
break;
|
||||
|
||||
case VART_BOOL:
|
||||
- *(int*)val = vp->v.bool;
|
||||
+ *(int*)val = vp->v.b;
|
||||
break;
|
||||
|
||||
case VART_INT:
|
||||
@@ -461,7 +461,7 @@ variable_print_all (FILE *fp)
|
||||
break;
|
||||
|
||||
case VART_BOOL:
|
||||
- fprintf (fp, "%s%s", vp->v.bool ? "" : "no", vp->name);
|
||||
+ fprintf (fp, "%s%s", vp->v.b ? "" : "no", vp->name);
|
||||
break;
|
||||
|
||||
case VART_STRING:
|
||||
@@ -647,7 +647,7 @@ centfree_sethook (struct variable *var, union value *v)
|
||||
{
|
||||
if (!v)
|
||||
return VAR_OK;
|
||||
- return gdbmshell_setopt ("GDBM_SETCENTFREE", GDBM_SETCENTFREE, v->bool) == 0
|
||||
+ return gdbmshell_setopt ("GDBM_SETCENTFREE", GDBM_SETCENTFREE, v->b) == 0
|
||||
? VAR_OK : VAR_ERR_GDBM;
|
||||
}
|
||||
|
||||
@@ -656,7 +656,7 @@ coalesce_sethook (struct variable *var, union value *v)
|
||||
{
|
||||
if (!v)
|
||||
return VAR_OK;
|
||||
- return gdbmshell_setopt ("GDBM_SETCOALESCEBLKS", GDBM_SETCOALESCEBLKS, v->bool) == 0
|
||||
+ return gdbmshell_setopt ("GDBM_SETCOALESCEBLKS", GDBM_SETCOALESCEBLKS, v->b) == 0
|
||||
? VAR_OK : VAR_ERR_GDBM;
|
||||
}
|
||||
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -0,0 +1,236 @@
|
||||
From 436f3f0a75a42dc9e07f2fe85b73eeb4c95e0515 Mon Sep 17 00:00:00 2001
|
||||
From: NHOrus <jy6x2b32pie9@yahoo.com>
|
||||
Date: Tue, 11 Feb 2025 18:42:47 +0400
|
||||
Subject: [PATCH] Avoid shadowing ncurses functions. This fails with GCC-15 and
|
||||
other compilers implementing C23 Added prefix gpm_ to raw() and noraw() used
|
||||
in two files because they are implemented in same two files, and are static.
|
||||
Same with scr_dump() and src_restore() in yacc source file
|
||||
|
||||
Upstream: https://github.com/telmich/gpm/pull/49
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
src/prog/gpm-root.y | 10 +++++-----
|
||||
src/prog/hltest.c | 11 +++++------
|
||||
src/prog/mouse-test.c | 24 ++++++++++++------------
|
||||
3 files changed, 22 insertions(+), 23 deletions(-)
|
||||
|
||||
diff --git a/src/prog/gpm-root.y b/src/prog/gpm-root.y
|
||||
index d3d064c..7001d6e 100644
|
||||
--- a/src/prog/gpm-root.y
|
||||
+++ b/src/prog/gpm-root.y
|
||||
@@ -939,7 +939,7 @@ static unsigned short clear_sel_args[6]={0, 0,0, 0,0, 4};
|
||||
static unsigned char *clear_sel_arg= (unsigned char *)clear_sel_args+1;
|
||||
|
||||
/*------------*/
|
||||
-static inline void scr_dump(int fd, FILE *f, unsigned char *buffer, int vc)
|
||||
+static inline void gpm_scr_dump(int fd, FILE *f, unsigned char *buffer, int vc)
|
||||
{
|
||||
int dumpfd;
|
||||
char dumpname[20];
|
||||
@@ -958,7 +958,7 @@ static inline void scr_dump(int fd, FILE *f, unsigned char *buffer, int vc)
|
||||
}
|
||||
|
||||
/*------------*/
|
||||
-static inline void scr_restore(int fd, FILE *f, unsigned char *buffer, int vc)
|
||||
+static inline void gpm_scr_restore(int fd, FILE *f, unsigned char *buffer, int vc)
|
||||
{
|
||||
int x,y, dumpfd;
|
||||
char dumpname[20];
|
||||
@@ -1002,7 +1002,7 @@ Posted *postmenu(int fd, FILE *f, Draw *draw, int x, int y, int console)
|
||||
if (!new) return NULL;
|
||||
new->draw=draw;
|
||||
new->dump=dump=malloc(opt_buf);
|
||||
- scr_dump(fd,f,dump,console);
|
||||
+ gpm_scr_dump(fd,f,dump,console);
|
||||
lines=dump[0]; columns=dump[1];
|
||||
i=(columns*dump[3]+dump[2])*2+1; /* where to get it */
|
||||
if (i<0) i=1;
|
||||
@@ -1060,7 +1060,7 @@ Posted *postmenu(int fd, FILE *f, Draw *draw, int x, int y, int console)
|
||||
for (i=0; i<draw->width; i++) PUTC(HORLINE,draw->bord,draw->back);
|
||||
PUTC(LRCORNER,draw->bord,draw->back);
|
||||
|
||||
- scr_restore(fd,f,dump,console);
|
||||
+ gpm_scr_restore(fd,f,dump,console);
|
||||
free(dump);
|
||||
|
||||
#undef PUTC
|
||||
@@ -1077,7 +1077,7 @@ Posted *unpostmenu(int fd, FILE *f, Posted *which, int vc)
|
||||
{
|
||||
Posted *prev=which->prev;
|
||||
|
||||
- scr_restore(fd,f,which->dump, vc);
|
||||
+ gpm_scr_restore(fd,f,which->dump, vc);
|
||||
ioctl(fd,TCXONC,TCOON); /* activate the console */
|
||||
free(which->dump);
|
||||
free(which);
|
||||
diff --git a/src/prog/hltest.c b/src/prog/hltest.c
|
||||
index cce0abc..a916873 100644
|
||||
--- a/src/prog/hltest.c
|
||||
+++ b/src/prog/hltest.c
|
||||
@@ -80,7 +80,6 @@ int wid,hei,vcsize;
|
||||
unsigned short clear_sel_args[6]={0, 0,0, 0,0, 4};
|
||||
unsigned char *clear_sel_arg= (unsigned char *)clear_sel_args+1;
|
||||
|
||||
-
|
||||
static inline int scrdump(char *buf)
|
||||
{
|
||||
clear_sel_arg[0]=2; /* clear_selection */
|
||||
@@ -99,7 +98,7 @@ static inline int scrrestore(char *buf)
|
||||
|
||||
|
||||
/* I don't like curses, so I'm doing low level stuff here */
|
||||
-static void raw(void)
|
||||
+static void gpm_raw(void)
|
||||
{
|
||||
struct termios it;
|
||||
|
||||
@@ -115,7 +114,7 @@ tcsetattr(fileno(stdin),TCSANOW,&it);
|
||||
|
||||
}
|
||||
|
||||
-static void noraw(void)
|
||||
+static void gpm_noraw(void)
|
||||
{
|
||||
struct termios it;
|
||||
|
||||
@@ -136,7 +135,7 @@ void killed(int signo)
|
||||
{
|
||||
CLEAR;
|
||||
fprintf(stderr,"hltest: killed by signal %i\r\n",signo);
|
||||
- noraw();
|
||||
+ gpm_noraw();
|
||||
exit(0);
|
||||
}
|
||||
|
||||
@@ -525,7 +524,7 @@ int main(int argc, char **argv)
|
||||
gpm_roi_handler=xhandler;
|
||||
gpm_roi_data=NULL;
|
||||
|
||||
- raw();
|
||||
+ gpm_raw();
|
||||
newmsg(0,NULL); /* init data structures */
|
||||
while((c=Gpm_Getchar())!=EOF) {
|
||||
char s[32];
|
||||
@@ -538,6 +537,6 @@ int main(int argc, char **argv)
|
||||
newmsg(roi ? ((WinInfo *)roi->clientdata)->number : 0,s);
|
||||
}
|
||||
|
||||
- noraw();
|
||||
+ gpm_noraw();
|
||||
exit(0);
|
||||
}
|
||||
diff --git a/src/prog/mouse-test.c b/src/prog/mouse-test.c
|
||||
index 0bb1982..7235bba 100644
|
||||
--- a/src/prog/mouse-test.c
|
||||
+++ b/src/prog/mouse-test.c
|
||||
@@ -106,7 +106,7 @@ return 0;
|
||||
/*-----------------------------------------------------------------------------
|
||||
Place the description here.
|
||||
-----------------------------------------------------------------------------*/
|
||||
-static void raw(void)
|
||||
+static void gpm_raw(void)
|
||||
{
|
||||
struct termios it;
|
||||
|
||||
@@ -125,7 +125,7 @@ static void raw(void)
|
||||
/*-----------------------------------------------------------------------------
|
||||
Place the description here.
|
||||
-----------------------------------------------------------------------------*/
|
||||
-static void noraw(void)
|
||||
+static void gpm_noraw(void)
|
||||
{
|
||||
struct termios it;
|
||||
|
||||
@@ -144,7 +144,7 @@ static void noraw(void)
|
||||
void killed(int signo)
|
||||
{
|
||||
fprintf(stderr,"mouse-test: killed by signal %i\r\n",signo);
|
||||
- noraw();
|
||||
+ gpm_noraw();
|
||||
exit(0);
|
||||
}
|
||||
|
||||
@@ -196,7 +196,7 @@ int mousereopen(int oldfd, char *name, Gpm_Type *type)
|
||||
|
||||
int noneofthem(void)
|
||||
{
|
||||
- noraw();
|
||||
+ gpm_noraw();
|
||||
printf("\n\nSomething went wrong, I didn't manage to detect your"
|
||||
"protocol\n\nFeel free to report your problems to the author\n");
|
||||
exit(1);
|
||||
@@ -336,7 +336,7 @@ int main(int argc, char **argv)
|
||||
I_serial=mice->init; /* the first one has I_serial */
|
||||
|
||||
signal(SIGINT,killed); /* control-C kills us */
|
||||
- raw();
|
||||
+ gpm_raw();
|
||||
|
||||
/*====================================== First of all, detect the device */
|
||||
|
||||
@@ -568,7 +568,7 @@ int main(int argc, char **argv)
|
||||
/* why checking and not using return value ??? */
|
||||
CHECKFAIL(typecount);
|
||||
if (typecount==1) {
|
||||
- noraw();
|
||||
+ gpm_noraw();
|
||||
printf("\n\n\nWell, it seems like your mouse is already detected:\n"
|
||||
"it is on the device \"%s\", and speaks the protocol \"%s\"\n",
|
||||
mousename,list->this->name);
|
||||
@@ -587,7 +587,7 @@ int main(int argc, char **argv)
|
||||
} while(i!='y' && i!='n');
|
||||
|
||||
if (i=='n') {
|
||||
- noraw();
|
||||
+ gpm_noraw();
|
||||
printf("\nThen, you should use the \"bare\" protocol on \"%s\"\n",
|
||||
mousename);
|
||||
exit(0);
|
||||
@@ -634,7 +634,7 @@ int main(int argc, char **argv)
|
||||
for (pending=0,i=0;i<got-16;i++)
|
||||
if(!memcmp(buf+i,buf+i+8,8)) pending++;
|
||||
if (pending > 3) {
|
||||
- noraw();
|
||||
+ gpm_noraw();
|
||||
printf("\nYour mouse seems to be a 'mman' one on \"%s\" (%i matches)\n",
|
||||
mousename,pending);
|
||||
exit(0);
|
||||
@@ -660,7 +660,7 @@ int main(int argc, char **argv)
|
||||
continue;
|
||||
}
|
||||
if (pending>3) {
|
||||
- noraw();
|
||||
+ gpm_noraw();
|
||||
printf("\nYour mouse seems to be a '%s' one on \"%s\" (%i matches)\n",
|
||||
cur->this->name,mousename,pending);
|
||||
exit(0);
|
||||
@@ -695,7 +695,7 @@ int main(int argc, char **argv)
|
||||
for (pending=0,i=0;i<got-20;i++)
|
||||
if(!memcmp(buf+i,buf+i+10,10)) pending++;
|
||||
if (pending>3) {
|
||||
- noraw();
|
||||
+ gpm_noraw();
|
||||
printf("\nYour mouse becomes a 3-buttons ('-t msc') one when\n"
|
||||
"gpm gets '-o %s' on it command line, and X gets\n"
|
||||
"%s in XF86Config\nThe device is \"%s\"",
|
||||
@@ -726,7 +726,7 @@ int main(int argc, char **argv)
|
||||
for (pending=0,i=0;i<got-20;i++)
|
||||
if(!memcmp(buf+i,buf+i+10,10)) pending++;
|
||||
if (pending>3) {
|
||||
- noraw();
|
||||
+ gpm_noraw();
|
||||
printf("\nWorked. You should keep the button pressed every time the\n"
|
||||
"computer boots, and run gpm in '-R' mode in order to ignore\n"
|
||||
"such hassle when starting X\n\nStill better, but a better mouse\n"
|
||||
@@ -734,7 +734,7 @@ int main(int argc, char **argv)
|
||||
|
||||
exit(0);
|
||||
}
|
||||
- noraw();
|
||||
+ gpm_noraw();
|
||||
printf("\nI'm lost. Can't tell you how to use your middle button\n");
|
||||
return 0;
|
||||
}
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -0,0 +1,83 @@
|
||||
From 4e3d358da1c6066d7a320ffc157ca9e35ed34e49 Mon Sep 17 00:00:00 2001
|
||||
From: NHOrus <jy6x2b32pie9@yahoo.com>
|
||||
Date: Tue, 11 Feb 2025 19:01:48 +0400
|
||||
Subject: [PATCH] Fix function definition in yacc source file until valid C23.
|
||||
Fill empty argument lists with values. Add 0 as third argument for
|
||||
two-argument function, it will be ignored at call site.
|
||||
|
||||
Upstream: https://github.com/telmich/gpm/pull/49
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
src/prog/gpm-root.y | 14 +++++++-------
|
||||
1 file changed, 7 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/src/prog/gpm-root.y b/src/prog/gpm-root.y
|
||||
index 7001d6e..56072ac 100644
|
||||
--- a/src/prog/gpm-root.y
|
||||
+++ b/src/prog/gpm-root.y
|
||||
@@ -128,7 +128,7 @@ typedef struct DrawItem {
|
||||
char *name;
|
||||
char *arg; /* a cmd string */
|
||||
void *clientdata; /* a (Draw *) for menus or whatever */
|
||||
- int (*fun)();
|
||||
+ int (*fun)(int, struct DrawItem *, int);
|
||||
struct DrawItem *next;
|
||||
} DrawItem;
|
||||
|
||||
@@ -159,7 +159,7 @@ int yyerror(char *s);
|
||||
int yylex(void);
|
||||
|
||||
DrawItem *cfg_cat(DrawItem *, DrawItem *);
|
||||
-DrawItem *cfg_makeitem(int mode, char *msg, int(*fun)(), void *detail);
|
||||
+DrawItem *cfg_makeitem(int mode, char *msg, int(*fun)(int, DrawItem *, int), void *detail);
|
||||
|
||||
|
||||
/*===================================================================*
|
||||
@@ -195,7 +195,7 @@ int f_pipe(int mode, DrawItem *self, int uid);
|
||||
char *string;
|
||||
Draw *draw;
|
||||
DrawItem *item;
|
||||
- int (*fun)();
|
||||
+ int (*fun)(int, DrawItem *, int);
|
||||
}
|
||||
|
||||
%token <string> T_STRING
|
||||
@@ -284,7 +284,7 @@ struct tokenName tokenList[] = {
|
||||
struct funcName {
|
||||
char *name;
|
||||
int token;
|
||||
- int (*fun)();
|
||||
+ int (*fun)(int, DrawItem *, int);
|
||||
};
|
||||
struct funcName funcList[] = {
|
||||
{"f.debug",T_FUNC,f_debug},
|
||||
@@ -390,7 +390,7 @@ Draw *cfg_alloc(void)
|
||||
|
||||
/*---------------------------------------------------------------------*/
|
||||
/* malloc an empty DrawItem and fill it */
|
||||
-DrawItem *cfg_makeitem(int mode, char *msg, int(*fun)(), void *detail)
|
||||
+DrawItem *cfg_makeitem(int mode, char *msg, int(*fun)(int, DrawItem *, int), void *detail)
|
||||
{
|
||||
DrawItem *new=calloc(1,sizeof(DrawItem));
|
||||
|
||||
@@ -405,7 +405,7 @@ DrawItem *cfg_makeitem(int mode, char *msg, int(*fun)(), void *detail)
|
||||
|
||||
case 'F': /* a function without args */
|
||||
new->fun=fun;
|
||||
- if (fun) fun(F_CREATE,new);
|
||||
+ if (fun) fun(F_CREATE,new,0);
|
||||
break;
|
||||
|
||||
case 'M':
|
||||
@@ -1047,7 +1047,7 @@ Posted *postmenu(int fd, FILE *f, Draw *draw, int x, int y, int console)
|
||||
}
|
||||
/* sides and items */
|
||||
for (item=draw->menu; y++, item; item=item->next) {
|
||||
- if (item->fun) (*(item->fun))(F_POST,item);
|
||||
+ if (item->fun) (*(item->fun))(F_POST,item,0);
|
||||
GOTO(x,y); PUTC(VERLINE,draw->bord,draw->back);
|
||||
for (i=0;i<item->pad;i++) PUTC(' ',draw->fore,draw->back);
|
||||
PUTS(item->name,draw->fore,draw->back); i+=strlen(item->name);
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -0,0 +1,39 @@
|
||||
From d6d5168713b1513dc2a780d21bb33dcf16a7a518 Mon Sep 17 00:00:00 2001
|
||||
From: NHOrus <jy6x2b32pie9@yahoo.com>
|
||||
Date: Sat, 22 Feb 2025 01:12:32 +0400
|
||||
Subject: [PATCH] Add incomplete type definition for WINDOW in Gpm_Wgetch()
|
||||
|
||||
Window handle is an opaque pointer that Gpm_Wgetch() passes
|
||||
through straight to ncurses if it's not null and calls getch
|
||||
if it's null. Code doesn't care what's inside the handle
|
||||
as long as it agrees with curses definition.
|
||||
|
||||
Upstream: https://github.com/telmich/gpm/pull/49
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
src/headers/gpm.h | 9 ++++++++-
|
||||
1 file changed, 8 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/headers/gpm.h b/src/headers/gpm.h
|
||||
index 57dc618..6c53fbf 100644
|
||||
--- a/src/headers/gpm.h
|
||||
+++ b/src/headers/gpm.h
|
||||
@@ -268,7 +268,14 @@ Gpm_Roi * Gpm_LowerRoi(Gpm_Roi *which, Gpm_Roi *after);
|
||||
/* libcurses.c */
|
||||
/* #include <curses.h> Hmm... seems risky */
|
||||
|
||||
-extern int Gpm_Wgetch();
|
||||
+/* Window handle is an opaque pointer that Gpm_Wgetch()
|
||||
+ * passes through to ncurses if it's not null and calls getch
|
||||
+ * if it's null. Code doesn't care what's inside the handle
|
||||
+ * as long as it agrees with curses definition.
|
||||
+*/
|
||||
+typedef struct _win_st WINDOW;
|
||||
+
|
||||
+extern int Gpm_Wgetch(WINDOW *);
|
||||
#define Gpm_Getch() (Gpm_Wgetch(NULL))
|
||||
|
||||
/* libxtra.c */
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
config BR2_PACKAGE_LIBJWT
|
||||
bool "libjwt"
|
||||
select BR2_PACKAGE_OPENSSL if !BR2_PACKAGE_GNUTLS
|
||||
select BR2_PACKAGE_OPENSSL
|
||||
select BR2_PACKAGE_OPENSSL_FORCE_LIBOPENSSL
|
||||
select BR2_PACKAGE_JANSSON
|
||||
help
|
||||
JSON Web Tokens are an open, industry standard RFC 7519
|
||||
|
||||
@@ -7,21 +7,13 @@
|
||||
LIBJWT_VERSION = 3.2.0
|
||||
LIBJWT_SITE = https://github.com/benmcollins/libjwt/releases/download/v$(LIBJWT_VERSION)
|
||||
LIBJWT_SOURCE = libjwt-$(LIBJWT_VERSION).tar.xz
|
||||
LIBJWT_DEPENDENCIES = host-pkgconf jansson
|
||||
LIBJWT_DEPENDENCIES = host-pkgconf jansson openssl
|
||||
LIBJWT_INSTALL_STAGING = YES
|
||||
LIBJWT_LICENSE = MPL-2.0
|
||||
LIBJWT_LICENSE_FILES = LICENSE
|
||||
LIBJWT_CPE_ID_VENDOR = bencollins
|
||||
LIBJWT_CPE_ID_PRODUCT = jwt_c_library
|
||||
|
||||
LIBJWT_CONF_OPTS += -DWITH_TESTS=OFF
|
||||
|
||||
ifeq ($(BR2_PACKAGE_OPENSSL),y)
|
||||
LIBJWT_CONF_OPTS += -DWITH_OPENSSL=ON
|
||||
LIBJWT_DEPENDENCIES += openssl
|
||||
else
|
||||
LIBJWT_CONF_OPTS += -DWITH_GNUTLS=ON
|
||||
LIBJWT_DEPENDENCIES += gnutls
|
||||
endif
|
||||
LIBJWT_CONF_OPTS += -DWITH_TESTS=OFF -DWITH_GNUTLS=OFF
|
||||
|
||||
$(eval $(cmake-package))
|
||||
|
||||
+42
@@ -0,0 +1,42 @@
|
||||
From 1dfc4a60ebf96766b682c464ae69c453ce15105a Mon Sep 17 00:00:00 2001
|
||||
From: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
Date: Tue, 19 Aug 2025 20:04:09 +0200
|
||||
Subject: [PATCH] examples/userloc_formatter.c: drop usage of sd_debug()
|
||||
|
||||
With recent compilers, log4c-localtime fails to build with:
|
||||
|
||||
userloc_formatter.c: In function 'userloc_format':
|
||||
userloc_formatter.c:30:5: error: implicit declaration of function 'sd_debug' [-Wimplicit-function-declaration]
|
||||
30 | sd_debug("Formatter s13_userloc checking location info for userdata %X",a_event->evt_loc->loc_data);
|
||||
| ^~~~~~~~
|
||||
make[4]: *** [Makefile:519: userloc_formatter.lo] Error 1
|
||||
|
||||
This function seems to be an internal function of the log4c-localtime
|
||||
library, and is not used by any other example application. Since it's
|
||||
only used to print some debugging information, we simply get rid of
|
||||
the problematic code.
|
||||
|
||||
Upstream: https://github.com/rcmadruga/log4c-localtime/pull/2
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
examples/userloc_formatter.c | 2 --
|
||||
1 file changed, 2 deletions(-)
|
||||
|
||||
diff --git a/examples/userloc_formatter.c b/examples/userloc_formatter.c
|
||||
index 4299a48..7bcf0e9 100644
|
||||
--- a/examples/userloc_formatter.c
|
||||
+++ b/examples/userloc_formatter.c
|
||||
@@ -27,10 +27,8 @@ static const char* userloc_format(
|
||||
static char buffer[4096];
|
||||
user_locinfo_t* uloc = NULL;
|
||||
|
||||
- sd_debug("Formatter s13_userloc checking location info for userdata %X",a_event->evt_loc->loc_data);
|
||||
if (a_event->evt_loc->loc_data != NULL)
|
||||
{
|
||||
- sd_debug("Formatter s13_userloc getting a valid user location info pointer");
|
||||
uloc = (user_locinfo_t*) a_event->evt_loc->loc_data;
|
||||
sprintf(buffer, "[%s][HOST:%s][PID:%i][FILE:%s][LINE:%i][MSG:%s]",
|
||||
a_event->evt_category,
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -1,156 +0,0 @@
|
||||
From 5f1c949b1703367f7f06454fcff650bdb7bac840 Mon Sep 17 00:00:00 2001
|
||||
From: DJ Lucas <dj@linuxfromscratch.org>
|
||||
Date: Sun, 9 Sep 2018 15:46:15 +0200
|
||||
Subject: [PATCH] Fixes build issue with OpenSSL-1.1.0
|
||||
|
||||
Downloaded from
|
||||
http://www.linuxfromscratch.org/patches/blfs/svn/liboauth-1.0.3-openssl-1.1.0-2.patch
|
||||
|
||||
Patch was sent upstream: https://github.com/x42/liboauth/issues/9
|
||||
|
||||
Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
|
||||
---
|
||||
src/hash.c | 65 ++++++++++++++++++++++++++++++++++++++++++--------------------
|
||||
1 file changed, 44 insertions(+), 21 deletions(-)
|
||||
|
||||
diff --git a/src/hash.c b/src/hash.c
|
||||
index 17ff5c8..b7958f7 100644
|
||||
--- a/src/hash.c
|
||||
+++ b/src/hash.c
|
||||
@@ -362,6 +362,11 @@ looser:
|
||||
#include "oauth.h" // base64 encode fn's.
|
||||
#include <openssl/hmac.h>
|
||||
|
||||
+#if OPENSSL_VERSION_NUMBER < 0x10100000
|
||||
+#define EVP_MD_CTX_new EVP_MD_CTX_create
|
||||
+#define EVP_MD_CTX_free EVP_MD_CTX_destroy
|
||||
+#endif
|
||||
+
|
||||
char *oauth_sign_hmac_sha1 (const char *m, const char *k) {
|
||||
return(oauth_sign_hmac_sha1_raw (m, strlen(m), k, strlen(k)));
|
||||
}
|
||||
@@ -386,7 +391,7 @@ char *oauth_sign_rsa_sha1 (const char *m, const char *k) {
|
||||
unsigned char *sig = NULL;
|
||||
unsigned char *passphrase = NULL;
|
||||
unsigned int len=0;
|
||||
- EVP_MD_CTX md_ctx;
|
||||
+ EVP_MD_CTX *md_ctx;
|
||||
|
||||
EVP_PKEY *pkey;
|
||||
BIO *in;
|
||||
@@ -399,24 +404,31 @@ char *oauth_sign_rsa_sha1 (const char *m, const char *k) {
|
||||
return xstrdup("liboauth/OpenSSL: can not read private key");
|
||||
}
|
||||
|
||||
+ md_ctx = EVP_MD_CTX_new();
|
||||
+ if (md_ctx == NULL) {
|
||||
+ return xstrdup("liboauth/OpenSSL: failed to allocate EVP_MD_CTX");
|
||||
+ }
|
||||
+
|
||||
len = EVP_PKEY_size(pkey);
|
||||
sig = (unsigned char*)xmalloc((len+1)*sizeof(char));
|
||||
|
||||
- EVP_SignInit(&md_ctx, EVP_sha1());
|
||||
- EVP_SignUpdate(&md_ctx, m, strlen(m));
|
||||
- if (EVP_SignFinal (&md_ctx, sig, &len, pkey)) {
|
||||
+ EVP_SignInit(md_ctx, EVP_sha1());
|
||||
+ EVP_SignUpdate(md_ctx, m, strlen(m));
|
||||
+ if (EVP_SignFinal (md_ctx, sig, &len, pkey)) {
|
||||
char *tmp;
|
||||
sig[len] = '\0';
|
||||
tmp = oauth_encode_base64(len,sig);
|
||||
OPENSSL_free(sig);
|
||||
EVP_PKEY_free(pkey);
|
||||
+ EVP_MD_CTX_free(md_ctx);
|
||||
return tmp;
|
||||
}
|
||||
+ EVP_MD_CTX_free(md_ctx);
|
||||
return xstrdup("liboauth/OpenSSL: rsa-sha1 signing failed");
|
||||
}
|
||||
|
||||
int oauth_verify_rsa_sha1 (const char *m, const char *c, const char *s) {
|
||||
- EVP_MD_CTX md_ctx;
|
||||
+ EVP_MD_CTX *md_ctx;
|
||||
EVP_PKEY *pkey;
|
||||
BIO *in;
|
||||
X509 *cert = NULL;
|
||||
@@ -437,13 +449,18 @@ int oauth_verify_rsa_sha1 (const char *m, const char *c, const char *s) {
|
||||
return -2;
|
||||
}
|
||||
|
||||
+ md_ctx = EVP_MD_CTX_new();
|
||||
+ if (md_ctx == NULL) {
|
||||
+ return -2;
|
||||
+ }
|
||||
+
|
||||
b64d= (unsigned char*) xmalloc(sizeof(char)*strlen(s));
|
||||
slen = oauth_decode_base64(b64d, s);
|
||||
|
||||
- EVP_VerifyInit(&md_ctx, EVP_sha1());
|
||||
- EVP_VerifyUpdate(&md_ctx, m, strlen(m));
|
||||
- err = EVP_VerifyFinal(&md_ctx, b64d, slen, pkey);
|
||||
- EVP_MD_CTX_cleanup(&md_ctx);
|
||||
+ EVP_VerifyInit(md_ctx, EVP_sha1());
|
||||
+ EVP_VerifyUpdate(md_ctx, m, strlen(m));
|
||||
+ err = EVP_VerifyFinal(md_ctx, b64d, slen, pkey);
|
||||
+ EVP_MD_CTX_free(pkey);
|
||||
EVP_PKEY_free(pkey);
|
||||
xfree(b64d);
|
||||
return (err);
|
||||
@@ -455,35 +472,41 @@ int oauth_verify_rsa_sha1 (const char *m, const char *c, const char *s) {
|
||||
*/
|
||||
char *oauth_body_hash_file(char *filename) {
|
||||
unsigned char fb[BUFSIZ];
|
||||
- EVP_MD_CTX ctx;
|
||||
+ EVP_MD_CTX *ctx;
|
||||
size_t len=0;
|
||||
unsigned char *md;
|
||||
FILE *F= fopen(filename, "r");
|
||||
if (!F) return NULL;
|
||||
|
||||
- EVP_MD_CTX_init(&ctx);
|
||||
- EVP_DigestInit(&ctx,EVP_sha1());
|
||||
+ ctx = EVP_MD_CTX_new();
|
||||
+ if (ctx == NULL) {
|
||||
+ return xstrdup("liboauth/OpenSSL: failed to allocate EVP_MD_CTX");
|
||||
+ }
|
||||
+ EVP_DigestInit(ctx,EVP_sha1());
|
||||
while (!feof(F) && (len=fread(fb,sizeof(char),BUFSIZ, F))>0) {
|
||||
- EVP_DigestUpdate(&ctx, fb, len);
|
||||
+ EVP_DigestUpdate(ctx, fb, len);
|
||||
}
|
||||
fclose(F);
|
||||
len=0;
|
||||
md=(unsigned char*) xcalloc(EVP_MD_size(EVP_sha1()),sizeof(unsigned char));
|
||||
- EVP_DigestFinal(&ctx, md,(unsigned int*) &len);
|
||||
- EVP_MD_CTX_cleanup(&ctx);
|
||||
+ EVP_DigestFinal(ctx, md,(unsigned int*) &len);
|
||||
+ EVP_MD_CTX_free(ctx);
|
||||
return oauth_body_hash_encode(len, md);
|
||||
}
|
||||
|
||||
char *oauth_body_hash_data(size_t length, const char *data) {
|
||||
- EVP_MD_CTX ctx;
|
||||
+ EVP_MD_CTX *ctx;
|
||||
size_t len=0;
|
||||
unsigned char *md;
|
||||
md=(unsigned char*) xcalloc(EVP_MD_size(EVP_sha1()),sizeof(unsigned char));
|
||||
- EVP_MD_CTX_init(&ctx);
|
||||
- EVP_DigestInit(&ctx,EVP_sha1());
|
||||
- EVP_DigestUpdate(&ctx, data, length);
|
||||
- EVP_DigestFinal(&ctx, md,(unsigned int*) &len);
|
||||
- EVP_MD_CTX_cleanup(&ctx);
|
||||
+ ctx = EVP_MD_CTX_new();
|
||||
+ if (ctx == NULL) {
|
||||
+ return xstrdup("liboauth/OpenSSL: failed to allocate EVP_MD_CTX");
|
||||
+ }
|
||||
+ EVP_DigestInit(ctx,EVP_sha1());
|
||||
+ EVP_DigestUpdate(ctx, data, length);
|
||||
+ EVP_DigestFinal(ctx, md,(unsigned int*) &len);
|
||||
+ EVP_MD_CTX_free(ctx);
|
||||
return oauth_body_hash_encode(len, md);
|
||||
}
|
||||
|
||||
--
|
||||
2.14.4
|
||||
|
||||
@@ -1,11 +0,0 @@
|
||||
config BR2_PACKAGE_LIBOAUTH
|
||||
bool "liboauth"
|
||||
select BR2_PACKAGE_OPENSSL
|
||||
help
|
||||
liboauth is a collection of c functions implementing the oAuth
|
||||
Core 1.0 Rev A standard API. liboauth provides basic functions
|
||||
to escape and encode parameters according to oAuth specs and
|
||||
offers high-level functions to sign requests or verify
|
||||
signatures.
|
||||
|
||||
http://liboauth.sourceforge.net/
|
||||
@@ -1,3 +0,0 @@
|
||||
# Locally computed:
|
||||
sha256 0df60157b052f0e774ade8a8bac59d6e8d4b464058cc55f9208d72e41156811f liboauth-1.0.3.tar.gz
|
||||
sha256 c30608672733bf3abd2ccf6f3206be8d91b7ee58b007b2fdbcfbc61c655e7fb7 COPYING.MIT
|
||||
@@ -1,20 +0,0 @@
|
||||
################################################################################
|
||||
#
|
||||
# liboauth
|
||||
#
|
||||
################################################################################
|
||||
|
||||
LIBOAUTH_VERSION = 1.0.3
|
||||
LIBOAUTH_SITE = http://downloads.sourceforge.net/project/liboauth
|
||||
LIBOAUTH_INSTALL_STAGING = YES
|
||||
LIBOAUTH_DEPENDENCIES += host-pkgconf openssl
|
||||
LIBOAUTH_LICENSE = MIT
|
||||
LIBOAUTH_LICENSE_FILES = COPYING.MIT
|
||||
|
||||
ifeq ($(BR2_PACKAGE_LIBCURL),y)
|
||||
LIBOAUTH_DEPENDENCIES += libcurl
|
||||
else
|
||||
LIBOAUTH_CONF_OPTS += --disable-libcurl
|
||||
endif
|
||||
|
||||
$(eval $(autotools-package))
|
||||
@@ -0,0 +1,83 @@
|
||||
From 9f0da8467183f9f647bddc4a5b4f01aad930846a Mon Sep 17 00:00:00 2001
|
||||
From: Peter Seiderer <ps.report@gmx.net>
|
||||
Date: Mon, 2 Sep 2024 15:59:53 +0200
|
||||
Subject: [PATCH] libv4lconvert: fix jpeg-v9x/gcc-14.x compile (jpeg_mem_dest
|
||||
argument mismatch)
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
- fix jpeg_mem_dest pointer arument mismatch (long unsigned int vs. size_t)
|
||||
with jpeg-v9x/gcc-14.x 32-bit arm compile
|
||||
|
||||
Fixes:
|
||||
|
||||
../lib/libv4lconvert/jl2005bcd.c: In function ‘v4lconvert_decode_jl2005bcd’:
|
||||
../lib/libv4lconvert/jl2005bcd.c:94:46: error: passing argument 3 of ‘jpeg_mem_dest’ from incompatible pointer type [-Wincompatible-pointer-types]
|
||||
94 | jpeg_mem_dest (&cinfo, &jpeg_header, &jpeg_header_size);
|
||||
| ^~~~~~~~~~~~~~~~~
|
||||
| |
|
||||
| long unsigned int *
|
||||
In file included from ../lib/libv4lconvert/libv4lconvert-priv.h:26,
|
||||
from ../lib/libv4lconvert/jl2005bcd.c:30:
|
||||
.../host/arm-buildroot-linux-gnueabihf/sysroot/usr/include/jpeglib.h:979:28: note: expected ‘size_t *’ {aka ‘unsigned int *’} but argument is of type ‘long unsigned int *’
|
||||
979 | EXTERN(void) jpeg_mem_dest JPP((j_compress_ptr cinfo,
|
||||
| ^~~
|
||||
|
||||
../lib/libv4lconvert/jpeg.c: In function ‘init_libjpeg_cinfo’:
|
||||
../lib/libv4lconvert/jpeg.c:157:45: error: passing argument 3 of ‘jpeg_mem_dest’ from incompatible pointer type [-Wincompatible-pointer-types]
|
||||
157 | jpeg_mem_dest(&cinfo, &jpeg_header, &jpeg_header_size);
|
||||
| ^~~~~~~~~~~~~~~~~
|
||||
| |
|
||||
| long unsigned int *
|
||||
In file included from ../lib/libv4lconvert/libv4lconvert-priv.h:26,
|
||||
from ../lib/libv4lconvert/jpeg.c:21:
|
||||
.../host/arm-buildroot-linux-gnueabihf/sysroot/usr/include/jpeglib.h:979:28: note: expected ‘size_t *’ {aka ‘unsigned int *’} but argument is of type ‘long unsigned int *’
|
||||
979 | EXTERN(void) jpeg_mem_dest JPP((j_compress_ptr cinfo,
|
||||
| ^~~
|
||||
|
||||
Signed-off-by: Peter Seiderer <ps.report@gmx.net>
|
||||
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
|
||||
Upstream: https://git.linuxtv.org/v4l-utils.git/commit/?id=e11e10ff7c8a4ef69526edd275c0ed92a450fbf3
|
||||
[Romain: backport to 1.28.1]
|
||||
Signed-off-by: Romain Naour <romain.naour@smile.fr>
|
||||
---
|
||||
lib/libv4lconvert/jl2005bcd.c | 4 ++++
|
||||
lib/libv4lconvert/jpeg.c | 4 ++++
|
||||
2 files changed, 8 insertions(+)
|
||||
|
||||
diff --git a/lib/libv4lconvert/jl2005bcd.c b/lib/libv4lconvert/jl2005bcd.c
|
||||
index 707c3205..14b040f3 100644
|
||||
--- a/lib/libv4lconvert/jl2005bcd.c
|
||||
+++ b/lib/libv4lconvert/jl2005bcd.c
|
||||
@@ -63,7 +63,11 @@ int v4lconvert_decode_jl2005bcd(struct v4lconvert_data *data,
|
||||
struct jpeg_decompress_struct dinfo;
|
||||
struct jpeg_error_mgr jcerr, jderr;
|
||||
JOCTET *jpeg_header = NULL;
|
||||
+#if JPEG_LIB_VERSION >= 90
|
||||
+ size_t jpeg_header_size = 0;
|
||||
+#else
|
||||
unsigned long jpeg_header_size = 0;
|
||||
+#endif
|
||||
int i, x, y, x1, y1, jpeg_data_size, jpeg_data_idx, eoi, size;
|
||||
|
||||
/* src_size had better be bigger than 16 */
|
||||
diff --git a/lib/libv4lconvert/jpeg.c b/lib/libv4lconvert/jpeg.c
|
||||
index ebfc8149..450d0967 100644
|
||||
--- a/lib/libv4lconvert/jpeg.c
|
||||
+++ b/lib/libv4lconvert/jpeg.c
|
||||
@@ -136,7 +136,11 @@ static void init_libjpeg_cinfo(struct v4lconvert_data *data)
|
||||
{
|
||||
struct jpeg_compress_struct cinfo;
|
||||
unsigned char *jpeg_header = NULL;
|
||||
+#if JPEG_LIB_VERSION >= 90
|
||||
+ size_t jpeg_header_size = 0;
|
||||
+#else
|
||||
unsigned long jpeg_header_size = 0;
|
||||
+#endif
|
||||
|
||||
if (data->cinfo_initialized)
|
||||
return;
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -26,14 +26,20 @@ config BR2_KERNEL_HEADERS_AS_KERNEL
|
||||
|
||||
config BR2_KERNEL_HEADERS_5_4
|
||||
bool "Linux 5.4.x kernel headers"
|
||||
# Support was introduced in Linux 5.19
|
||||
depends on !BR2_loongarch64
|
||||
select BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_4
|
||||
|
||||
config BR2_KERNEL_HEADERS_5_10
|
||||
bool "Linux 5.10.x kernel headers"
|
||||
# Support was introduced in Linux 5.19
|
||||
depends on !BR2_loongarch64
|
||||
select BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_10
|
||||
|
||||
config BR2_KERNEL_HEADERS_5_15
|
||||
bool "Linux 5.15.x kernel headers"
|
||||
# Support was introduced in Linux 5.19
|
||||
depends on !BR2_loongarch64
|
||||
select BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_15
|
||||
|
||||
config BR2_KERNEL_HEADERS_6_1
|
||||
@@ -48,10 +54,6 @@ config BR2_KERNEL_HEADERS_6_12
|
||||
bool "Linux 6.12.x kernel headers"
|
||||
select BR2_TOOLCHAIN_HEADERS_AT_LEAST_6_12
|
||||
|
||||
config BR2_KERNEL_HEADERS_6_15
|
||||
bool "Linux 6.15.x kernel headers"
|
||||
select BR2_TOOLCHAIN_HEADERS_AT_LEAST_6_15
|
||||
|
||||
config BR2_KERNEL_HEADERS_6_16
|
||||
bool "Linux 6.16.x kernel headers"
|
||||
select BR2_TOOLCHAIN_HEADERS_AT_LEAST_6_16
|
||||
@@ -455,11 +457,10 @@ config BR2_DEFAULT_KERNEL_HEADERS
|
||||
default "5.4.296" if BR2_KERNEL_HEADERS_5_4
|
||||
default "5.10.240" if BR2_KERNEL_HEADERS_5_10
|
||||
default "5.15.189" if BR2_KERNEL_HEADERS_5_15
|
||||
default "6.1.147" if BR2_KERNEL_HEADERS_6_1
|
||||
default "6.6.101" if BR2_KERNEL_HEADERS_6_6
|
||||
default "6.12.41" if BR2_KERNEL_HEADERS_6_12
|
||||
default "6.15.9" if BR2_KERNEL_HEADERS_6_15
|
||||
default "6.16" if BR2_KERNEL_HEADERS_6_16
|
||||
default "6.1.148" if BR2_KERNEL_HEADERS_6_1
|
||||
default "6.6.102" if BR2_KERNEL_HEADERS_6_6
|
||||
default "6.12.43" if BR2_KERNEL_HEADERS_6_12
|
||||
default "6.16.2" if BR2_KERNEL_HEADERS_6_16
|
||||
default BR2_DEFAULT_KERNEL_VERSION if BR2_KERNEL_HEADERS_VERSION
|
||||
default "custom" if BR2_KERNEL_HEADERS_CUSTOM_TARBALL
|
||||
default BR2_KERNEL_HEADERS_CUSTOM_REPO_VERSION \
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
From c2758812867a52a6bb56b87d52c35ebff797e777 Mon Sep 17 00:00:00 2001
|
||||
From 4c264d704357220b91a070862e0490c641b3f560 Mon Sep 17 00:00:00 2001
|
||||
From: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
Date: Sun, 15 Sep 2024 15:12:07 +0200
|
||||
Subject: [PATCH] configure: fix main() prototype
|
||||
@@ -30,5 +30,5 @@ index cc586d5..16a259a 100755
|
||||
if { (eval echo configure:1059: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
ac_cv_prog_cc_works=yes
|
||||
--
|
||||
2.45.2
|
||||
2.50.1
|
||||
|
||||
|
||||
+2
-2
@@ -1,4 +1,4 @@
|
||||
From e164c9cd3207321e162f054357fcd37b06cb0b8a Mon Sep 17 00:00:00 2001
|
||||
From bbbaccd80c69a705f27e9236808d42088cf1f1cb Mon Sep 17 00:00:00 2001
|
||||
From: Uwe Ohse <uwe@ohse.de>
|
||||
Date: Mon, 2 Mar 2020 22:38:16 +0000
|
||||
Subject: [PATCH] include stdio.h to remove warning
|
||||
@@ -22,5 +22,5 @@ index 6baf4a2..d21ab35 100644
|
||||
|
||||
#if __STDC__
|
||||
--
|
||||
2.46.0
|
||||
2.50.1
|
||||
|
||||
@@ -1,40 +0,0 @@
|
||||
From aa6779c2846f13bf58575486b374ef06b2844fe8 Mon Sep 17 00:00:00 2001
|
||||
From: Yegor Yefremov <yegorslists@googlemail.com>
|
||||
Date: Tue, 21 May 2024 11:13:17 +0200
|
||||
Subject: [PATCH] lib/long-options.c: include stdlib.h
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Fixes the following error (compiled with GCC 14.x):
|
||||
|
||||
long-options.c:70:11: error: implicit declaration of function ‘exit’
|
||||
[-Wimplicit-function-declaration]
|
||||
70 | exit (0);
|
||||
| ^~~~
|
||||
|
||||
Upstream: https://github.com/UweOhse/lrzsz/pull/4
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
[Fiona: remove conditional on __GNU_LIBRARY__ to fix build with musl]
|
||||
Signed-off-by: Fiona Klute <fiona.klute@gmx.de>
|
||||
---
|
||||
lib/long-options.c | 9 +++++++++
|
||||
1 file changed, 9 insertions(+)
|
||||
|
||||
diff --git a/lib/long-options.c b/lib/long-options.c
|
||||
index 76b9796..19c84e0 100644
|
||||
--- a/lib/long-options.c
|
||||
+++ b/lib/long-options.c
|
||||
@@ -22,6 +22,9 @@
|
||||
#endif
|
||||
|
||||
#include <stdio.h>
|
||||
+
|
||||
+#include <stdlib.h>
|
||||
+
|
||||
#include <getopt.h>
|
||||
#include "long-options.h"
|
||||
|
||||
--
|
||||
2.46.0
|
||||
|
||||
+3
-3
@@ -1,9 +1,9 @@
|
||||
From a9faaf7f02811e7409074362700e963609885ba6 Mon Sep 17 00:00:00 2001
|
||||
From b526a62d5992d838ee34fb992defdeb8ee0ed594 Mon Sep 17 00:00:00 2001
|
||||
From: Wolfram Sang <wsa+renesas@sang-engineering.com>
|
||||
Date: Fri, 29 Nov 2024 14:14:25 +0100
|
||||
Subject: [PATCH] FTBFS fix missing includes
|
||||
|
||||
From: https://sources.debian.org/data/main/l/lrzsz/0.12.21rc-0.1/debian/patches/include.diff
|
||||
Taken from: https://sources.debian.org/data/main/l/lrzsz/0.12.21rc-0.1/debian/patches/include.diff
|
||||
|
||||
Description: Fixes FTBFS (missing includes)
|
||||
Author: Martin A. Godisch <godisch@debian.org>
|
||||
@@ -120,5 +120,5 @@ index dd9736b..7bc3736 100644
|
||||
#include <ctype.h>
|
||||
#include <errno.h>
|
||||
--
|
||||
2.45.2
|
||||
2.50.1
|
||||
|
||||
@@ -0,0 +1,93 @@
|
||||
From 01a8cdf3f8e64b80ff219c250c899605c50312f5 Mon Sep 17 00:00:00 2001
|
||||
From: Khem Raj <raj.khem@gmail.com>
|
||||
Date: Sat, 22 Mar 2025 23:06:54 -0700
|
||||
Subject: [PATCH] Fix build with GCC 15
|
||||
|
||||
This is collection of changes needed to get compiling with gcc-15
|
||||
which switched to use C23 as default std.
|
||||
|
||||
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
||||
Upstream: https://github.com/UweOhse/lrzsz/pull/8
|
||||
Signed-off-by: Frank Chung <uuidxx@163.com>
|
||||
---
|
||||
lib/error.c | 2 +-
|
||||
lib/getopt.h | 2 +-
|
||||
lib/long-options.c | 3 ++-
|
||||
lib/long-options.h | 2 +-
|
||||
lib/xstrtol.c | 2 --
|
||||
5 files changed, 5 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/lib/error.c b/lib/error.c
|
||||
index 3861578..2a2f1ff 100644
|
||||
--- a/lib/error.c
|
||||
+++ b/lib/error.c
|
||||
@@ -74,7 +74,7 @@ extern char *program_name;
|
||||
|
||||
# if HAVE_STRERROR
|
||||
# ifndef strerror /* On some systems, strerror is a macro */
|
||||
-char *strerror ();
|
||||
+char *strerror (int);
|
||||
# endif
|
||||
# else
|
||||
static char *
|
||||
diff --git a/lib/getopt.h b/lib/getopt.h
|
||||
index 4ac33b7..46971cb 100644
|
||||
--- a/lib/getopt.h
|
||||
+++ b/lib/getopt.h
|
||||
@@ -101,7 +101,7 @@ struct option
|
||||
errors, only prototype getopt for the GNU C library. */
|
||||
extern int getopt (int argc, char *const *argv, const char *shortopts);
|
||||
#else /* not __GNU_LIBRARY__ */
|
||||
-extern int getopt ();
|
||||
+extern int getopt (int, char * const [], const char *);
|
||||
#endif /* __GNU_LIBRARY__ */
|
||||
extern int getopt_long (int argc, char *const *argv, const char *shortopts,
|
||||
const struct option *longopts, int *longind);
|
||||
diff --git a/lib/long-options.c b/lib/long-options.c
|
||||
index fe069fd..4db5cea 100644
|
||||
--- a/lib/long-options.c
|
||||
+++ b/lib/long-options.c
|
||||
@@ -22,6 +22,7 @@
|
||||
#endif
|
||||
|
||||
#include <stdio.h>
|
||||
+#include <stdlib.h>
|
||||
#include <getopt.h>
|
||||
#include "long-options.h"
|
||||
|
||||
@@ -43,7 +44,7 @@ parse_long_options (argc, argv,version, usage)
|
||||
int argc;
|
||||
char **argv;
|
||||
void (*version)();
|
||||
- void (*usage)();
|
||||
+ void (*usage)(int);
|
||||
#endif
|
||||
{
|
||||
int c;
|
||||
diff --git a/lib/long-options.h b/lib/long-options.h
|
||||
index 14459cd..3fb8fa6 100644
|
||||
--- a/lib/long-options.h
|
||||
+++ b/lib/long-options.h
|
||||
@@ -6,5 +6,5 @@
|
||||
#endif
|
||||
|
||||
void parse_long_options __P ((int _argc, char **_argv,
|
||||
- void (*_version) (void),
|
||||
+ void (*_version) (),
|
||||
void (*_usage) (int)));
|
||||
diff --git a/lib/xstrtol.c b/lib/xstrtol.c
|
||||
index d7b4b56..7d0737d 100644
|
||||
--- a/lib/xstrtol.c
|
||||
+++ b/lib/xstrtol.c
|
||||
@@ -65,8 +65,6 @@ extern int errno;
|
||||
} \
|
||||
while (0)
|
||||
|
||||
-__unsigned long int __strtol ();
|
||||
-
|
||||
/* FIXME: comment. */
|
||||
|
||||
strtol_error
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -0,0 +1,38 @@
|
||||
From 8d91782ae404c59f42029b3af394fbccb2d43856 Mon Sep 17 00:00:00 2001
|
||||
From: Uwe Ohse <uwe@ohse.de>
|
||||
Date: Mon, 2 Mar 2020 21:24:45 +0000
|
||||
Subject: [PATCH] remove old prototypes
|
||||
|
||||
Upstream: 34f9527076276aace5fc2e31388e09aaaf1773eb
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
src/lrz.c | 6 +-----
|
||||
1 file changed, 1 insertion(+), 5 deletions(-)
|
||||
|
||||
diff --git a/src/lrz.c b/src/lrz.c
|
||||
index 63e1326..a31e82d 100644
|
||||
--- a/src/lrz.c
|
||||
+++ b/src/lrz.c
|
||||
@@ -32,6 +32,7 @@
|
||||
#include <ctype.h>
|
||||
#include <errno.h>
|
||||
#include <getopt.h>
|
||||
+#include <time.h>
|
||||
|
||||
#ifdef HAVE_UTIME_H
|
||||
#include <utime.h>
|
||||
@@ -42,11 +43,6 @@
|
||||
#include "xstrtoul.h"
|
||||
#include "error.h"
|
||||
|
||||
-#ifndef STRICT_PROTOTYPES
|
||||
-extern time_t time();
|
||||
-extern char *strerror();
|
||||
-extern char *strstr();
|
||||
-#endif
|
||||
|
||||
#ifndef HAVE_ERRNO_DECLARATION
|
||||
extern int errno;
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
From 755da0781a2b20674f183cbf8cddf28ac56f7bad Mon Sep 17 00:00:00 2001
|
||||
From: Uwe Ohse <uwe@ohse.de>
|
||||
Date: Mon, 2 Mar 2020 21:26:21 +0000
|
||||
Subject: [PATCH] remove old prototypes
|
||||
|
||||
Upstream: 7cdaef47634d2d8944a4192bb87c6e57dd24c41f
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
src/lsz.c | 6 ------
|
||||
1 file changed, 6 deletions(-)
|
||||
|
||||
diff --git a/src/lsz.c b/src/lsz.c
|
||||
index 1598150..b8041b2 100644
|
||||
--- a/src/lsz.c
|
||||
+++ b/src/lsz.c
|
||||
@@ -51,12 +51,6 @@ void *mm_addr=NULL;
|
||||
#include "xstrtoul.h"
|
||||
#include "error.h"
|
||||
|
||||
-#ifndef STRICT_PROTOTYPES
|
||||
-extern time_t time();
|
||||
-extern char *strerror();
|
||||
-extern char *strstr();
|
||||
-#endif
|
||||
-
|
||||
#ifndef HAVE_ERRNO_DECLARATION
|
||||
extern int errno;
|
||||
#endif
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -11,7 +11,9 @@ LRZSZ_LICENSE = GPL-2.0+
|
||||
LRZSZ_LICENSE_FILES = COPYING
|
||||
LRZSZ_CPE_ID_VALID = YES
|
||||
LRZSZ_DEPENDENCIES = $(TARGET_NLS_DEPENDENCIES)
|
||||
LRZSZ_CONF_ENV = LIBS=$(TARGET_NLS_LIBS)
|
||||
LRZSZ_CONF_ENV = \
|
||||
ac_cv_type_signal=void \
|
||||
LIBS=$(TARGET_NLS_LIBS)
|
||||
|
||||
define LRZSZ_INSTALL_TARGET_CMDS
|
||||
$(INSTALL) -m 0755 -D $(@D)/src/lrz $(TARGET_DIR)/usr/bin/rz
|
||||
|
||||
@@ -12,7 +12,7 @@ endif
|
||||
|
||||
# Not possible to directly refer to mesa3d variables, because of
|
||||
# first/second expansion trickery...
|
||||
MESA3D_HEADERS_VERSION = 25.1.7
|
||||
MESA3D_HEADERS_VERSION = 25.1.8
|
||||
MESA3D_HEADERS_SOURCE = mesa-$(MESA3D_HEADERS_VERSION).tar.xz
|
||||
MESA3D_HEADERS_SITE = https://archive.mesa3d.org
|
||||
MESA3D_HEADERS_DL_SUBDIR = mesa3d
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# From https://lists.freedesktop.org/archives/mesa-announce/2025-July/000814.html
|
||||
sha256 4afd26a3cc93c3dd27183d4c4845f1ca7d683f6343900b54995809b3271ebed6 mesa-25.1.7.tar.xz
|
||||
sha512 a62fc6970efce3b4861094be2ef3139a3b18a6a51d770ead9f04d39592abc0a13a04702c552637e63bc965236f66ad545d30a9ec446b24f0bfc5bbb7cf0f0757 mesa-25.1.7.tar.xz
|
||||
# From https://lists.freedesktop.org/archives/mesa-announce/2025-August/000817.html
|
||||
sha256 5cf1571d0d646d90047f3d93f57acc787cf88ec7e95efe172c555b492c30fb71 mesa-25.1.8.tar.xz
|
||||
sha512 98435d52a2855c71b15060785c225dc674b3565545a8581a5dd501605a04f9d597636282f1bce61e7a2e8ee98c31ecf7fbccab594571e31bc8b827e18e98aaa5 mesa-25.1.8.tar.xz
|
||||
# License
|
||||
sha256 0d1a0472ecc81830e75c20d59b0ea02841e3db21255e0ebad97ab682c54d6615 docs/license.rst
|
||||
sha256 323c587d0ccf10e376f8bf9a7f31fb4ca6078105194b42e0b1e0ee2bc9bde71f licenses/MIT
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
################################################################################
|
||||
|
||||
# When updating the version, please also update mesa3d-headers
|
||||
MESA3D_VERSION = 25.1.7
|
||||
MESA3D_VERSION = 25.1.8
|
||||
MESA3D_SOURCE = mesa-$(MESA3D_VERSION).tar.xz
|
||||
MESA3D_SITE = https://archive.mesa3d.org
|
||||
MESA3D_LICENSE = MIT, SGI, Khronos
|
||||
|
||||
@@ -14,6 +14,12 @@ P11_KIT_CONF_ENV = ac_cv_have_decl_program_invocation_short_name=yes \
|
||||
P11_KIT_LICENSE = BSD-3-Clause
|
||||
P11_KIT_LICENSE_FILES = COPYING
|
||||
P11_KIT_CPE_ID_VALID = YES
|
||||
# Needed because the pre-generated ./configure script has an old
|
||||
# broken expansion of AC_HEADER_STDBOOL, which incorrectly detects
|
||||
# that <stdbool.h> cannot be used, causing breakage down the road.
|
||||
P11_KIT_AUTORECONF = YES
|
||||
# Needed for autoreconf
|
||||
P11_KIT_DEPENDENCIES = host-pkgconf
|
||||
|
||||
ifeq ($(BR2_PACKAGE_LIBFFI),y)
|
||||
P11_KIT_DEPENDENCIES += host-pkgconf libffi
|
||||
|
||||
@@ -0,0 +1,77 @@
|
||||
From de1068d634519abf2461dac9427b5ff24b6603af Mon Sep 17 00:00:00 2001
|
||||
From: Mikhail Galanin <mikhail.galanin@team.bumble.com>
|
||||
Date: Tue, 24 Aug 2021 08:28:47 +0100
|
||||
Subject: [PATCH] php8: Signature of write_property/read_property was changed
|
||||
in https://github.com/php/php-src/commit/91ef4124e56
|
||||
|
||||
Upstream: upstream dead, taken from fork at https://github.com/badoo/php-lua/pull/8
|
||||
Signed-off-by: Alexis Lothoré <alexis.lothore@bootlin.com>
|
||||
---
|
||||
lua.c | 28 ++++++++++++++--------------
|
||||
1 file changed, 14 insertions(+), 14 deletions(-)
|
||||
|
||||
diff --git a/lua.c b/lua.c
|
||||
index edc2868..32c1471 100755
|
||||
--- a/lua.c
|
||||
+++ b/lua.c
|
||||
@@ -229,46 +229,46 @@ zend_object *php_lua_create_object(zend_class_entry *ce)
|
||||
|
||||
/** {{{ static zval * php_lua_read_property(zval *object, zval *member, int type)
|
||||
*/
|
||||
-zval *php_lua_read_property(zval *object, zval *member, int type, void **cache_slot, zval *rv){
|
||||
- lua_State *L = (Z_LUAVAL_P(object))->L;
|
||||
- zend_string *str_member;
|
||||
+zval *php_lua_read_property(zend_object *object, zend_string *member, int type, void **cache_slot, zval *rv){
|
||||
+ lua_State *L = php_lua_obj_from_obj(object)->L;
|
||||
|
||||
if (type != BP_VAR_R) {
|
||||
ZVAL_NULL(rv);
|
||||
return rv;
|
||||
}
|
||||
|
||||
- str_member = zval_get_string(member);
|
||||
#if (LUA_VERSION_NUM < 502)
|
||||
- lua_getfield(L, LUA_GLOBALSINDEX, ZSTR_VAL(str_member));
|
||||
+ lua_getfield(L, LUA_GLOBALSINDEX, ZSTR_VAL(member));
|
||||
#else
|
||||
- lua_getglobal(L, ZSTR_VAL(str_member));
|
||||
+ lua_getglobal(L, ZSTR_VAL(member));
|
||||
#endif
|
||||
- zend_string_release(str_member);
|
||||
|
||||
- php_lua_get_zval_from_lua(L, -1, object, rv);
|
||||
+ zval lua_zval_object;
|
||||
+ ZVAL_OBJ(&lua_zval_object, object);
|
||||
+
|
||||
+ php_lua_get_zval_from_lua(L, -1, &lua_zval_object, rv);
|
||||
lua_pop(L, 1);
|
||||
+
|
||||
return rv;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
/** {{{ static void php_lua_write_property(zval *object, zval *member, zval *value)
|
||||
*/
|
||||
-static void php_lua_write_property(zval *object, zval *member, zval *value, void ** key) {
|
||||
- lua_State *L = (Z_LUAVAL_P(object))->L;
|
||||
- zend_string *str_member = zval_get_string(member);
|
||||
+static zval* php_lua_write_property(zend_object *object, zend_string *member, zval *value, void ** key) {
|
||||
+ lua_State *L = php_lua_obj_from_obj(object)->L;
|
||||
|
||||
#if (LUA_VERSION_NUM < 502)
|
||||
- php_lua_send_zval_to_lua(L, member);
|
||||
+ lua_pushlstring(L, ZSTR_VAL(val), ZSTR_LEN(val));
|
||||
php_lua_send_zval_to_lua(L, value);
|
||||
|
||||
lua_settable(L, LUA_GLOBALSINDEX);
|
||||
#else
|
||||
php_lua_send_zval_to_lua(L, value);
|
||||
- lua_setglobal(L, Z_STRVAL_P(member));
|
||||
+ lua_setglobal(L, ZSTR_VAL(member));
|
||||
#endif
|
||||
|
||||
- zend_string_release(str_member);
|
||||
+ return value;
|
||||
}
|
||||
/* }}} */
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
# Locally calculated
|
||||
sha256 183ab7c6107de271a2959ff268f55c9b6c76b2cf0029e6584fccc019686601e0 proftpd-1.3.8b.tar.gz
|
||||
sha256 42ba40d8d5a5a9f28c9dcd7f15aa6b5368fe5efceaacb999041311b170f076d5 proftpd-1.3.8d.tar.gz
|
||||
sha256 391a473d755c29b5326fb726326ff3c37e42512f53a8f5789fc310232150bf80 COPYING
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
#
|
||||
################################################################################
|
||||
|
||||
PROFTPD_VERSION = 1.3.8b
|
||||
PROFTPD_VERSION = 1.3.8d
|
||||
PROFTPD_SITE = https://github.com/proftpd/proftpd/archive/v$(PROFTPD_VERSION)
|
||||
PROFTPD_LICENSE = GPL-2.0+
|
||||
PROFTPD_LICENSE_FILES = COPYING
|
||||
@@ -27,6 +27,14 @@ PROFTPD_CONF_OPTS = \
|
||||
--with-gnu-ld \
|
||||
--without-openssl-cmdline
|
||||
|
||||
# source code contains a number of variables named 'bool', which
|
||||
# conflicts with the C23 keyword. Fixed upstream in 1.3.9 with
|
||||
# https://github.com/proftpd/proftpd/commit/61be7eb14f200b97804a3cfa85fed51661067c62
|
||||
# so can be dropped when bumping to that
|
||||
ifeq ($(BR2_TOOLCHAIN_GCC_AT_LEAST_15),y)
|
||||
PROFTPD_CONF_ENV += CFLAGS="$(TARGET_CFLAGS) -std=gnu18"
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_PACKAGE_LIBIDN2),y)
|
||||
PROFTPD_DEPENDENCIES += libidn2
|
||||
endif
|
||||
|
||||
@@ -0,0 +1,70 @@
|
||||
From 3753ad491bf5847a11a7f4baf3ecaa490e0e9111 Mon Sep 17 00:00:00 2001
|
||||
From: Xu Han <xuhan@redhat.com>
|
||||
Date: Wed, 31 Jan 2024 14:57:37 +0800
|
||||
Subject: [PATCH] Drop the use of pipes
|
||||
|
||||
`pipes` was deprecated since version 3.11 so let's replace the use
|
||||
of that module with the alternatives.
|
||||
|
||||
Signed-off-by: Xu Han <xuhan@redhat.com>
|
||||
Upstream: https://github.com/avocado-framework/aexpect/commit/f2b888b1bd453a46820d38b62fd2b5db1228e4b7
|
||||
[Romain: backport to 1.7.0]
|
||||
Signed-off-by: Romain Naour <romain.naour@smile.fr>
|
||||
---
|
||||
aexpect/remote.py | 12 ++++++------
|
||||
1 file changed, 6 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/aexpect/remote.py b/aexpect/remote.py
|
||||
index d7e09ec..2bfd92a 100644
|
||||
--- a/aexpect/remote.py
|
||||
+++ b/aexpect/remote.py
|
||||
@@ -47,7 +47,7 @@ import logging
|
||||
import time
|
||||
import re
|
||||
import os
|
||||
-import pipes
|
||||
+import shlex
|
||||
|
||||
from aexpect.client import Expect
|
||||
from aexpect.client import RemoteSession
|
||||
@@ -217,8 +217,8 @@ def quote_path(path):
|
||||
:return: Shell escaped version
|
||||
"""
|
||||
if isinstance(path, list):
|
||||
- return ' '.join(map(pipes.quote, path))
|
||||
- return pipes.quote(path)
|
||||
+ return ' '.join(map(shlex.quote, path))
|
||||
+ return shlex.quote(path)
|
||||
|
||||
|
||||
def handle_prompts(session, username, password, prompt=PROMPT_LINUX,
|
||||
@@ -621,7 +621,7 @@ def scp_to_remote(host, port, username, password, local_path, remote_path,
|
||||
r"-o StrictHostKeyChecking=no "
|
||||
fr"-o PreferredAuthentications=password {limit} "
|
||||
fr"-P {port} {quote_path(local_path)} {username}@\[{host}\]:"
|
||||
- fr"{pipes.quote(remote_path)}")
|
||||
+ fr"{shlex.quote(remote_path)}")
|
||||
password_list = [password]
|
||||
return remote_scp(command, password_list,
|
||||
log_filename, log_function, timeout)
|
||||
@@ -664,7 +664,7 @@ def scp_from_remote(host, port, username, password, remote_path, local_path,
|
||||
r"-o StrictHostKeyChecking=no "
|
||||
fr"-o PreferredAuthentications=password {limit} "
|
||||
fr"-P {port} {username}@\[{host}\]:{quote_path(remote_path)} "
|
||||
- fr"{pipes.quote(local_path)}")
|
||||
+ fr"{shlex.quote(local_path)}")
|
||||
password_list = [password]
|
||||
remote_scp(command, password_list,
|
||||
log_filename, log_function, timeout)
|
||||
@@ -717,7 +717,7 @@ def scp_between_remotes(src, dst, port, s_passwd, d_passwd, s_name, d_name,
|
||||
r"-o StrictHostKeyChecking=no "
|
||||
fr"-o PreferredAuthentications=password {limit} -P {port}"
|
||||
fr" {s_name}@\[{src}\]:{quote_path(s_path)} {d_name}@\[{dst}\]"
|
||||
- fr":{pipes.quote(d_path)}")
|
||||
+ fr":{shlex.quote(d_path)}")
|
||||
password_list = [s_passwd, d_passwd]
|
||||
return remote_scp(command, password_list,
|
||||
log_filename, log_function, timeout)
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
config BR2_PACKAGE_PYTHON_PYROUTE2
|
||||
bool "python-pyroute2"
|
||||
select BR2_PACKAGE_PYTHON3_SQLITE
|
||||
select BR2_PACKAGE_PYTHON3_SSL # runtime
|
||||
help
|
||||
Python netlink library - Linux network / netns / wireless /
|
||||
ipset configuration.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
From 96a5a899445bee3bc1b750cc4aca730cc1733375 Mon Sep 17 00:00:00 2001
|
||||
From 52bb6f2a3ef352cda16d95a588a0356da562de8e Mon Sep 17 00:00:00 2001
|
||||
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
|
||||
Date: Wed, 22 Feb 2017 16:21:31 -0800
|
||||
Subject: [PATCH] Make the build of pyc files conditional
|
||||
@@ -21,10 +21,10 @@ Signed-off-by: Vincent Fazio <vfazio@gmail.com>
|
||||
2 files changed, 9 insertions(+)
|
||||
|
||||
diff --git a/Makefile.pre.in b/Makefile.pre.in
|
||||
index 46a37ded970..b9a2ab2b02b 100644
|
||||
index a7dc9709d62..a1d460b36f4 100644
|
||||
--- a/Makefile.pre.in
|
||||
+++ b/Makefile.pre.in
|
||||
@@ -2563,6 +2563,7 @@ libinstall: all $(srcdir)/Modules/xxmodule.c
|
||||
@@ -2570,6 +2570,7 @@ libinstall: all $(srcdir)/Modules/xxmodule.c
|
||||
patch --force --reject-file "$(abs_builddir)/app-store-compliance.rej" --strip 2 --directory "$(DESTDIR)$(LIBDEST)" --input "$(abs_srcdir)/$(APP_STORE_COMPLIANCE_PATCH)" || true ; \
|
||||
fi
|
||||
@ # Build PYC files for the 3 optimization levels (0, 1, 2)
|
||||
@@ -32,7 +32,7 @@ index 46a37ded970..b9a2ab2b02b 100644
|
||||
-PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
|
||||
$(PYTHON_FOR_BUILD) -Wi $(DESTDIR)$(LIBDEST)/compileall.py \
|
||||
-o 0 -o 1 -o 2 $(COMPILEALL_OPTS) -d $(LIBDEST) -f \
|
||||
@@ -2572,6 +2573,7 @@ libinstall: all $(srcdir)/Modules/xxmodule.c
|
||||
@@ -2579,6 +2580,7 @@ libinstall: all $(srcdir)/Modules/xxmodule.c
|
||||
$(PYTHON_FOR_BUILD) -Wi $(DESTDIR)$(LIBDEST)/compileall.py \
|
||||
-o 0 -o 1 -o 2 $(COMPILEALL_OPTS) -d $(LIBDEST)/site-packages -f \
|
||||
-x badsyntax $(DESTDIR)$(LIBDEST)/site-packages
|
||||
@@ -41,7 +41,7 @@ index 46a37ded970..b9a2ab2b02b 100644
|
||||
# bpo-21536: Misc/python-config.sh is generated in the build directory
|
||||
# from $(srcdir)Misc/python-config.sh.in.
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 3fcb18922c5..c60381f9605 100644
|
||||
index 597a44b331a..edac73ec5d3 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -1513,6 +1513,13 @@ fi
|
||||
@@ -59,5 +59,5 @@ index 3fcb18922c5..c60381f9605 100644
|
||||
# library that we build, but we do not want to link against it (we
|
||||
# will find it with a -framework option). For this reason there is an
|
||||
--
|
||||
2.34.1
|
||||
2.50.1
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
From 7db6ccbed6dd0b47011d1dfecb040d447ccf4595 Mon Sep 17 00:00:00 2001
|
||||
From 8ba9dc9a12687d37454dd949409599f108f1ce44 Mon Sep 17 00:00:00 2001
|
||||
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
|
||||
Date: Wed, 22 Feb 2017 17:07:56 -0800
|
||||
Subject: [PATCH] Add an option to disable pydoc
|
||||
@@ -24,10 +24,10 @@ Signed-off-by: Vincent Fazio <vfazio@gmail.com>
|
||||
2 files changed, 14 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/Makefile.pre.in b/Makefile.pre.in
|
||||
index b9a2ab2b02b..4360b60165a 100644
|
||||
index a1d460b36f4..81f3fd54ee4 100644
|
||||
--- a/Makefile.pre.in
|
||||
+++ b/Makefile.pre.in
|
||||
@@ -2275,7 +2275,9 @@ bininstall: commoninstall altbininstall
|
||||
@@ -2281,7 +2281,9 @@ bininstall: commoninstall altbininstall
|
||||
-rm -f $(DESTDIR)$(BINDIR)/idle3
|
||||
(cd $(DESTDIR)$(BINDIR); $(LN) -s idle$(VERSION) idle3)
|
||||
-rm -f $(DESTDIR)$(BINDIR)/pydoc3
|
||||
@@ -37,7 +37,7 @@ index b9a2ab2b02b..4360b60165a 100644
|
||||
if test "x$(LIPO_32BIT_FLAGS)" != "x" ; then \
|
||||
rm -f $(DESTDIR)$(BINDIR)/python3-32$(EXE); \
|
||||
(cd $(DESTDIR)$(BINDIR); $(LN) -s python$(VERSION)-32$(EXE) python3-32$(EXE)) \
|
||||
@@ -2325,7 +2327,6 @@ LIBSUBDIRS= asyncio \
|
||||
@@ -2331,7 +2333,6 @@ LIBSUBDIRS= asyncio \
|
||||
logging \
|
||||
multiprocessing multiprocessing/dummy \
|
||||
pathlib \
|
||||
@@ -45,7 +45,7 @@ index b9a2ab2b02b..4360b60165a 100644
|
||||
re \
|
||||
site-packages \
|
||||
sqlite3 \
|
||||
@@ -2483,6 +2484,10 @@ TESTSUBDIRS= idlelib/idle_test \
|
||||
@@ -2490,6 +2491,10 @@ TESTSUBDIRS= idlelib/idle_test \
|
||||
|
||||
COMPILEALL_OPTS=-j0
|
||||
|
||||
@@ -56,7 +56,7 @@ index b9a2ab2b02b..4360b60165a 100644
|
||||
TEST_MODULES=@TEST_MODULES@
|
||||
|
||||
.PHONY: libinstall
|
||||
@@ -2710,7 +2715,9 @@ libainstall: all scripts
|
||||
@@ -2717,7 +2722,9 @@ libainstall: all scripts
|
||||
$(INSTALL_SCRIPT) python-config.py $(DESTDIR)$(LIBPL)/python-config.py
|
||||
$(INSTALL_SCRIPT) python-config $(DESTDIR)$(BINDIR)/python$(LDVERSION)-config
|
||||
$(INSTALL_SCRIPT) $(SCRIPT_IDLE) $(DESTDIR)$(BINDIR)/idle$(VERSION)
|
||||
@@ -67,10 +67,10 @@ index b9a2ab2b02b..4360b60165a 100644
|
||||
"`echo $(MACHDEP) | sed 's/^\(...\).*/\1/'`" = "aix" ]; then \
|
||||
echo; echo "Installing support files for building shared extension modules on AIX:"; \
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index c60381f9605..583adc7e16a 100644
|
||||
index edac73ec5d3..7ed4fa578f3 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -4661,6 +4661,12 @@ AS_VAR_IF([posix_threads], [stub], [
|
||||
@@ -4749,6 +4749,12 @@ AS_VAR_IF([posix_threads], [stub], [
|
||||
AC_DEFINE([HAVE_PTHREAD_STUBS], [1], [Define if platform requires stubbed pthreads support])
|
||||
])
|
||||
|
||||
@@ -84,5 +84,5 @@ index c60381f9605..583adc7e16a 100644
|
||||
AH_TEMPLATE([ENABLE_IPV6], [Define if --enable-ipv6 is specified])
|
||||
AC_MSG_CHECKING([if --enable-ipv6 is specified])
|
||||
--
|
||||
2.34.1
|
||||
2.50.1
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
From 8da950588cd2597a6588a46374ad917d642c583d Mon Sep 17 00:00:00 2001
|
||||
From 463c64020b288b8ddfd32a63c4a23ab7369b9669 Mon Sep 17 00:00:00 2001
|
||||
From: Maxime Ripard <maxime.ripard@free-electrons.com>
|
||||
Date: Wed, 22 Feb 2017 17:45:14 -0800
|
||||
Subject: [PATCH] Add an option to disable IDLE
|
||||
@@ -23,10 +23,10 @@ Signed-off-by: Vincent Fazio <vfazio@gmail.com>
|
||||
2 files changed, 14 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/Makefile.pre.in b/Makefile.pre.in
|
||||
index 4360b60165a..e88f89b91b1 100644
|
||||
index 81f3fd54ee4..2d067730633 100644
|
||||
--- a/Makefile.pre.in
|
||||
+++ b/Makefile.pre.in
|
||||
@@ -2273,7 +2273,9 @@ bininstall: commoninstall altbininstall
|
||||
@@ -2279,7 +2279,9 @@ bininstall: commoninstall altbininstall
|
||||
-rm -f $(DESTDIR)$(LIBPC)/python3-embed.pc
|
||||
(cd $(DESTDIR)$(LIBPC); $(LN) -s python-$(VERSION)-embed.pc python3-embed.pc)
|
||||
-rm -f $(DESTDIR)$(BINDIR)/idle3
|
||||
@@ -36,7 +36,7 @@ index 4360b60165a..e88f89b91b1 100644
|
||||
-rm -f $(DESTDIR)$(BINDIR)/pydoc3
|
||||
ifeq (@PYDOC@,yes)
|
||||
(cd $(DESTDIR)$(BINDIR); $(LN) -s pydoc$(VERSION) pydoc3)
|
||||
@@ -2321,7 +2323,6 @@ LIBSUBDIRS= asyncio \
|
||||
@@ -2327,7 +2329,6 @@ LIBSUBDIRS= asyncio \
|
||||
ensurepip ensurepip/_bundled \
|
||||
html \
|
||||
http \
|
||||
@@ -44,7 +44,7 @@ index 4360b60165a..e88f89b91b1 100644
|
||||
importlib importlib/resources importlib/metadata \
|
||||
json \
|
||||
logging \
|
||||
@@ -2488,6 +2489,10 @@ ifeq (@PYDOC@,yes)
|
||||
@@ -2495,6 +2496,10 @@ ifeq (@PYDOC@,yes)
|
||||
LIBSUBDIRS += pydoc_data
|
||||
endif
|
||||
|
||||
@@ -55,7 +55,7 @@ index 4360b60165a..e88f89b91b1 100644
|
||||
TEST_MODULES=@TEST_MODULES@
|
||||
|
||||
.PHONY: libinstall
|
||||
@@ -2714,7 +2719,9 @@ libainstall: all scripts
|
||||
@@ -2721,7 +2726,9 @@ libainstall: all scripts
|
||||
$(INSTALL_SCRIPT) $(srcdir)/install-sh $(DESTDIR)$(LIBPL)/install-sh
|
||||
$(INSTALL_SCRIPT) python-config.py $(DESTDIR)$(LIBPL)/python-config.py
|
||||
$(INSTALL_SCRIPT) python-config $(DESTDIR)$(BINDIR)/python$(LDVERSION)-config
|
||||
@@ -66,10 +66,10 @@ index 4360b60165a..e88f89b91b1 100644
|
||||
$(INSTALL_SCRIPT) $(SCRIPT_PYDOC) $(DESTDIR)$(BINDIR)/pydoc$(VERSION)
|
||||
endif
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 583adc7e16a..744c5bebd39 100644
|
||||
index 7ed4fa578f3..d5dac4bf8bc 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -7810,6 +7810,12 @@ PY_STDLIB_MOD([xxlimited_35], [test "$TEST_MODULES" = yes], [test "$ac_cv_func_d
|
||||
@@ -7927,6 +7927,12 @@ PY_STDLIB_MOD([xxlimited_35], [test "$TEST_MODULES" = yes], [test "$ac_cv_func_d
|
||||
# substitute multiline block, must come after last PY_STDLIB_MOD()
|
||||
AC_SUBST([MODULE_BLOCK])
|
||||
|
||||
@@ -83,5 +83,5 @@ index 583adc7e16a..744c5bebd39 100644
|
||||
AC_CONFIG_FILES(m4_normalize([
|
||||
Makefile.pre
|
||||
--
|
||||
2.34.1
|
||||
2.50.1
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
From 3de626186e6abeb23f0c3c0f6442058884e4a3f6 Mon Sep 17 00:00:00 2001
|
||||
From 930c4763ac46d180880615eceeb68698e9b35e85 Mon Sep 17 00:00:00 2001
|
||||
From: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
Date: Tue, 6 Feb 2024 22:46:59 +0100
|
||||
Subject: [PATCH] configure.ac: move PY_STDLIB_MOD_SET_NA further up
|
||||
@@ -16,7 +16,7 @@ Signed-off-by: Vincent Fazio <vfazio@gmail.com>
|
||||
1 file changed, 6 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 744c5bebd39..8d56a24ffcb 100644
|
||||
index d5dac4bf8bc..6635aaa134d 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -95,6 +95,12 @@ AC_DEFUN([PY_CHECK_EMSCRIPTEN_PORT], [
|
||||
@@ -32,7 +32,7 @@ index 744c5bebd39..8d56a24ffcb 100644
|
||||
AC_SUBST([BASECPPFLAGS])
|
||||
if test "$srcdir" != . -a "$srcdir" != "$(pwd)"; then
|
||||
# If we're building out-of-tree, we need to make sure the following
|
||||
@@ -7478,13 +7484,6 @@ AS_VAR_IF([ac_cv_libatomic_needed], [yes],
|
||||
@@ -7595,13 +7601,6 @@ AS_VAR_IF([ac_cv_libatomic_needed], [yes],
|
||||
LIBATOMIC=${LIBATOMIC-"-latomic"}])
|
||||
_RESTORE_VAR([CPPFLAGS])
|
||||
|
||||
@@ -47,5 +47,5 @@ index 744c5bebd39..8d56a24ffcb 100644
|
||||
dnl Modules that are not available on some platforms
|
||||
AS_CASE([$ac_sys_system],
|
||||
--
|
||||
2.34.1
|
||||
2.50.1
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
From bd588150572c48da6dbb2f65eb21587f0f20dfaf Mon Sep 17 00:00:00 2001
|
||||
From 8f6beca556599479705444af7cc7c49b2b964af8 Mon Sep 17 00:00:00 2001
|
||||
From: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
Date: Tue, 6 Feb 2024 22:12:20 +0100
|
||||
Subject: [PATCH] Add option to disable the sqlite3 module
|
||||
@@ -20,10 +20,10 @@ Signed-off-by: Vincent Fazio <vfazio@gmail.com>
|
||||
2 files changed, 11 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/Makefile.pre.in b/Makefile.pre.in
|
||||
index e88f89b91b1..88a48eb5333 100644
|
||||
index 2d067730633..a45a76cce45 100644
|
||||
--- a/Makefile.pre.in
|
||||
+++ b/Makefile.pre.in
|
||||
@@ -2330,7 +2330,6 @@ LIBSUBDIRS= asyncio \
|
||||
@@ -2336,7 +2336,6 @@ LIBSUBDIRS= asyncio \
|
||||
pathlib \
|
||||
re \
|
||||
site-packages \
|
||||
@@ -31,7 +31,7 @@ index e88f89b91b1..88a48eb5333 100644
|
||||
sysconfig \
|
||||
tkinter \
|
||||
tomllib \
|
||||
@@ -2493,6 +2492,10 @@ ifeq (@IDLE@,yes)
|
||||
@@ -2500,6 +2499,10 @@ ifeq (@IDLE@,yes)
|
||||
LIBSUBDIRS += idlelib idlelib/Icons
|
||||
endif
|
||||
|
||||
@@ -43,10 +43,10 @@ index e88f89b91b1..88a48eb5333 100644
|
||||
|
||||
.PHONY: libinstall
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 8d56a24ffcb..b6d5bb3d9c5 100644
|
||||
index 6635aaa134d..8153b738b2f 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -4667,6 +4667,13 @@ AS_VAR_IF([posix_threads], [stub], [
|
||||
@@ -4755,6 +4755,13 @@ AS_VAR_IF([posix_threads], [stub], [
|
||||
AC_DEFINE([HAVE_PTHREAD_STUBS], [1], [Define if platform requires stubbed pthreads support])
|
||||
])
|
||||
|
||||
@@ -61,5 +61,5 @@ index 8d56a24ffcb..b6d5bb3d9c5 100644
|
||||
|
||||
AC_ARG_ENABLE(pydoc,
|
||||
--
|
||||
2.34.1
|
||||
2.50.1
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
From bd14e6f232232c11b67477a5d8f0caf174a089d0 Mon Sep 17 00:00:00 2001
|
||||
From b53a2758ac431bc2493a460e6c886561e2397518 Mon Sep 17 00:00:00 2001
|
||||
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
|
||||
Date: Wed, 22 Feb 2017 17:23:42 -0800
|
||||
Subject: [PATCH] Add an option to disable the tk module
|
||||
@@ -25,10 +25,10 @@ Signed-off-by: Vincent Fazio <vfazio@xes-inc.com>
|
||||
2 files changed, 12 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/Makefile.pre.in b/Makefile.pre.in
|
||||
index 0f394d6ece4..a44307a0fb1 100644
|
||||
index a45a76cce45..76d67ce7185 100644
|
||||
--- a/Makefile.pre.in
|
||||
+++ b/Makefile.pre.in
|
||||
@@ -2331,7 +2331,6 @@ LIBSUBDIRS= asyncio \
|
||||
@@ -2337,7 +2337,6 @@ LIBSUBDIRS= asyncio \
|
||||
re \
|
||||
site-packages \
|
||||
sysconfig \
|
||||
@@ -36,7 +36,7 @@ index 0f394d6ece4..a44307a0fb1 100644
|
||||
tomllib \
|
||||
turtledemo \
|
||||
unittest \
|
||||
@@ -2439,7 +2438,6 @@ TESTSUBDIRS= idlelib/idle_test \
|
||||
@@ -2445,7 +2444,6 @@ TESTSUBDIRS= idlelib/idle_test \
|
||||
test/test_pydoc \
|
||||
test/test_pyrepl \
|
||||
test/test_sqlite3 \
|
||||
@@ -44,7 +44,7 @@ index 0f394d6ece4..a44307a0fb1 100644
|
||||
test/test_tomllib \
|
||||
test/test_tomllib/data \
|
||||
test/test_tomllib/data/invalid \
|
||||
@@ -2461,7 +2459,6 @@ TESTSUBDIRS= idlelib/idle_test \
|
||||
@@ -2467,7 +2465,6 @@ TESTSUBDIRS= idlelib/idle_test \
|
||||
test/test_tools \
|
||||
test/test_tools/i18n_data \
|
||||
test/test_tools/msgfmt_data \
|
||||
@@ -52,7 +52,7 @@ index 0f394d6ece4..a44307a0fb1 100644
|
||||
test/test_unittest \
|
||||
test/test_unittest/testmock \
|
||||
test/test_warnings \
|
||||
@@ -2483,6 +2480,11 @@ TESTSUBDIRS= idlelib/idle_test \
|
||||
@@ -2489,6 +2486,11 @@ TESTSUBDIRS= idlelib/idle_test \
|
||||
test/xmltestdata/c14n-20 \
|
||||
test/zipimport_data
|
||||
|
||||
@@ -65,10 +65,10 @@ index 0f394d6ece4..a44307a0fb1 100644
|
||||
|
||||
ifeq (@PYDOC@,yes)
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index b6d5bb3d9c5..a1a91e094cd 100644
|
||||
index 8153b738b2f..0cf06a50c71 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -4680,6 +4680,13 @@ AC_ARG_ENABLE(pydoc,
|
||||
@@ -4768,6 +4768,13 @@ AC_ARG_ENABLE(pydoc,
|
||||
AS_HELP_STRING([--disable-pydoc], [disable pydoc]),
|
||||
[ PYDOC="${enableval}" ], [ PYDOC=yes ])
|
||||
|
||||
@@ -83,5 +83,5 @@ index b6d5bb3d9c5..a1a91e094cd 100644
|
||||
AH_TEMPLATE([ENABLE_IPV6], [Define if --enable-ipv6 is specified])
|
||||
AC_MSG_CHECKING([if --enable-ipv6 is specified])
|
||||
--
|
||||
2.34.1
|
||||
2.50.1
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
From 7ec209bfb172ba5382c010954057fd32e4f21cf6 Mon Sep 17 00:00:00 2001
|
||||
From baef276faa676d1b0faf64a91fa627b5f8fcc5e0 Mon Sep 17 00:00:00 2001
|
||||
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
|
||||
Date: Wed, 22 Feb 2017 17:31:51 -0800
|
||||
Subject: [PATCH] Add an option to disable the curses module
|
||||
@@ -19,10 +19,10 @@ Signed-off-by: Vincent Fazio <vfazio@gmail.com>
|
||||
2 files changed, 11 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/Makefile.pre.in b/Makefile.pre.in
|
||||
index 6d6631cbe31..a4531d1f0fc 100644
|
||||
index 76d67ce7185..bfb6cb65354 100644
|
||||
--- a/Makefile.pre.in
|
||||
+++ b/Makefile.pre.in
|
||||
@@ -2316,7 +2316,6 @@ LIBSUBDIRS= asyncio \
|
||||
@@ -2322,7 +2322,6 @@ LIBSUBDIRS= asyncio \
|
||||
concurrent concurrent/futures \
|
||||
csv \
|
||||
ctypes ctypes/macholib \
|
||||
@@ -30,7 +30,7 @@ index 6d6631cbe31..a4531d1f0fc 100644
|
||||
dbm \
|
||||
email email/mime \
|
||||
encodings \
|
||||
@@ -2484,6 +2483,10 @@ LIBSUBDIRS += tkinter
|
||||
@@ -2491,6 +2490,10 @@ LIBSUBDIRS += tkinter
|
||||
TESTSUBDIRS += test/test_tkinter test/test_ttk
|
||||
endif
|
||||
|
||||
@@ -42,10 +42,10 @@ index 6d6631cbe31..a4531d1f0fc 100644
|
||||
|
||||
ifeq (@PYDOC@,yes)
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index a1a91e094cd..30ad6f1e68d 100644
|
||||
index 0cf06a50c71..0895dc57808 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -4674,6 +4674,13 @@ AC_ARG_ENABLE(sqlite3,
|
||||
@@ -4762,6 +4762,13 @@ AC_ARG_ENABLE(sqlite3,
|
||||
AS_IF([test "$SQLITE3" = "no"],
|
||||
[PY_STDLIB_MOD_SET_NA([_sqlite3])])
|
||||
|
||||
@@ -60,5 +60,5 @@ index a1a91e094cd..30ad6f1e68d 100644
|
||||
|
||||
AC_ARG_ENABLE(pydoc,
|
||||
--
|
||||
2.34.1
|
||||
2.50.1
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
From fb7d73d6e3c4cdc9cb272120845103b1aa965240 Mon Sep 17 00:00:00 2001
|
||||
From 2a7412e43554830ffbc831454de8df903e765b73 Mon Sep 17 00:00:00 2001
|
||||
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
|
||||
Date: Wed, 22 Feb 2017 17:40:45 -0800
|
||||
Subject: [PATCH] Add an option to disable expat
|
||||
@@ -25,10 +25,10 @@ Signed-off-by: Vincent Fazio <vfazio@gmail.com>
|
||||
2 files changed, 17 insertions(+), 12 deletions(-)
|
||||
|
||||
diff --git a/Makefile.pre.in b/Makefile.pre.in
|
||||
index a4531d1f0fc..f6719bd19b3 100644
|
||||
index bfb6cb65354..7a662ea4b32 100644
|
||||
--- a/Makefile.pre.in
|
||||
+++ b/Makefile.pre.in
|
||||
@@ -2336,7 +2336,6 @@ LIBSUBDIRS= asyncio \
|
||||
@@ -2342,7 +2342,6 @@ LIBSUBDIRS= asyncio \
|
||||
urllib \
|
||||
venv venv/scripts venv/scripts/common venv/scripts/posix \
|
||||
wsgiref \
|
||||
@@ -36,7 +36,7 @@ index a4531d1f0fc..f6719bd19b3 100644
|
||||
xmlrpc \
|
||||
zipfile zipfile/_path \
|
||||
zoneinfo \
|
||||
@@ -2501,6 +2500,10 @@ ifeq (@SQLITE3@,yes)
|
||||
@@ -2508,6 +2507,10 @@ ifeq (@SQLITE3@,yes)
|
||||
LIBSUBDIRS += sqlite3
|
||||
endif
|
||||
|
||||
@@ -48,10 +48,10 @@ index a4531d1f0fc..f6719bd19b3 100644
|
||||
|
||||
.PHONY: libinstall
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 30ad6f1e68d..370eb94730f 100644
|
||||
index 0895dc57808..34e4d5dd244 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -3970,17 +3970,19 @@ LIBS="$withval $LIBS"
|
||||
@@ -4058,17 +4058,19 @@ LIBS="$withval $LIBS"
|
||||
[AC_MSG_RESULT([no])])
|
||||
|
||||
# Check for use of the system expat library
|
||||
@@ -83,5 +83,5 @@ index 30ad6f1e68d..370eb94730f 100644
|
||||
LIBEXPAT_LDFLAGS=${LIBEXPAT_LDFLAGS-"-lexpat"}
|
||||
LIBEXPAT_INTERNAL=
|
||||
--
|
||||
2.34.1
|
||||
2.50.1
|
||||
|
||||
|
||||
@@ -1,221 +0,0 @@
|
||||
From cdae923ffe187d6ef916c0f665a31249619193fe Mon Sep 17 00:00:00 2001
|
||||
From: "Miss Islington (bot)"
|
||||
<31488909+miss-islington@users.noreply.github.com>
|
||||
Date: Mon, 28 Jul 2025 17:59:33 +0200
|
||||
Subject: [PATCH] [3.13] gh-130577: tarfile now validates archives to ensure
|
||||
member offsets are non-negative (GH-137027) (#137170)
|
||||
|
||||
gh-130577: tarfile now validates archives to ensure member offsets are non-negative (GH-137027)
|
||||
(cherry picked from commit 7040aa54f14676938970e10c5f74ea93cd56aa38)
|
||||
|
||||
Upstream: https://github.com/python/cpython/commit/cdae923ffe187d6ef916c0f665a31249619193fe
|
||||
Co-authored-by: Alexander Urieles <aeurielesn@users.noreply.github.com>
|
||||
Co-authored-by: Gregory P. Smith <greg@krypto.org>
|
||||
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
|
||||
---
|
||||
Lib/tarfile.py | 3 +
|
||||
Lib/test/test_tarfile.py | 156 ++++++++++++++++++
|
||||
...-07-23-00-35-29.gh-issue-130577.c7EITy.rst | 3 +
|
||||
3 files changed, 162 insertions(+)
|
||||
create mode 100644 Misc/NEWS.d/next/Library/2025-07-23-00-35-29.gh-issue-130577.c7EITy.rst
|
||||
|
||||
diff --git a/Lib/tarfile.py b/Lib/tarfile.py
|
||||
index 0980f6a8175..9ff9df696de 100755
|
||||
--- a/Lib/tarfile.py
|
||||
+++ b/Lib/tarfile.py
|
||||
@@ -1636,6 +1636,9 @@ def _block(self, count):
|
||||
"""Round up a byte count by BLOCKSIZE and return it,
|
||||
e.g. _block(834) => 1024.
|
||||
"""
|
||||
+ # Only non-negative offsets are allowed
|
||||
+ if count < 0:
|
||||
+ raise InvalidHeaderError("invalid offset")
|
||||
blocks, remainder = divmod(count, BLOCKSIZE)
|
||||
if remainder:
|
||||
blocks += 1
|
||||
diff --git a/Lib/test/test_tarfile.py b/Lib/test/test_tarfile.py
|
||||
index ac31be0f050..7024be46de5 100644
|
||||
--- a/Lib/test/test_tarfile.py
|
||||
+++ b/Lib/test/test_tarfile.py
|
||||
@@ -50,6 +50,7 @@ def sha256sum(data):
|
||||
xzname = os.path.join(TEMPDIR, "testtar.tar.xz")
|
||||
tmpname = os.path.join(TEMPDIR, "tmp.tar")
|
||||
dotlessname = os.path.join(TEMPDIR, "testtar")
|
||||
+SPACE = b" "
|
||||
|
||||
sha256_regtype = (
|
||||
"e09e4bc8b3c9d9177e77256353b36c159f5f040531bbd4b024a8f9b9196c71ce"
|
||||
@@ -4578,6 +4579,161 @@ def extractall(self, ar):
|
||||
ar.extractall(self.testdir, filter='fully_trusted')
|
||||
|
||||
|
||||
+class OffsetValidationTests(unittest.TestCase):
|
||||
+ tarname = tmpname
|
||||
+ invalid_posix_header = (
|
||||
+ # name: 100 bytes
|
||||
+ tarfile.NUL * tarfile.LENGTH_NAME
|
||||
+ # mode, space, null terminator: 8 bytes
|
||||
+ + b"000755" + SPACE + tarfile.NUL
|
||||
+ # uid, space, null terminator: 8 bytes
|
||||
+ + b"000001" + SPACE + tarfile.NUL
|
||||
+ # gid, space, null terminator: 8 bytes
|
||||
+ + b"000001" + SPACE + tarfile.NUL
|
||||
+ # size, space: 12 bytes
|
||||
+ + b"\xff" * 11 + SPACE
|
||||
+ # mtime, space: 12 bytes
|
||||
+ + tarfile.NUL * 11 + SPACE
|
||||
+ # chksum: 8 bytes
|
||||
+ + b"0011407" + tarfile.NUL
|
||||
+ # type: 1 byte
|
||||
+ + tarfile.REGTYPE
|
||||
+ # linkname: 100 bytes
|
||||
+ + tarfile.NUL * tarfile.LENGTH_LINK
|
||||
+ # magic: 6 bytes, version: 2 bytes
|
||||
+ + tarfile.POSIX_MAGIC
|
||||
+ # uname: 32 bytes
|
||||
+ + tarfile.NUL * 32
|
||||
+ # gname: 32 bytes
|
||||
+ + tarfile.NUL * 32
|
||||
+ # devmajor, space, null terminator: 8 bytes
|
||||
+ + tarfile.NUL * 6 + SPACE + tarfile.NUL
|
||||
+ # devminor, space, null terminator: 8 bytes
|
||||
+ + tarfile.NUL * 6 + SPACE + tarfile.NUL
|
||||
+ # prefix: 155 bytes
|
||||
+ + tarfile.NUL * tarfile.LENGTH_PREFIX
|
||||
+ # padding: 12 bytes
|
||||
+ + tarfile.NUL * 12
|
||||
+ )
|
||||
+ invalid_gnu_header = (
|
||||
+ # name: 100 bytes
|
||||
+ tarfile.NUL * tarfile.LENGTH_NAME
|
||||
+ # mode, null terminator: 8 bytes
|
||||
+ + b"0000755" + tarfile.NUL
|
||||
+ # uid, null terminator: 8 bytes
|
||||
+ + b"0000001" + tarfile.NUL
|
||||
+ # gid, space, null terminator: 8 bytes
|
||||
+ + b"0000001" + tarfile.NUL
|
||||
+ # size, space: 12 bytes
|
||||
+ + b"\xff" * 11 + SPACE
|
||||
+ # mtime, space: 12 bytes
|
||||
+ + tarfile.NUL * 11 + SPACE
|
||||
+ # chksum: 8 bytes
|
||||
+ + b"0011327" + tarfile.NUL
|
||||
+ # type: 1 byte
|
||||
+ + tarfile.REGTYPE
|
||||
+ # linkname: 100 bytes
|
||||
+ + tarfile.NUL * tarfile.LENGTH_LINK
|
||||
+ # magic: 8 bytes
|
||||
+ + tarfile.GNU_MAGIC
|
||||
+ # uname: 32 bytes
|
||||
+ + tarfile.NUL * 32
|
||||
+ # gname: 32 bytes
|
||||
+ + tarfile.NUL * 32
|
||||
+ # devmajor, null terminator: 8 bytes
|
||||
+ + tarfile.NUL * 8
|
||||
+ # devminor, null terminator: 8 bytes
|
||||
+ + tarfile.NUL * 8
|
||||
+ # padding: 167 bytes
|
||||
+ + tarfile.NUL * 167
|
||||
+ )
|
||||
+ invalid_v7_header = (
|
||||
+ # name: 100 bytes
|
||||
+ tarfile.NUL * tarfile.LENGTH_NAME
|
||||
+ # mode, space, null terminator: 8 bytes
|
||||
+ + b"000755" + SPACE + tarfile.NUL
|
||||
+ # uid, space, null terminator: 8 bytes
|
||||
+ + b"000001" + SPACE + tarfile.NUL
|
||||
+ # gid, space, null terminator: 8 bytes
|
||||
+ + b"000001" + SPACE + tarfile.NUL
|
||||
+ # size, space: 12 bytes
|
||||
+ + b"\xff" * 11 + SPACE
|
||||
+ # mtime, space: 12 bytes
|
||||
+ + tarfile.NUL * 11 + SPACE
|
||||
+ # chksum: 8 bytes
|
||||
+ + b"0010070" + tarfile.NUL
|
||||
+ # type: 1 byte
|
||||
+ + tarfile.REGTYPE
|
||||
+ # linkname: 100 bytes
|
||||
+ + tarfile.NUL * tarfile.LENGTH_LINK
|
||||
+ # padding: 255 bytes
|
||||
+ + tarfile.NUL * 255
|
||||
+ )
|
||||
+ valid_gnu_header = tarfile.TarInfo("filename").tobuf(tarfile.GNU_FORMAT)
|
||||
+ data_block = b"\xff" * tarfile.BLOCKSIZE
|
||||
+
|
||||
+ def _write_buffer(self, buffer):
|
||||
+ with open(self.tarname, "wb") as f:
|
||||
+ f.write(buffer)
|
||||
+
|
||||
+ def _get_members(self, ignore_zeros=None):
|
||||
+ with open(self.tarname, "rb") as f:
|
||||
+ with tarfile.open(
|
||||
+ mode="r", fileobj=f, ignore_zeros=ignore_zeros
|
||||
+ ) as tar:
|
||||
+ return tar.getmembers()
|
||||
+
|
||||
+ def _assert_raises_read_error_exception(self):
|
||||
+ with self.assertRaisesRegex(
|
||||
+ tarfile.ReadError, "file could not be opened successfully"
|
||||
+ ):
|
||||
+ self._get_members()
|
||||
+
|
||||
+ def test_invalid_offset_header_validations(self):
|
||||
+ for tar_format, invalid_header in (
|
||||
+ ("posix", self.invalid_posix_header),
|
||||
+ ("gnu", self.invalid_gnu_header),
|
||||
+ ("v7", self.invalid_v7_header),
|
||||
+ ):
|
||||
+ with self.subTest(format=tar_format):
|
||||
+ self._write_buffer(invalid_header)
|
||||
+ self._assert_raises_read_error_exception()
|
||||
+
|
||||
+ def test_early_stop_at_invalid_offset_header(self):
|
||||
+ buffer = self.valid_gnu_header + self.invalid_gnu_header + self.valid_gnu_header
|
||||
+ self._write_buffer(buffer)
|
||||
+ members = self._get_members()
|
||||
+ self.assertEqual(len(members), 1)
|
||||
+ self.assertEqual(members[0].name, "filename")
|
||||
+ self.assertEqual(members[0].offset, 0)
|
||||
+
|
||||
+ def test_ignore_invalid_archive(self):
|
||||
+ # 3 invalid headers with their respective data
|
||||
+ buffer = (self.invalid_gnu_header + self.data_block) * 3
|
||||
+ self._write_buffer(buffer)
|
||||
+ members = self._get_members(ignore_zeros=True)
|
||||
+ self.assertEqual(len(members), 0)
|
||||
+
|
||||
+ def test_ignore_invalid_offset_headers(self):
|
||||
+ for first_block, second_block, expected_offset in (
|
||||
+ (
|
||||
+ (self.valid_gnu_header),
|
||||
+ (self.invalid_gnu_header + self.data_block),
|
||||
+ 0,
|
||||
+ ),
|
||||
+ (
|
||||
+ (self.invalid_gnu_header + self.data_block),
|
||||
+ (self.valid_gnu_header),
|
||||
+ 1024,
|
||||
+ ),
|
||||
+ ):
|
||||
+ self._write_buffer(first_block + second_block)
|
||||
+ members = self._get_members(ignore_zeros=True)
|
||||
+ self.assertEqual(len(members), 1)
|
||||
+ self.assertEqual(members[0].name, "filename")
|
||||
+ self.assertEqual(members[0].offset, expected_offset)
|
||||
+
|
||||
+
|
||||
def setUpModule():
|
||||
os_helper.unlink(TEMPDIR)
|
||||
os.makedirs(TEMPDIR)
|
||||
diff --git a/Misc/NEWS.d/next/Library/2025-07-23-00-35-29.gh-issue-130577.c7EITy.rst b/Misc/NEWS.d/next/Library/2025-07-23-00-35-29.gh-issue-130577.c7EITy.rst
|
||||
new file mode 100644
|
||||
index 00000000000..342cabbc865
|
||||
--- /dev/null
|
||||
+++ b/Misc/NEWS.d/next/Library/2025-07-23-00-35-29.gh-issue-130577.c7EITy.rst
|
||||
@@ -0,0 +1,3 @@
|
||||
+:mod:`tarfile` now validates archives to ensure member offsets are
|
||||
+non-negative. (Contributed by Alexander Enrique Urieles Nieto in
|
||||
+:gh:`130577`.)
|
||||
--
|
||||
2.39.5
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
# From https://www.python.org/downloads/release/python-3135/
|
||||
md5 dbaa8833aa736eddbb18a6a6ae0c10fa Python-3.13.5.tar.xz
|
||||
# From https://www.python.org/downloads/release/python-3137/
|
||||
md5 256cdb3bbf45cdce7499e52ba6c36ea3 Python-3.13.7.tar.xz
|
||||
# Locally computed
|
||||
sha256 93e583f243454e6e9e4588ca2c2662206ad961659863277afcdb96801647d640 Python-3.13.5.tar.xz
|
||||
sha256 5462f9099dfd30e238def83c71d91897d8caa5ff6ebc7a50f14d4802cdaaa79a Python-3.13.7.tar.xz
|
||||
sha256 78b12c3a81360b357002334f0e70ea0e92eebf7a9b358805c03c48484945f3bb LICENSE
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
################################################################################
|
||||
|
||||
PYTHON3_VERSION_MAJOR = 3.13
|
||||
PYTHON3_VERSION = $(PYTHON3_VERSION_MAJOR).5
|
||||
PYTHON3_VERSION = $(PYTHON3_VERSION_MAJOR).7
|
||||
PYTHON3_SOURCE = Python-$(PYTHON3_VERSION).tar.xz
|
||||
PYTHON3_SITE = https://python.org/ftp/python/$(PYTHON3_VERSION)
|
||||
PYTHON3_LICENSE = Python-2.0, others
|
||||
@@ -13,9 +13,6 @@ PYTHON3_LICENSE_FILES = LICENSE
|
||||
PYTHON3_CPE_ID_VENDOR = python
|
||||
PYTHON3_CPE_ID_PRODUCT = python
|
||||
|
||||
# 0009-3.13-gh-130577-tarfile-now-validates-archives-to-ens.patch
|
||||
PYTHON3_IGNORE_CVES += CVE-2025-8194
|
||||
|
||||
# This host Python is installed in $(HOST_DIR), as it is needed when
|
||||
# cross-compiling third-party Python modules.
|
||||
|
||||
@@ -192,6 +189,15 @@ else
|
||||
PYTHON3_CONF_ENV += ac_cv_big_endian_double=yes
|
||||
endif
|
||||
|
||||
PYTHON3_CFLAGS = $(TARGET_CFLAGS)
|
||||
|
||||
ifeq ($(BR2_TOOLCHAIN_HAS_GCC_BUG_121567),y)
|
||||
PYTHON3_CFLAGS += -O1
|
||||
endif
|
||||
|
||||
PYTHON3_CONF_ENV += \
|
||||
CFLAGS="$(PYTHON3_CFLAGS)"
|
||||
|
||||
ifeq ($(BR2_PACKAGE_GETTEXT_PROVIDES_LIBINTL),y)
|
||||
PYTHON3_DEPENDENCIES += gettext
|
||||
endif
|
||||
|
||||
@@ -0,0 +1,41 @@
|
||||
From c2337c83c627dd94f9b673361dca6ffafca7f59b Mon Sep 17 00:00:00 2001
|
||||
From: Jonas Kvinge <jonas@jkvinge.net>
|
||||
Date: Sun, 6 Jul 2025 20:21:00 +0200
|
||||
Subject: [PATCH] Fix conflicting types build error
|
||||
|
||||
Upstream: https://github.com/raspberrypi/userland/pull/744
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
interface/vchiq_arm/vchiq_lib.c | 2 +-
|
||||
interface/vmcs_host/vc_vchi_gpuserv.h | 2 +-
|
||||
2 files changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/interface/vchiq_arm/vchiq_lib.c b/interface/vchiq_arm/vchiq_lib.c
|
||||
index 133d5ca..7a2dae5 100755
|
||||
--- a/interface/vchiq_arm/vchiq_lib.c
|
||||
+++ b/interface/vchiq_arm/vchiq_lib.c
|
||||
@@ -537,7 +537,7 @@ vchiq_bulk_receive_handle(VCHIQ_SERVICE_HANDLE_T handle,
|
||||
int size,
|
||||
void *userdata,
|
||||
VCHIQ_BULK_MODE_T mode,
|
||||
- int (*copy_pagelist)())
|
||||
+ int (*copy_pagelist)(char *vcptr, const struct pagelist_struct *pagelist))
|
||||
{
|
||||
VCHIQ_SERVICE_T *service = find_service_by_handle(handle);
|
||||
VCHIQ_QUEUE_BULK_TRANSFER_T args;
|
||||
diff --git a/interface/vmcs_host/vc_vchi_gpuserv.h b/interface/vmcs_host/vc_vchi_gpuserv.h
|
||||
index fc0bfee..ce6cb58 100755
|
||||
--- a/interface/vmcs_host/vc_vchi_gpuserv.h
|
||||
+++ b/interface/vmcs_host/vc_vchi_gpuserv.h
|
||||
@@ -58,7 +58,7 @@ struct sync_job_s {
|
||||
|
||||
struct gpu_callback_s {
|
||||
// callback to call when complete (can be NULL)
|
||||
- void (*func)();
|
||||
+ void (*func)(void*);
|
||||
void *cookie;
|
||||
};
|
||||
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
From cf6d0ac0d31fcc2e64c83b8105b078e792f2d441 Mon Sep 17 00:00:00 2001
|
||||
From: Krawlow <mglarecerca@gmail.com>
|
||||
Date: Wed, 23 Mar 2022 16:46:18 +0100
|
||||
Subject: [PATCH] Fix raspicommonsettings_parse_cmdline
|
||||
|
||||
Fix raspicommonsettings_parse_cmdline's definition to match declaration
|
||||
|
||||
Upstream: c4fd1b8986c6d6d4ae5cd51e65a8bbeb495dfa4e
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
host_applications/linux/apps/raspicam/RaspiCommonSettings.h | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/host_applications/linux/apps/raspicam/RaspiCommonSettings.h b/host_applications/linux/apps/raspicam/RaspiCommonSettings.h
|
||||
index 75b2937..2e9de7d 100644
|
||||
--- a/host_applications/linux/apps/raspicam/RaspiCommonSettings.h
|
||||
+++ b/host_applications/linux/apps/raspicam/RaspiCommonSettings.h
|
||||
@@ -54,6 +54,6 @@ typedef struct
|
||||
void raspicommonsettings_set_defaults(RASPICOMMONSETTINGS_PARAMETERS *);
|
||||
void raspicommonsettings_dump_parameters(RASPICOMMONSETTINGS_PARAMETERS *);
|
||||
void raspicommonsettings_display_help();
|
||||
-int raspicommonsettings_parse_cmdline(RASPICOMMONSETTINGS_PARAMETERS *state, const char *arg1, const char *arg2, void (*app_help)());
|
||||
+int raspicommonsettings_parse_cmdline(RASPICOMMONSETTINGS_PARAMETERS *state, const char *arg1, const char *arg2, void (*app_help)(char*));
|
||||
|
||||
#endif
|
||||
--
|
||||
2.50.1
|
||||
|
||||
+30
-21
@@ -1,20 +1,24 @@
|
||||
sdl: Fix compilation with libX11 >= 1.5.99.902
|
||||
Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
|
||||
|
||||
# HG changeset patch
|
||||
# User Azamat H. Hackimov <azamat.hackimov@gmail.com>
|
||||
# Date 1370184533 -21600
|
||||
# Node ID 91ad7b43317a6387e115ecdf63a49137f47e42c8
|
||||
# Parent f7fd5c3951b9ed922fdf696f7182e71b58a13268
|
||||
Fix compilation with libX11 >= 1.5.99.902.
|
||||
From 41410b72746cfc7ff515aefed62b0b179bf6e8da Mon Sep 17 00:00:00 2001
|
||||
From: "Azamat H. Hackimov" <azamat.hackimov@gmail.com>
|
||||
Date: Sun, 2 Jun 2013 20:48:53 +0600
|
||||
Subject: [PATCH] Fix compilation with libX11 >= 1.5.99.902.
|
||||
|
||||
These changes fixes bug #1769 for SDL 1.2
|
||||
(http://bugzilla.libsdl.org/show_bug.cgi?id=1769).
|
||||
|
||||
diff -r f7fd5c3951b9 -r 91ad7b43317a configure.in
|
||||
--- a/configure.in Wed Apr 17 00:56:53 2013 -0700
|
||||
+++ b/configure.in Sun Jun 02 20:48:53 2013 +0600
|
||||
@@ -1169,6 +1169,17 @@
|
||||
Upstream: 5d79977ec7a6b58afa6e4817035aaaba186f7e9f
|
||||
Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
|
||||
---
|
||||
configure.in | 11 +++++++++++
|
||||
include/SDL_config.h.in | 1 +
|
||||
src/video/x11/SDL_x11sym.h | 4 ++++
|
||||
3 files changed, 16 insertions(+)
|
||||
|
||||
diff --git a/configure.in b/configure.in
|
||||
index 08c8e1e9..89c526d4 100644
|
||||
--- a/configure.in
|
||||
+++ b/configure.in
|
||||
@@ -1127,6 +1127,17 @@ AC_HELP_STRING([--enable-video-x11-xrandr], [enable X11 Xrandr extension for ful
|
||||
if test x$definitely_enable_video_x11_xrandr = xyes; then
|
||||
AC_DEFINE(SDL_VIDEO_DRIVER_X11_XRANDR)
|
||||
fi
|
||||
@@ -32,10 +36,11 @@ diff -r f7fd5c3951b9 -r 91ad7b43317a configure.in
|
||||
fi
|
||||
fi
|
||||
}
|
||||
diff -r f7fd5c3951b9 -r 91ad7b43317a include/SDL_config.h.in
|
||||
--- a/include/SDL_config.h.in Wed Apr 17 00:56:53 2013 -0700
|
||||
+++ b/include/SDL_config.h.in Sun Jun 02 20:48:53 2013 +0600
|
||||
@@ -283,6 +283,7 @@
|
||||
diff --git a/include/SDL_config.h.in b/include/SDL_config.h.in
|
||||
index 8bb1773c..78ca747b 100644
|
||||
--- a/include/SDL_config.h.in
|
||||
+++ b/include/SDL_config.h.in
|
||||
@@ -282,6 +282,7 @@
|
||||
#undef SDL_VIDEO_DRIVER_WINDIB
|
||||
#undef SDL_VIDEO_DRIVER_WSCONS
|
||||
#undef SDL_VIDEO_DRIVER_X11
|
||||
@@ -43,10 +48,11 @@ diff -r f7fd5c3951b9 -r 91ad7b43317a include/SDL_config.h.in
|
||||
#undef SDL_VIDEO_DRIVER_X11_DGAMOUSE
|
||||
#undef SDL_VIDEO_DRIVER_X11_DYNAMIC
|
||||
#undef SDL_VIDEO_DRIVER_X11_DYNAMIC_XEXT
|
||||
diff -r f7fd5c3951b9 -r 91ad7b43317a src/video/x11/SDL_x11sym.h
|
||||
--- a/src/video/x11/SDL_x11sym.h Wed Apr 17 00:56:53 2013 -0700
|
||||
+++ b/src/video/x11/SDL_x11sym.h Sun Jun 02 20:48:53 2013 +0600
|
||||
@@ -165,7 +165,11 @@
|
||||
diff --git a/src/video/x11/SDL_x11sym.h b/src/video/x11/SDL_x11sym.h
|
||||
index 4875b989..bd83f7f5 100644
|
||||
--- a/src/video/x11/SDL_x11sym.h
|
||||
+++ b/src/video/x11/SDL_x11sym.h
|
||||
@@ -165,7 +165,11 @@ SDL_X11_SYM(Bool,XShmQueryExtension,(Display* a),(a),return)
|
||||
*/
|
||||
#ifdef LONG64
|
||||
SDL_X11_MODULE(IO_32BIT)
|
||||
@@ -58,3 +64,6 @@ diff -r f7fd5c3951b9 -r 91ad7b43317a src/video/x11/SDL_x11sym.h
|
||||
SDL_X11_SYM(void,_XRead32,(Display *dpy,register long *data,long len),(dpy,data,len),)
|
||||
#endif
|
||||
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
From d7e00208738a0bc6af302723fe64908ac35b777b Mon Sep 17 00:00:00 2001
|
||||
From c24c08c9aa0f92213793e5ef404f2c387603d7f8 Mon Sep 17 00:00:00 2001
|
||||
From: Ozkan Sezer <sezeroz@gmail.com>
|
||||
Date: Sat, 18 Jun 2022 14:55:00 +0300
|
||||
Subject: [PATCH] SDL_x11yuv.c: fix possible use-after-free
|
||||
|
||||
Fixes: https://github.com/libsdl-org/SDL-1.2/issues/863
|
||||
Upstream: d7e00208738a0bc6af302723fe64908ac35b777b
|
||||
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
|
||||
---
|
||||
src/video/x11/SDL_x11yuv.c | 2 +-
|
||||
@@ -24,5 +25,5 @@ index 62698dfd..0d5754e3 100644
|
||||
0, width, height);
|
||||
}
|
||||
--
|
||||
2.30.2
|
||||
2.50.1
|
||||
|
||||
|
||||
@@ -0,0 +1,66 @@
|
||||
From 6fb5aadafc9d99c25fb4f1a37d225d5b79bc92e9 Mon Sep 17 00:00:00 2001
|
||||
From: orbea <orbea@riseup.net>
|
||||
Date: Sat, 15 Oct 2022 15:10:48 -0700
|
||||
Subject: [PATCH] Xext: Fix function declarations without a prototype
|
||||
|
||||
This is not supported with the upcoming clang 16.
|
||||
|
||||
error: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C2x, conflicting with a subsequent definition [-Werror,-Wdeprecated-non-prototype]
|
||||
|
||||
reference: https://archives.gentoo.org/gentoo-dev/message/dd9f2d3082b8b6f8dfbccb0639e6e240
|
||||
|
||||
Upstream: e738cfffced8a006094d55337d917386582ada47
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
|
||||
---
|
||||
src/video/Xext/XME/xme.c | 2 +-
|
||||
src/video/Xext/Xinerama/Xinerama.c | 3 ++-
|
||||
src/video/Xext/Xv/Xv.c | 6 +++---
|
||||
3 files changed, 6 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/src/video/Xext/XME/xme.c b/src/video/Xext/XME/xme.c
|
||||
index 2cead35a..bb8d04d4 100644
|
||||
--- a/src/video/Xext/XME/xme.c
|
||||
+++ b/src/video/Xext/XME/xme.c
|
||||
@@ -206,7 +206,7 @@ static char *xigmisc_extension_name = XIGMISC_PROTOCOL_NAME;
|
||||
/*
|
||||
* find_display - locate the display info block
|
||||
*/
|
||||
-static int XiGMiscCloseDisplay();
|
||||
+static int XiGMiscCloseDisplay(Display*, XExtCodes*);
|
||||
|
||||
static XExtensionHooks xigmisc_extension_hooks = {
|
||||
NULL, /* create_gc */
|
||||
diff --git a/src/video/Xext/Xinerama/Xinerama.c b/src/video/Xext/Xinerama/Xinerama.c
|
||||
index 4ff42ebf..57f64b9c 100644
|
||||
--- a/src/video/Xext/Xinerama/Xinerama.c
|
||||
+++ b/src/video/Xext/Xinerama/Xinerama.c
|
||||
@@ -50,7 +50,8 @@ static /* const */ char *panoramiX_extension_name = PANORAMIX_PROTOCOL_NAME;
|
||||
#define PanoramiXSimpleCheckExtension(dpy,i) \
|
||||
XextSimpleCheckExtension (dpy, i, panoramiX_extension_name)
|
||||
|
||||
-static int close_display();
|
||||
+static int close_display(Display*, XExtCodes*);
|
||||
+
|
||||
static /* const */ XExtensionHooks panoramiX_extension_hooks = {
|
||||
NULL, /* create_gc */
|
||||
NULL, /* copy_gc */
|
||||
diff --git a/src/video/Xext/Xv/Xv.c b/src/video/Xext/Xv/Xv.c
|
||||
index 7147b9e8..c254a1dc 100644
|
||||
--- a/src/video/Xext/Xv/Xv.c
|
||||
+++ b/src/video/Xext/Xv/Xv.c
|
||||
@@ -63,9 +63,9 @@ static char *xv_extension_name = XvName;
|
||||
#define XvCheckExtension(dpy, i, val) \
|
||||
XextCheckExtension(dpy, i, xv_extension_name, val)
|
||||
|
||||
-static char *xv_error_string();
|
||||
-static int xv_close_display();
|
||||
-static Bool xv_wire_to_event();
|
||||
+static char *xv_error_string(Display*, int, XExtCodes*, char*, int);
|
||||
+static int xv_close_display(Display*, XExtCodes*);
|
||||
+static Bool xv_wire_to_event(Display*, XEvent*, xEvent*);
|
||||
|
||||
static XExtensionHooks xv_extension_hooks = {
|
||||
NULL, /* create_gc */
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Locally computed
|
||||
sha256 0056537cb57190aa41c12ba6c2ad04ce10e7f714cde4c1fe7193a37e1c44db46 vim-9.1.0145.tar.gz
|
||||
sha256 4fe4cb284007e26255267338dde1ceac6f8326f78123ae8c96a36ee15a1ea7ba vim-9.1.1684.tar.gz
|
||||
sha256 0b3f1f330cb1b179bb17c7c687d4cec601e0aa3462bc7f890ad4c3888d37d720 LICENSE
|
||||
sha256 7a2f621c8496396dae5eecdcc4dccff9d534dff4627193d3ebf7fa6d2cb27042 README.txt
|
||||
sha256 ee1d0885bbc4a95a24e49873a075391bdf26b69d13758e30f3d9271f8f42bd2d README.txt
|
||||
|
||||
+2
-1
@@ -4,7 +4,7 @@
|
||||
#
|
||||
################################################################################
|
||||
|
||||
VIM_VERSION = 9.1.0145
|
||||
VIM_VERSION = 9.1.1684
|
||||
VIM_SITE = $(call github,vim,vim,v$(VIM_VERSION))
|
||||
VIM_DEPENDENCIES = ncurses $(TARGET_NLS_DEPENDENCIES)
|
||||
VIM_SUBDIR = src
|
||||
@@ -49,6 +49,7 @@ endif
|
||||
define VIM_INSTALL_TARGET_CMDS
|
||||
cd $(@D)/src; \
|
||||
$(TARGET_MAKE_ENV) $(MAKE) DESTDIR=$(TARGET_DIR) installvimbin; \
|
||||
$(TARGET_MAKE_ENV) $(MAKE) DESTDIR=$(TARGET_DIR) installpack; \
|
||||
$(TARGET_MAKE_ENV) $(MAKE) DESTDIR=$(TARGET_DIR) installtools; \
|
||||
$(TARGET_MAKE_ENV) $(MAKE) DESTDIR=$(TARGET_DIR) installlinks
|
||||
endef
|
||||
|
||||
@@ -23,5 +23,17 @@ define WAYLAND_TARGET_CLEANUP
|
||||
endef
|
||||
WAYLAND_POST_INSTALL_TARGET_HOOKS += WAYLAND_TARGET_CLEANUP
|
||||
|
||||
# The wayland-scanner.pc installed by the target wayland package is
|
||||
# used to find the wayland-scanner tool, which in a cross-compilation
|
||||
# context is compiled for the host (and in Buildroot, compiled by
|
||||
# host-wayland). Below, we tweak the target wayland-scanner.pc so that
|
||||
# when the wayland_scanner variable is requested through pkg-config,
|
||||
# it points to the host wayland_scanner tool.
|
||||
define WAYLAND_TWEAK_WAYLAND_SCANNER_PATH
|
||||
$(SED) 's%^wayland_scanner=.*%wayland_scanner=$(HOST_DIR)/bin/wayland-scanner%' \
|
||||
$(STAGING_DIR)/usr/lib/pkgconfig/wayland-scanner.pc
|
||||
endef
|
||||
WAYLAND_POST_INSTALL_TARGET_HOOKS += WAYLAND_TWEAK_WAYLAND_SCANNER_PATH
|
||||
|
||||
$(eval $(meson-package))
|
||||
$(eval $(host-meson-package))
|
||||
|
||||
@@ -15,7 +15,6 @@ config BR2_PACKAGE_WESTON
|
||||
select BR2_PACKAGE_CAIRO
|
||||
select BR2_PACKAGE_CAIRO_PNG
|
||||
select BR2_PACKAGE_LIBPNG
|
||||
select BR2_PACKAGE_JPEG
|
||||
select BR2_PACKAGE_LIBINPUT
|
||||
select BR2_PACKAGE_LIBDISPLAY_INFO
|
||||
select BR2_PACKAGE_LIBDRM
|
||||
|
||||
@@ -36,7 +36,8 @@ WESTON_SIMPLE_CLIENTS += dmabuf-v4l
|
||||
endif
|
||||
endif # BR2_PACKAGE_WESTON_SIMPLE_CLIENTS
|
||||
|
||||
ifeq ($(BR2_PACKAGE_JPEG),y)
|
||||
# weston uses jpeg_read_icc_profile(), only provided by jpeg-turbo
|
||||
ifeq ($(BR2_PACKAGE_JPEG_TURBO),y)
|
||||
WESTON_CONF_OPTS += -Dimage-jpeg=true
|
||||
WESTON_DEPENDENCIES += jpeg
|
||||
else
|
||||
|
||||
@@ -41,6 +41,7 @@ config BR2_PACKAGE_WPEWEBKIT
|
||||
depends on BR2_PACKAGE_HAS_LIBGLES # libepoxy
|
||||
depends on BR2_PACKAGE_HAS_LIBEGL # libepoxy
|
||||
depends on BR2_PACKAGE_WPEWEBKIT_ARCH_SUPPORTS
|
||||
select BR2_HOST_CMAKE_AT_LEAST_3_20
|
||||
select BR2_PACKAGE_CAIRO if BR2_ENDIAN = "BIG"
|
||||
select BR2_PACKAGE_CAIRO_PNG if BR2_ENDIAN = "BIG"
|
||||
select BR2_PACKAGE_HARFBUZZ
|
||||
|
||||
@@ -0,0 +1,40 @@
|
||||
From 53a53af30ce1704b7de806a51d822472fbcc57de Mon Sep 17 00:00:00 2001
|
||||
From: Romain Naour <romain.naour@smile.fr>
|
||||
Date: Sun, 24 Aug 2025 18:26:52 +0200
|
||||
Subject: [PATCH] Makefile: Use '-std=gnu11' to fix build with GCC 15
|
||||
|
||||
GCC 15 changed the default C standard version to C23 [1], resulting in
|
||||
errors from the xvisor definitions of bool from core/include/vmm_types.h,
|
||||
which is a reserved keyword under C23.
|
||||
|
||||
Since CFLAGS are hardcoded in the main Makefile, add '-std=gnu11' to
|
||||
'cflags' to resolve the error.
|
||||
|
||||
[1] https://gcc.gnu.org/gcc-15/porting_to.html
|
||||
|
||||
Upstream: https://github.com/xvisor/xvisor/pull/200
|
||||
|
||||
Fixes:
|
||||
https://gitlab.com/buildroot.org/buildroot/-/jobs/11042295047
|
||||
|
||||
Signed-off-by: Romain Naour <romain.naour@smile.fr>
|
||||
---
|
||||
Makefile | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/Makefile b/Makefile
|
||||
index 1984408c..8731ece0 100644
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -166,7 +166,7 @@ cppflags+=-I$(libs_dir)/include
|
||||
cppflags+=$(cpu-cppflags)
|
||||
cppflags+=$(board-cppflags)
|
||||
cppflags+=$(libs-cppflags-y)
|
||||
-cflags=-g -Wall -nostdlib --sysroot=$(drivers_dir)/include -fno-builtin -fno-stack-protector -D__VMM__
|
||||
+cflags=-std=gnu11 -g -Wall -nostdlib --sysroot=$(drivers_dir)/include -fno-builtin -fno-stack-protector -D__VMM__
|
||||
cflags+=$(board-cflags)
|
||||
cflags+=$(cpu-cflags)
|
||||
cflags+=$(libs-cflags-y)
|
||||
--
|
||||
2.50.1
|
||||
|
||||
@@ -170,7 +170,7 @@ class CVE:
|
||||
|
||||
def each_cpe(self):
|
||||
for nodes in self.nvd_cve.get('configurations', []):
|
||||
for node in nodes['nodes']:
|
||||
for node in nodes.get('nodes', []):
|
||||
for cpe in self.parse_node(node):
|
||||
yield cpe
|
||||
|
||||
|
||||
@@ -37,7 +37,6 @@ class BRConfigTest(unittest.TestCase):
|
||||
super(BRConfigTest, self).__init__(names)
|
||||
self.testname = self.__class__.__name__
|
||||
self.builddir = self.outputdir and os.path.join(self.outputdir, self.testname)
|
||||
self.config += '\nBR2_BACKUP_SITE=""\n'
|
||||
self.config += '\nBR2_DL_DIR="{}"\n'.format(self.downloaddir)
|
||||
self.config += "\nBR2_JLEVEL={}\n".format(self.jlevel)
|
||||
|
||||
|
||||
@@ -7,7 +7,10 @@ import infra
|
||||
|
||||
|
||||
class GitTestBase(infra.basetest.BRConfigTest):
|
||||
config = ""
|
||||
config = \
|
||||
"""
|
||||
BR2_BACKUP_SITE=""
|
||||
"""
|
||||
gitremotedir = infra.filepath("tests/download/git-remote")
|
||||
gitremote = None
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user