Re: [Mingw-w64-public] Is there a libbacktrace library for mingw-64/gcc

2017-05-28 Thread LRN
On 5/28/2017 9:53 PM, Edward Diener wrote:
> On 5/28/2017 10:15 AM, niXman wrote:
>> Edward Diener 2017-05-28 16:32:
>>> As of September 2016, libbacktrace only supports ELF and PE/COFF 
>>> executables with DWARF debugging information.
> 
> That does not seem very limiting. ELF and PE/COFF covers all popular 
> object file formats on Linux and Windows respectively and surely just 
> about everyone not using VC++ uses DWARF rather than sjlj.
> 

I think there's some confusion here. ILT means DWARF /debug/ info[1] (the other
kind of debug info supported by GCC is STABS (there's also COFF, VMS and
variations, not our concern though); gcc uses DWARF by default, gdb understands
both), not DWARF (DW2) exception handling (where the other exception handling
mechanism is SJLJ, for 32-bit programs, and 64-bit programs have their own,
64-bit-specific exception handling).

[1] https://gcc.gnu.org/onlinedocs/gcc/Debugging-Options.html

-- 
O< ascii ribbon - stop html email! - www.asciiribbon.org


signature.asc
Description: OpenPGP digital signature
--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public


Re: [Mingw-w64-public] Is there a libbacktrace library for mingw-64/gcc

2017-05-28 Thread LRN
On 5/28/2017 9:53 PM, Edward Diener wrote:
> On 5/28/2017 10:15 AM, niXman wrote:
>> Edward Diener 2017-05-28 16:32:
>>
>>
>> [1] https://github.com/ianlancetaylor/libbacktrace
> 
> Thanks for the link.
> 
> How would I build this above-linked libbacktrace in mingw-64 for myself 
> ? Am I supposed to use the current mingw-64 build script to do so and 
> just copy the aforementioned 3 files to some final directories ?

* git clone https://github.com/ianlancetaylor/libbacktrace.git
* cd libbacktrace
* libtoolize -fi
* autoreconf -fi
* ./configure --prefix= --build=
--enable-host-shared
* make LDFLAGS="-no-undefined"
* make install DESTDIR=

The conventional prefix usually looks like "/mingw" or something like that. Do
"ls /" look for a similarly-named directory.
The build triplet is usually either i686-w64-mingw32 or x86_64-w64-mingw32,
depending on whether the program you're building is 32-bit or 64-bit.

Obviously, this is just a manual build routine, normally someone should can it
and then use buildscripts to build the package.

-- 
O< ascii ribbon - stop html email! - www.asciiribbon.org


signature.asc
Description: OpenPGP digital signature
--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public


Re: [Mingw-w64-public] Is there a libbacktrace library for mingw-64/gcc

2017-05-28 Thread Edward Diener

On 5/28/2017 5:06 PM, niXman wrote:

Edward Diener 2017-05-28 21:53:


That does not seem very limiting. ELF and PE/COFF covers all popular
object file formats on Linux and Windows respectively and surely just
about everyone not using VC++ uses DWARF rather than sjlj.


As I know, for windows targets DWARF is available only for 32bit 
targets.(But I can be wrong...)




How would I build this above-linked libbacktrace in mingw-64 for
myself ? Am I supposed to use the current mingw-64 build script to do
so and just copy the aforementioned 3 files to some final directories
?


1) clone mingw-builds scripts into your home dir.
2) cd mingw-builds
3) switch to develop branch
4) ./build --mode=gcc-7.1.0 --bootstrap --buildroot=/c/mingw710 
--threads=posix --exceptions=dwarf --arch=i686 --bin-compress --jobs=2 
--rev=0 --rt-version=v5


Following instructions I eventually get under MSYS2:

-> libiconv
--> download libiconv-1.14.tar.gz... done
--> unpack libiconv-1.14.tar.gz... done
--> patching...
Not found level for patch 
libiconv/0001-compile-relocatable-in-gnulib.mingw.patch, error=2


If the building of mingw-w64 in your environment is successful, I will 
tell you which files and where to copy to.







--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public


Re: [Mingw-w64-public] Is there a libbacktrace library for mingw-64/gcc

2017-05-28 Thread niXman

niXman 2017-05-29 00:06:


1) clone mingw-builds scripts into your home dir.

*using MSYS2 (sf.net/p/msys2)

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public


Re: [Mingw-w64-public] Is there a libbacktrace library for mingw-64/gcc

2017-05-28 Thread Edward Diener

On 5/28/2017 10:15 AM, niXman wrote:

Edward Diener 2017-05-28 16:32:


2) libbacktrace can be part of a mingw-64 distribution but relies on
other files in that distribution ?

Yes.


Great !




I see in [2] below that there was a discussion of making libbacktrace
standalone, but it appears that in the 4 years from that discussion
that it was never followed through.


I can make the libbacktrace part of the mingw-w64 distribution. In order 
to do this I should copy the three files(libbacktrace.a, backtrace.h, 
gstdint.h) from the GCC build tree.


If libbacktrace were part of mingw-w64 distribution I think it would 
benefit mingw-64 users. This is because the new Boost stacktrace library 
( I am not its author ) uses libbacktrace to produce stack trace 
information on demand, and I am sure you know that Boost is popular with 
C++ programmers. For VC++ on Windows the Boost stacktrace library uses 
other means to generate its stacktrace, so libbacktrace is really useful 
for Boost stacktrace when mingw-64 is being used. You can see Boost 
stacktrace at https://github.com/boostorg/stacktrace since it is now a 
Boost git submodule, and it should be part of the next Boost release.




But pay attention to the limited possibilities of libbacktrace, the 
developer[1] of this library writes about:
As of September 2016, libbacktrace only supports ELF and PE/COFF 
executables with DWARF debugging information.


That does not seem very limiting. ELF and PE/COFF covers all popular 
object file formats on Linux and Windows respectively and surely just 
about everyone not using VC++ uses DWARF rather than sjlj.






[1] https://github.com/ianlancetaylor/libbacktrace


Thanks for the link.

How would I build this above-linked libbacktrace in mingw-64 for myself 
? Am I supposed to use the current mingw-64 build script to do so and 
just copy the aforementioned 3 files to some final directories ?





--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public


Re: [Mingw-w64-public] Is there a libbacktrace library for mingw-64/gcc

2017-05-28 Thread niXman

Edward Diener 2017-05-28 16:32:


2) libbacktrace can be part of a mingw-64 distribution but relies on
other files in that distribution ?

Yes.


I see in [2] below that there was a discussion of making libbacktrace
standalone, but it appears that in the 4 years from that discussion
that it was never followed through.


I can make the libbacktrace part of the mingw-w64 distribution. In order 
to do this I should copy the three files(libbacktrace.a, backtrace.h, 
gstdint.h) from the GCC build tree.


But pay attention to the limited possibilities of libbacktrace, the 
developer[1] of this library writes about:
As of September 2016, libbacktrace only supports ELF and PE/COFF 
executables with DWARF debugging information.




[1] https://github.com/ianlancetaylor/libbacktrace

--
Regards, niXman
___
Dual-target(32 & 64-bit) MinGW-W64 compilers for 32 and 64-bit Windows:
https://sf.net/p/mingw-w64/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public


Re: [Mingw-w64-public] Is there a libbacktrace library for mingw-64/gcc

2017-05-28 Thread Edward Diener

On 5/28/2017 3:37 AM, niXman wrote:

Edward Diener 2017-05-27 23:37:

Hi,


Do I use msys2 in order to build libbacktrace ? When building do I
need to use the version of mingw-64/gcc for which I will be using
libbacktrace when I eventually use mingw-64/gcc as my compiler ? If I
need to do that do I just add the mingw-64/gcc compiler to the
beginning of my msys2 path ?

I have used various versions of mingw-64/gcc binaries in order to test
Boost libraries but I have never built another library for use by any
particular version of mingw-64/gcc, which is why I am asking these
questions.



You can just use the mingw-builds[1] scripts that are used to build the 
official mingw-w64 toolchains.
But the problem is yesterday I rebuild gcc-7-branch and in the logs of 
the builbing I can see libbacktrace has successfully builded, but not 
installed.


In accordance with this message[2], the libbacktrace should not be 
installed in the destination directory because the developers find an it 
inner instrument of GCC.


Are you essentially saying that:

1) libbacktrace can not be part of a mingw-64 distribution because it 
relies on gcc files which are not part of mingw-64 ?
2) libbacktrace can be part of a mingw-64 distribution but relies on 
other files in that distribution ?


I see in [2] below that there was a discussion of making libbacktrace 
standalone, but it appears that in the 4 years from that discussion that 
it was never followed through.






[1] https://github.com/niXman/mingw-builds
[2] https://gcc.gnu.org/ml/gcc/2013-05/msg00174.html





--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public


Re: [Mingw-w64-public] Is there a libbacktrace library for mingw-64/gcc

2017-05-28 Thread niXman

Edward Diener 2017-05-27 23:37:

Hi,


Do I use msys2 in order to build libbacktrace ? When building do I
need to use the version of mingw-64/gcc for which I will be using
libbacktrace when I eventually use mingw-64/gcc as my compiler ? If I
need to do that do I just add the mingw-64/gcc compiler to the
beginning of my msys2 path ?

I have used various versions of mingw-64/gcc binaries in order to test
Boost libraries but I have never built another library for use by any
particular version of mingw-64/gcc, which is why I am asking these
questions.



You can just use the mingw-builds[1] scripts that are used to build the 
official mingw-w64 toolchains.
But the problem is yesterday I rebuild gcc-7-branch and in the logs of 
the builbing I can see libbacktrace has successfully builded, but not 
installed.


In accordance with this message[2], the libbacktrace should not be 
installed in the destination directory because the developers find an it 
inner instrument of GCC.




[1] https://github.com/niXman/mingw-builds
[2] https://gcc.gnu.org/ml/gcc/2013-05/msg00174.html

--
Regards, niXman
___
Dual-target(32 & 64-bit) MinGW-W64 compilers for 32 and 64-bit Windows:
https://sf.net/p/mingw-w64/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public


Re: [Mingw-w64-public] Is there a libbacktrace library for mingw-64/gcc

2017-05-28 Thread Vincent Torri
it seems that it is part of gcc, so maybe the mingw-w64 maintainers should
be able to answer you

Vincent

On Sat, May 27, 2017 at 10:37 PM, Edward Diener <
eldlistmaili...@tropicsoft.com> wrote:

> On 5/27/2017 12:08 PM, niXman wrote:
>
>> Edward Diener 2017-05-27 18:40:
>>
>>> On 5/26/2017 11:03 PM, Vincent Torri wrote:
>>>
 ./configure --host=i686-w64-mingw32
 or
 ./configure --host=i686-w64-mingw32

 for respectively 32bits and 64bits support

>>>
>>> Your configure commands are the same.
>>>
>>
>>
>>
>> ./configure --host=i686-w64-mingw32
>> or
>> ./configure --host=x86_64-w64-mingw32
>>
>
> OK.
>
> Do I use msys2 in order to build libbacktrace ? When building do I need to
> use the version of mingw-64/gcc for which I will be using libbacktrace when
> I eventually use mingw-64/gcc as my compiler ? If I need to do that do I
> just add the mingw-64/gcc compiler to the beginning of my msys2 path ?
>
> I have used various versions of mingw-64/gcc binaries in order to test
> Boost libraries but I have never built another library for use by any
> particular version of mingw-64/gcc, which is why I am asking these
> questions.
>
>
> 
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> ___
> Mingw-w64-public mailing list
> Mingw-w64-public@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
>
--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public