Thanks for the pointer there, I've verified that
the old version was indeed segfaulting with
echo "3*3" | bc -l
After applying fixes it rightly prints '9'.
This change will be present in the next update,
I've pushed the relevant changes already.
- ikey
On 07/03/16 13:37, Jan Fikar wrote:
Or you can directly try:
http://alpha.gnu.org/gnu/bc/bc-1.06.95.tar.bz2
With just one patch:
http://mirror.qubenet.net/mirror/gentoo-portage/sys-devel/bc/files/bc-1.0...
This is what I have on Gentoo bc-1.06.95-r1
On 7.3.2016 14:21, Victor Rodriguez wrote:
> Apparently there are some patches that we need:
>
>
https://github.com/axilleas/aur-mirror/tree/master/bc-alpha
>
> I am gonna do the experiments and fix should be soon
>
> Thanks for the report :)
>
> Regards
>
> Victor Rodriguez
>
>
> On Mon, Mar 7, 2016 at 5:17 AM, Nesius, Robert A
> <robert.a.nesius(a)intel.com> wrote:
>>
>> Follow-up note - distro-provided bc on Arch does work. I was
>> previously only testing my own build against latest sources from
>>
ftp.gnu.org. Should be possible for us to compare/contrast and
>> figure it out.
>>
>> Thanks for the report.
>>
>> -Rob
>>
>>
>>
>>
>> On 3/7/16, 3:13 AM, "Dev on behalf of Nesius, Robert A"
>> <dev-bounces(a)lists.clearlinux.org on behalf of
>> robert.a.nesius(a)intel.com> wrote:
>>
>>>
>>> Whatever is happening on line 68 of load.c is broken on multiple
>>> platforms.
>>>
>>> Not sure what the root cause is but I repro'd it on Clear Linux and
>>> Arch Linux (32-bit and 64-bit).
>>>
>>> Hmm... I see a memory-leak patch for bc out in the wild, but that
>>> didn't look like a smoking gun. I did wonder based on comments I
>>> read in source if "bc -l" might run into problems when working
with
>>> a version of libm that had symbols stripped, but I just did some
>>> test-builds to explore that thought and came up blank.
>>>
>>> I'll try to look at this memory leak patch in the next day or so -
>>> it didn't apply cleanly for me.
>>>
>>> -Rob
>>>
>>>
>>>
>>>
>>>
>>> On 3/7/16, 1:35 AM, "Dev on behalf of Jan Fikar"
>>> <dev-bounces(a)lists.clearlinux.org on behalf of j.fikar(a)gmail.com>
>>> wrote:
>>>
>>>>
>>>>> I'm getting segmentation fault using "bc -l" to
calculate for
>>>>> example 3*3 in Clear Linux 6580, details are below. Without the -l
>>>>> parameter there is no problem.
>>>>>
>>>>> Best Regards,
>>>>> Jan
>>>>>
>>>>>
>>>>>
>>>>> fik@clr ~ $ bc -l
>>>>> bc 1.06
>>>>> Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.
>>>>> This is free software with ABSOLUTELY NO WARRANTY.
>>>>> For details type `warranty'.
>>>>> 3*3
>>>>> Segmentation fault
>>>>> fik@clr ~ $ bc
>>>>> bc 1.06
>>>>> Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.
>>>>> This is free software with ABSOLUTELY NO WARRANTY.
>>>>> For details type `warranty'.
>>>>> 3*3
>>>>> 9
>>>>> fik@clr ~ $ gdb /usr/bin/bc
>>>>> GNU gdb (GDB) 7.10.1
>>>>> Copyright (C) 2015 Free Software Foundation, Inc.
>>>>> License GPLv3+: GNU GPL version 3 or later
>>>>> <
http://gnu.org/licenses/gpl.html>
>>>>> This is free software: you are free to change and redistribute it.
>>>>> There is NO WARRANTY, to the extent permitted by law. Type
"show
>>>>> copying"
>>>>> and "show warranty" for details.
>>>>> This GDB was configured as "x86_64-generic-linux-gnu".
>>>>> Type "show configuration" for configuration details.
>>>>> For bug reporting instructions, please see:
>>>>> <
http://www.gnu.org/software/gdb/bugs/>.
>>>>> Find the GDB manual and other documentation resources online at:
>>>>> <
http://www.gnu.org/software/gdb/documentation/>.
>>>>> For help, type "help".
>>>>> Type "apropos word" to search for commands related to
"word"...
>>>>> Reading symbols from /usr/bin/bc...Reading symbols from
>>>>>
/usr/lib/debug/.build-id/e9/0aba169187c4c61a6358b737acfe325b661938.debug...done.
>>>>>
>>>>> done.
>>>>> (gdb) run -l
>>>>> Starting program: /usr/bin/bc -l
>>>>> bc 1.06
>>>>> Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.
>>>>> This is free software with ABSOLUTELY NO WARRANTY.
>>>>> For details type `warranty'.
>>>>> 3*3
>>>>>
>>>>> Program received signal SIGSEGV, Segmentation fault.
>>>>> addbyte (byte=byte@entry=75 'K') at load.c:68
>>>>> 68 if (pc >= f->f_body_size)
>>>>> (gdb) bt
>>>>> #0 addbyte (byte=byte@entry=75 'K') at load.c:68
>>>>> #1 0x0000000000405d72 in addbyte (byte=75 'K') at
load.c:348
>>>>> #2 load_code (code=<optimized out>) at load.c:307
>>>>> #3 0x000000000040765d in generate (str=str@entry=0x40c3b6
"K") at
>>>>> util.c:278
>>>>> #4 0x0000000000402c85 in yyparse () at bc.y:545
>>>>> #5 0x00000000004012fe in main (argc=2, argv=0x7fffffffe888) at
>>>>> main.c:259
>>>> _______________________________________________
>>>> Dev mailing list
>>>> Dev(a)lists.clearlinux.org
>>>>
https://lists.clearlinux.org/mailman/listinfo/dev
>>> _______________________________________________
>>> Dev mailing list
>>> Dev(a)lists.clearlinux.org
>>>
https://lists.clearlinux.org/mailman/listinfo/dev
>> _______________________________________________
>> Dev mailing list
>> Dev(a)lists.clearlinux.org
>>
https://lists.clearlinux.org/mailman/listinfo/dev
_______________________________________________
Dev mailing list
Dev(a)lists.clearlinux.org
https://lists.clearlinux.org/mailman/listinfo/dev