Re: [fossil-users] Rejected JSON tests
On Wed, Jun 1, 2016 at 1:00 AM, Kain Abel wrote: > I've slightly modified your line from the top: > lm@um:~/src/fossil$ gcc -c -pedantic -I./src -Wall -Werror -fPIC > -Wstrict-aliasing -g -Wno-long-long -std=c89 ./src/cson_amalgamation.c > -DFOSSIL_ENABLE_JSON -Og > lm@um:~/src/fossil$ gcc -c -pedantic -I./src -Wall -Werror -fPIC > -Wstrict-aliasing -g -Wno-long-long -std=c89 ./src/cson_amalgamation.c > -DFOSSIL_ENABLE_JSON -O1 > lm@um:~/src/fossil$ gcc -c -pedantic -I./src -Wall -Werror -fPIC > -Wstrict-aliasing -g -Wno-long-long -std=c89 ./src/cson_amalgamation.c > -DFOSSIL_ENABLE_JSON -O2 > ./src/cson_amalgamation.c: In function ‘cson_value_new_integer’: > ./src/cson_amalgamation.c:2863:13: error: dereferencing type-punned > pointer will break strict-aliasing rules [-Werror=strict-aliasing] > *CSON_INT(c) = v; > ^ > cc1: all warnings being treated as errors > lm@um:~/src/fossil$ gcc -c -pedantic -I./src -Wall -Werror -fPIC > -Wstrict-aliasing -g -Wno-long-long -std=c89 ./src/cson_amalgamation.c > -DFOSSIL_ENABLE_JSON -Os > ./src/cson_amalgamation.c: In function ‘cson_value_new_integer’: > ./src/cson_amalgamation.c:2863:13: error: dereferencing type-punned > pointer will break strict-aliasing rules [-Werror=strict-aliasing] > *CSON_INT(c) = v; > ^ > cc1: all warnings being treated as errors > > The same thing happens with a GCC 4.8 by the switching of the > optimizer flags (or to -std=c99). > aha! i will take a look at it as soon as i am capable of emacsing with 2 hand again. i'm not sure how that can be resolved without fundamental code changes, as it's a side-effect of allocating a cson_value and integer in the same block of memory (that macro accesses the integer part of that memory block). -- - stephan beal http://wanderinghorse.net/home/stephan/ http://gplus.to/sgbeal "Freedom is sloppy. But since tyranny's the only guaranteed byproduct of those who insist on a perfect world, freedom will have to do." -- Bigby Wolf ___ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
Re: [fossil-users] Rejected JSON tests
Hi Stephan, again, I beg your pardon. My work ate all the time. I've slightly modified your line from the top: lm@um:~/src/fossil$ gcc -c -pedantic -I./src -Wall -Werror -fPIC -Wstrict-aliasing -g -Wno-long-long -std=c89 ./src/cson_amalgamation.c -DFOSSIL_ENABLE_JSON -Og lm@um:~/src/fossil$ gcc -c -pedantic -I./src -Wall -Werror -fPIC -Wstrict-aliasing -g -Wno-long-long -std=c89 ./src/cson_amalgamation.c -DFOSSIL_ENABLE_JSON -O1 lm@um:~/src/fossil$ gcc -c -pedantic -I./src -Wall -Werror -fPIC -Wstrict-aliasing -g -Wno-long-long -std=c89 ./src/cson_amalgamation.c -DFOSSIL_ENABLE_JSON -O2 ./src/cson_amalgamation.c: In function ‘cson_value_new_integer’: ./src/cson_amalgamation.c:2863:13: error: dereferencing type-punned pointer will break strict-aliasing rules [-Werror=strict-aliasing] *CSON_INT(c) = v; ^ cc1: all warnings being treated as errors lm@um:~/src/fossil$ gcc -c -pedantic -I./src -Wall -Werror -fPIC -Wstrict-aliasing -g -Wno-long-long -std=c89 ./src/cson_amalgamation.c -DFOSSIL_ENABLE_JSON -Os ./src/cson_amalgamation.c: In function ‘cson_value_new_integer’: ./src/cson_amalgamation.c:2863:13: error: dereferencing type-punned pointer will break strict-aliasing rules [-Werror=strict-aliasing] *CSON_INT(c) = v; ^ cc1: all warnings being treated as errors The same thing happens with a GCC 4.8 by the switching of the optimizer flags (or to -std=c99). lm@um:~/src/fossil$ uname -a Linux um 4.4.0-22-generic #40-Ubuntu SMP Thu May 12 22:03:46 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux lm@um:~/src/fossil$ gcc --version gcc (Ubuntu 5.3.1-14ubuntu2.1) 5.3.1 20160413 lm@um:~/src/fossil$ $ gcc-4.8 --version gcc-4.8 (Ubuntu 4.8.5-4ubuntu2) 4.8.5 With best regards, Kain ___ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
Re: [fossil-users] Rejected JSON tests
Hi Ross, sorry for the late reply. My day job ate all the time. Thanks for the tip. 'apt-get install tcllib' solved the problem. Best regards and thanks, Kain 2016-05-27 22:52 GMT+02:00 Ross Berteig : > The issue here is that you don't have the json package installed in your > copy of Tcl with which you are running the test harness. > > There is a comment in json.test that has the reminder of which json library > I used. Specifically, I used the one from tcllib, as packaged and delivered > by ActiveTcl's teacup utility. > > https://www.fossil-scm.org/index.html/artifact/65f8333164e4?txt=1&ln=33-38 ___ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
Re: [fossil-users] Rejected JSON tests
On Fri, May 27, 2016 at 1:39 PM, Kain Abel wrote: > > ./src/cson_amalgamation.c: In function ‘cson_value_new_integer’: > ./src/cson_amalgamation.c:2863:13: warning: dereferencing type-punned > pointer will break strict-aliasing rules [-Wstrict-aliasing] > *CSON_INT(c) = v; > Hi again Kain, i suspect that this warning might be specific to gcc 4.4. i just tried it on the original sources with gcc 4.8 and it does not warn there (and also didn't with the older gcc versions it was original developed with): [stephan@host:~/fossil/cson]$ gcc -c -pedantic -Wall -Werror -fPIC -Wstrict-aliasing -g -std=c89 cson_amalgamation.c [stephan@host:~/fossil/cson]$ gcc --version gcc (Ubuntu 4.8.4-2ubuntu1~14.04.3) 4.8.4 also tried with -std=c99. -- - stephan beal http://wanderinghorse.net/home/stephan/ http://gplus.to/sgbeal "Freedom is sloppy. But since tyranny's the only guaranteed byproduct of those who insist on a perfect world, freedom will have to do." -- Bigby Wolf ___ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
Re: [fossil-users] Rejected JSON tests
On 5/27/2016 4:39 AM, Kain Abel wrote: Dear devs, dear users, the script tester.tcl don't like the JSON support?. lm@um:/tmp$ tclsh /tmp/test/tester.tcl /tmp/fossil -quiet -prot can't find package json while executing "package require json" (file "/tmp/test/json.test" line 38) invoked from within The issue here is that you don't have the json package installed in your copy of Tcl with which you are running the test harness. There is a comment in json.test that has the reminder of which json library I used. Specifically, I used the one from tcllib, as packaged and delivered by ActiveTcl's teacup utility. https://www.fossil-scm.org/index.html/artifact/65f8333164e4?txt=1&ln=33-38 On linux, you'll have to find your own way to get the library, IIRC I was able to tease it out of apt-get, but I don't recall what its name was. -- Ross Berteig r...@cheshireeng.com Cheshire Engineering Corp. http://www.CheshireEng.com/ +1 626 303 1602 ___ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users