* [COMMITTED] config: Sync largefile.m4 from binutils-gdb
@ 2020-09-08 9:22 Rainer Orth
2020-09-21 8:04 ` Martin Liška
0 siblings, 1 reply; 2+ messages in thread
From: Rainer Orth @ 2020-09-08 9:22 UTC (permalink / raw)
To: gcc-patches
[-- Attachment #1: Type: text/plain, Size: 1761 bytes --]
The following patch improves handling of largefile support with procfs
on 32-bit Solaris. It has already been approved and installed for
binutils-gdb in the thread starting at
[PATCH] Unify Solaris procfs and largefile handling
https://sourceware.org/pipermail/gdb-patches/2020-June/169977.html
I'm syncing the config/largefile.m4 part to gcc now which is the master
for config. Since ACX_LARGEFILE isn't used anywhere in the gcc tree,
I'm installing it as obvious.
[Or rather: I meant to and failed:
remote: *** ChangeLog format failed:
remote: ERR: first line should start with a tab, an asterisk and a space:" Sync from binutils-gdb."
remote: ERR: additional author must be indented with one tab and four spaces:" 2020-07-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>"
remote: ERR: first line should start with a tab, an asterisk and a space:" 2020-07-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>"
remote:
remote: Please see: https://gcc.gnu.org/codingconventions.html#ChangeLogs
remote:
abort: git remote error: refs/heads/master failed to update
How am I supposed to install a ChangeLog entry like the one below? The
format is analogous to the one used for backports. Martin?]
Rainer
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University
2020-09-08 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
config:
Sync from binutils-gdb.
2020-07-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
* largefile.m4 (ACX_LARGEFILE) <sparc-*-solaris*|i?86-*-solaris*>:
Check for <sys/procfs.h> incompatilibity with large-file support
on Solaris.
Only disable large-file support and perhaps plugins if needed.
Set, substitute LARGEFILE_CPPFLAGS if so.
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: config-largefile-sync.patch --]
[-- Type: text/x-patch, Size: 2703 bytes --]
# HG changeset patch
# Parent 9631429b03ab5d025fee1443d88e46caa38dbd23
config: Sync largefile.m4 from binutils-gdb
diff --git a/config/largefile.m4 b/config/largefile.m4
--- a/config/largefile.m4
+++ b/config/largefile.m4
@@ -1,5 +1,5 @@
# This macro wraps AC_SYS_LARGEFILE with one exception for Solaris.
-# PR 9992/binutils: We have to replicate everywhere the behaviour of
+# PR binutils/9992: We have to replicate everywhere the behaviour of
# bfd's configure script so that all the directories agree on the size
# of structures used to describe files.
@@ -16,17 +16,38 @@ AC_REQUIRE([AC_CANONICAL_TARGET])
AC_PLUGINS
case "${host}" in
-changequote(,)dnl
- sparc-*-solaris*|i[3-7]86-*-solaris*)
-changequote([,])dnl
- # On native 32bit sparc and ia32 solaris, large-file and procfs support
- # are mutually exclusive; and without procfs support, the bfd/ elf module
- # cannot provide certain routines such as elfcore_write_prpsinfo
- # or elfcore_write_prstatus. So unless the user explicitly requested
- # large-file support through the --enable-largefile switch, disable
- # large-file support in favor of procfs support.
- test "${target}" = "${host}" -a "x$plugins" = xno \
- && : ${enable_largefile="no"}
+ sparc-*-solaris*|i?86-*-solaris*)
+ # On native 32-bit Solaris/SPARC and x86, large-file and procfs support
+ # were mutually exclusive until Solaris 11.3. Without procfs support,
+ # the bfd/ elf module cannot provide certain routines such as
+ # elfcore_write_prpsinfo or elfcore_write_prstatus. So unless the user
+ # explicitly requested large-file support through the
+ # --enable-largefile switch, disable large-file support in favor of
+ # procfs support.
+ #
+ # Check if <sys/procfs.h> is incompatible with large-file support.
+ AC_TRY_COMPILE([#define _FILE_OFFSET_BITS 64
+#define _STRUCTURED_PROC 1
+#include <sys/procfs.h>], , acx_cv_procfs_lfs=yes, acx_cv_procfs_lfs=no)
+ #
+ # Forcefully disable large-file support only if necessary, gdb is in
+ # tree and enabled.
+ if test "${target}" = "${host}" -a "$acx_cv_procfs_lfs" = no \
+ -a -d $srcdir/../gdb -a "$enable_gdb" != no; then
+ : ${enable_largefile="no"}
+ if test "$plugins" = yes; then
+ AC_MSG_WARN([
+plugin support disabled; require large-file support which is incompatible with GDB.])
+ plugins=no
+ fi
+ fi
+ #
+ # Explicitly undef _FILE_OFFSET_BITS if enable_largefile=no for the
+ # benefit of g++ 9+ which predefines it on Solaris.
+ if test "$enable_largefile" = no; then
+ LARGEFILE_CPPFLAGS="-U_FILE_OFFSET_BITS"
+ AC_SUBST(LARGEFILE_CPPFLAGS)
+ fi
;;
esac
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [COMMITTED] config: Sync largefile.m4 from binutils-gdb
2020-09-08 9:22 [COMMITTED] config: Sync largefile.m4 from binutils-gdb Rainer Orth
@ 2020-09-21 8:04 ` Martin Liška
0 siblings, 0 replies; 2+ messages in thread
From: Martin Liška @ 2020-09-21 8:04 UTC (permalink / raw)
To: Rainer Orth, gcc-patches
On 9/8/20 11:22 AM, Rainer Orth wrote:
> How am I supposed to install a ChangeLog entry like the one below? The
> format is analogous to the one used for backports. Martin?]
Hello.
Currently we do not allow a changelog entry that prepends file changes.
You can put the:
'''
Sync from binutils-gdb.
2020-07-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
'''
just to the commit message.
Martin
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-09-21 8:04 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-08 9:22 [COMMITTED] config: Sync largefile.m4 from binutils-gdb Rainer Orth
2020-09-21 8:04 ` Martin Liška
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).