Hi,
all patches I consider suitable for upstream right now have been posted here
now. With all of them applied you still don't get useful elfutils on windows,
as for example the date preservation in some of the tools doesn't work. I have
more patches that just blatantly drop functionality I don
The tree functions are more widely available.
Signed-off-by: Ulf Hermann
---
src/ChangeLog | 4
src/ar.c | 77 ++-
2 files changed, 48 insertions(+), 33 deletions(-)
diff --git a/src/ChangeLog b/src/ChangeLog
index 332b07c..32cd
On windows we cannot rename or unlink open files.
(strip.c was missing)
Signed-off-by: Ulf Hermann
---
libasm/ChangeLog | 4
libasm/asm_end.c | 15 +++
src/ChangeLog| 4
src/strip.c | 5 -
tests/ChangeLog | 9 +
tests/newfile.c | 7 +--
test
elf.h does include features.h which should define those. However, on
windows there is no features.h. We have the empty features.h in libgnu
that depends on config.h being included before (which we can't), and the
features.h in lib that is only available when installed in selfcontained
mode. Therefo
Hey all,
I noticed that elfutils fails to handle clang binaries when we want to find a
DIE for a certain address. I.e. dwfl_module_addrdie returns nullptr, and eu-
addr2line fails to resolve inlined frames.
To reproduce this:
~~~
$ cat test.cpp
#include
#include
#include
using name
strip explicitly creates the new files. This will not work on windows if
the files already exist.
Signed-off-by: Ulf Hermann
---
tests/ChangeLog | 5 +
tests/run-strip-reloc.sh | 2 ++
2 files changed, 7 insertions(+)
diff --git a/tests/ChangeLog b/tests/ChangeLog
index f43aeba..1a
error() will only output the file name, but with ".exe" on windows.
Signed-off-by: Ulf Hermann
---
tests/ChangeLog | 6 ++
tests/run-stack-d-test.sh | 5 +
tests/run-stack-demangled-test.sh | 5 +
tests/run-stack-i-test.sh | 5 +
4 files changed,
The permission macros are not guaranteed to be defined and the octal
numbers are rather well known.
Signed-off-by: Ulf Hermann
---
src/ChangeLog | 7 +++
src/ar.c| 8
src/elfcompress.c | 4 ++--
src/ranlib.c| 2 +-
src/strip.c | 2 +-
tests/Change
/dev/zero is meant for reading zeroes. /dev/null is for writing into
nirvana.
Signed-off-by: Ulf Hermann
---
tests/ChangeLog | 4
tests/elfshphehdr.c | 2 +-
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/tests/ChangeLog b/tests/ChangeLog
index b8de138..fef6f55 100644
---
On windows x86_64 pid_t is 64bit wide. We ignore the extra bits as those
messages are only informational anyway.
Signed-off-by: Ulf Hermann
---
src/ChangeLog | 4
src/stack.c | 20 ++--
2 files changed, 14 insertions(+), 10 deletions(-)
diff --git a/src/ChangeLog b/src/C
On windows x86_64 we need more stack in some places.
Signed-off-by: Ulf Hermann
---
config/ChangeLog | 4
config/eu.am | 4 ++--
2 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/config/ChangeLog b/config/ChangeLog
index 0f240ea..642d765 100644
--- a/config/ChangeLog
+++ b/
We need to export open(), close(), malloc(), and free() from the C
library we are using so that we can handle resources passed to and from
elfutils correctly. For example, on Windows, calling free() on memory
malloc()'d with a different C library will not work. In addition, having
__cxa_demangle fr
$ORIGIN and $LIB are not supported by all implementations of dlopen() and
on windows we need backslashes as directory separators.
Signed-off-by: Ulf Hermann
---
libebl/ChangeLog| 5 +
libebl/eblopenbackend.c | 4
2 files changed, 9 insertions(+)
diff --git a/libebl/ChangeLog b/
The mechanism of moving argp_program_version_hook and
argp_program_bug_address to .rodata is not portable and two pointers
per program are not worth the effort to make it portable. Revert the
pointers to be non-const.
Signed-off-by: Ulf Hermann
---
lib/ChangeLog | 5 +
lib/printversion
On windows we cannot rename or unlink open files.
Signed-off-by: Ulf Hermann
---
libasm/ChangeLog | 4
libasm/asm_end.c | 15 +++
tests/ChangeLog | 9 +
tests/newfile.c | 7 +--
tests/newscn.c | 3 ++-
tests/update1.c | 1 +
tests/update2.c | 1 +
tests/u
On windows the resulting ino and dev entries are always 0, so the file
would always be discarded. We apply a heuristic instead: If the ctime,
mtime, mode and size of the two files are all equal then we consider
them to be the same. It's exceedingly unlikely to produce two different
files for which
In general we need to use ';' as path separator and '\' and directory
separator on windows. The shell will automatically translate paths to
some extent, but we have to call "pwd -W" rather than plain "pwd" to
get something useful.
Signed-off-by: Ulf Hermann
---
lib/ChangeLog
This accounts for the CR/LF problem we get when producing text files on
windows.
Signed-off-by: Ulf Hermann
---
tests/ChangeLog | 7 +++
tests/run-addr2line-test.sh | 8
tests/run-readelf-test1.sh | 2 +-
tests/run-unstrip-n.sh | 2 +-
tests/test-subr.sh |
If O_BINARY is not defined, define it to 0, so that the change has no
effect then. Some systems have separate binary and text modes for files,
and we don't want the text mode to be used.
Change-Id: If7efb5bd448c2a1c7d1eb5dab276849b1b15a3ce
Signed-off-by: Ulf Hermann
---
lib/ChangeLog
Signed-off-by: Ulf Hermann
---
ChangeLog | 4
configure.ac| 1 +
tests/ChangeLog | 4
tests/deleted.c | 14 ++
4 files changed, 23 insertions(+)
diff --git a/ChangeLog b/ChangeLog
index 662c633..2cf7bd6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
20
fprintf() and exit() do the same job and are portable.
Signed-off-by: Ulf Hermann
---
tests/ChangeLog | 6 ++
tests/allfcts.c | 46 +++---
tests/buildid.c | 6 +++---
tests/debugaltlink.c | 6 +++---
4 files changed, 43 insertions(+),
We cannot get GNU strerror_r from gnulib.
If we don't have it, we don't translate system error codes to strings in
dwfl_error.c.
(rebased on top of all the other patches)
Signed-off-by: Ulf Hermann
---
ChangeLog| 4
configure.ac | 2 ++
libdwfl/ChangeLog| 5 +
If fchmod or fchown are unavailable, then the file permission model is
likely to be different from what we expect there. posix_fallocate is a
frather fragile affair already on linux, and not guaranteed to do
anything useful. If it's not available, the result will be the same as
when it's available
Change-Id: I6ea7c1f894e89bbaaecb724473c4c00e67296f05
Signed-off-by: Ulf Hermann
---
src/ChangeLog | 4
src/strings.c | 3 +++
2 files changed, 7 insertions(+)
diff --git a/src/ChangeLog b/src/ChangeLog
index 64db1ca..4a32604 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,7 @@
+20
tdestroy is not necessarily available from search.h, but we need it.
gnulib cannot help us here as it will detect search.h to be available
and functional in that case. However, some search.h expose a node_t
struct which can be used to implement tdestroy. If that is the case, add
an implementation t
If it doesn't exist, add an implementation to libgnu.a and config.h.
Signed-off-by: Ulf Hermann
---
ChangeLog | 4
configure.ac | 16 +++
libgnu/ChangeLog | 6 ++
libgnu/Makefile.am| 6 +-
libgnu/basename-gnu.c | 54 ++
The locked IO functions will still do the job, albeit a bit slower.
Signed-off-by: Ulf Hermann
---
ChangeLog | 4
configure.ac| 4
lib/ChangeLog | 5 +
lib/eu-config.h | 28
4 files changed, 41 insertions(+)
diff --git a/ChangeLog b/Chan
For some reason gnulib calls the headers fts_.h. We need to wrap it into
an actual fts.h to make it available.
Signed-off-by: Ulf Hermann
---
ChangeLog | 4
configure.ac | 18 +++---
libgnu/ChangeLog | 5 +
libgnu/Makefile.am | 9 -
libgnu/fts.in.
On 05/02/2017 01:55 PM, Ulf Hermann wrote:
>> Maybe we can cleanup that last
>> one once we integrate gnulib (which I believe has a good/64-off_t fts.h
>> already).
>
> gnulib is among the bad ones. Or, at least we detect it as bad.
Sorry, I meant the msys fts.h. That is also the one which needs
__fsetlocking is a nice optimization, but if it's unavailable, we can do
without.
Signed-off-by: Ulf Hermann
---
ChangeLog | 4
configure.ac | 3 +++
libgnu/ChangeLog | 5 +
libgnu/Makefile.am| 9 -
libgnu/stdio_ext.in.h | 35 +++
gnulib #defines all the types we need from it in config.h, so it is empty.
We still need it because other files #include it. We use this for building
elfutils itself. The other features.h in lib gets installed in selfcontained
mode for other projects that include elfutils headers in a different
env
With MSVC there is no features.h, uid_t, gid_t, mode_t, and pid_t are
not defined and there is also no elf.h. To make it possible to build
other software against libelf and libdw, install our own version of
elf.h, and a bare-bones features.h that provides exactly the above
declarations. The feature
Signed-off-by: Ulf Hermann
---
ChangeLog | 4
configure.ac | 3 +++
libgnu/ChangeLog | 5 +
libgnu/Makefile.am | 9 -
libgnu/ar.in.h | 59 ++
5 files changed, 79 insertions(+), 1 deletion(-)
create mode
We cannot get sysconf() from gnulib and the only thing we need it for
is getting the page size. Therefore, of the various possible sysconf
parameters we only define and implement _SC_PAGESIZE in our replacement.
Signed-off-by: Ulf Hermann
---
ChangeLog | 6 ++
configure.ac
We cannot get mmap() and friends from gnulib and they don't exist on windows.
The functionality we need can be implemnted using native win32 functions,
though.
(changelog entries were missing in V1)
Signed-off-by: Ulf Hermann
---
ChangeLog | 4 ++
configure.ac| 7
We cannot get mmap() and friends from gnulib and they don't exist on windows.
The functionality we need can be implemnted using native win32 functions,
though.
Signed-off-by: Ulf Hermann
---
configure.ac| 7 +++
libgnu/Makefile.am | 17 +-
libgnu/mman_win32.c | 140 +
36 matches
Mail list logo