Page 1 of 2

gcc 6 support?

PostPosted: Wed Jun 08, 2016 9:34 am
by Heiko
Hi there,

i recently wanted to give ecere sdk another chance for a project i am planning, unfortunately it is not possible to compile ecere sdk with gcc 6, which is default on archlinux.

Any plans to fix this in the near future?

Re: gcc 6 support?

PostPosted: Wed Jun 08, 2016 1:42 pm
by jerome
Hi Heiko,

Yes! Definitely, that is high on our priority list.

In fact it would be very helpful if you could provide us with information of what is not working so we can start figuring out a solution. (Build logs would be useful).

Regards,

-Jerome

Re: gcc 6 support?

PostPosted: Wed Jun 08, 2016 11:52 pm
by Heiko
btw: the 'fork me on github' link on the upper right of the homepage goes to a 404 from github

Bootstrapping eC compiling tools...
Building ecere...
Building ec...
Building ecp...
Building ecc...
Building ecs...
All done!
Building 2nd stage ecere...
obj/release.linux/Archive.c:327:93: error: expected ‘)’ before ‘__leaf__’
extern unsigned int gnu_dev_major(unsigned long long int __dev) __attribute__((__nothrow__ __leaf__)) __attribute__((__const__));
^~~~~~~~
obj/release.linux/Archive.c:327:102: error: expected ‘,’ or ‘;’ before ‘)’ token
extern unsigned int gnu_dev_major(unsigned long long int __dev) __attribute__((__nothrow__ __leaf__)) __attribute__((__const__));
^
obj/release.linux/Archive.c:329:93: error: expected ‘)’ before ‘__leaf__’
extern unsigned int gnu_dev_minor(unsigned long long int __dev) __attribute__((__nothrow__ __leaf__)) __attribute__((__const__));
^~~~~~~~
obj/release.linux/Archive.c:329:102: error: expected ‘,’ or ‘;’ before ‘)’ token
extern unsigned int gnu_dev_minor(unsigned long long int __dev) __attribute__((__nothrow__ __leaf__)) __attribute__((__const__));
^
obj/release.linux/Archive.c:331:119: error: expected ‘)’ before ‘__leaf__’
extern unsigned long long int gnu_dev_makedev(unsigned int __major, unsigned int __minor) __attribute__((__nothrow__ __leaf__)) __attribute__((__const__));
^~~~~~~~
obj/release.linux/Archive.c:331:128: error: expected ‘,’ or ‘;’ before ‘)’ token
extern unsigned long long int gnu_dev_makedev(unsigned int __major, unsigned int __minor) __attribute__((__nothrow__ __leaf__)) __attribute__((__const__));
^
Makefile:1440: recipe for target 'obj/release.linux/Archive.o' failed
make[1]: *** [obj/release.linux/Archive.o] Error 1
Makefile:202: recipe for target 'ecere' failed
make: *** [ecere] Error 2

Re: gcc 6 support?

PostPosted: Thu Jun 09, 2016 8:54 am
by jerome
Thanks for letting me know about the fork button!
I didn't realize this, they must have changed things around.

From these errors it seems that the first problem is the GCC headers now make use of the new __leaf__ keyword and we'll have to support it for things to build.
I'll try to setup a GCC 6 this weekend to address this.

In the meantime, is it possible for you to install an additional GCC 5 compiler on the side?

Regards,

-Jerome

Re: gcc 6 support?

PostPosted: Thu Jun 09, 2016 10:26 am
by jerome
In fact looking at this again (and the previous Debian bug report we had @ https://bugs.debian.org/cgi-bin/bugrepo ... bug=811957, the problem seems that these header files have non-comma separated attributes.

According to https://gcc.gnu.org/onlinedocs/gcc-6.1. ... ute-Syntax nothing indicates these come without commas :|

Of course this could be the eC compiler's fault that it ends up this way...
Downloading the latest Debian to update and get GCC 6 installed.

Re: gcc 6 support?

PostPosted: Thu Jun 09, 2016 10:56 am
by jerome
OK I now suspect the eC compiler is the one omitting the comma!
----
Definitely, we're not outputting a comma there.
It might be that GCC 6 decided to enforce requiring a comma between attributes while before it let a missing comma pass silently... I will commit an easy fix you could try.

Re: gcc 6 support?

PostPosted: Thu Jun 09, 2016 1:12 pm
by jerome
Pushed this commit to master which will hopefully address that particular GCC 6 build issue:

https://github.com/ecere/ecere-sdk/comm ... b70ebd0aa1

Re: gcc 6 support?

PostPosted: Thu Jun 09, 2016 3:01 pm
by jerome
Regarding the 'Fork me on GitHub' link, it's actually misleading.
You see this when you are not logged into your GitHub account, but actually at least now they have a 'login box' that does appear on the page. Once you sign in, you should land on the 'Fork' page.

It is quite annoying that they show the 404 page. But then I would say GitHub has the coolest 404 page on the Internet ;)

Re: gcc 6 support?

PostPosted: Thu Jun 09, 2016 6:05 pm
by jerome
Confirming that the issue is solved on master and the Ecere SDK now builds fine with GCC 6 (Tested with GCC 6.1.1 on latest Debian Unstable).

Re: gcc 6 support?

PostPosted: Fri Jun 10, 2016 12:03 pm
by Heiko
First of all:: wow, thanx for the quick help ;)

Well, now ecere sdk builds with gcc 6, but it still fails on archlinux:

Building Ecere Data Access layer...
src/EDA.ec:8:17: fatal error: ffi.h: No such file or directory
#include "ffi.h"
^
compilation terminated.
Makefile:172: recipe for target 'obj/release.linux/EDA.sym' failed
make[1]: *** [obj/release.linux/EDA.sym] Error 1
Makefile:15: recipe for target 'all' failed


and

Building EDASQLite driver...
EDASQLite.ec:16:17: fatal error: ffi.h: No such file or directory
#include "ffi.h"
^
compilation terminated.
Makefile:183: recipe for target 'obj/release.linux/EDASQLite.sym' failed
make[2]: *** [obj/release.linux/EDASQLite.sym] Error 1
Makefile:15: recipe for target 'all' failed
make[1]: *** [all] Error 2
Makefile:351: recipe for target 'eda' failed


I was able to fix it by addin -I/usr/lib/libffi-3.2.1/include to two Makefiles, but this is obviously not a proper fix. libffi is in pkg-config though, so i think you should use pkg-config for it.

The next issue on arch is: no fonts, no text whatsoever