D-10 for GCC: was fcloseall() depricated

Need help with C, C++, perl, python, etc?

D-10 for GCC: was fcloseall() depricated

Postby mike acker » 2019-07-23 10:33

Code: Select all
~/Documents/1 Workareas/Workarea36$ gcc big_file_writer.c -o big_file_writer
big_file_writer.c: In function ‘main’:
big_file_writer.c:34:3: warning: implicit declaration of function ‘fcloseall’; did you mean ‘fclose’? [-Wimplicit-function-declaration]
   fcloseall();
   ^~~~~~~~~
   fclose


why is fcloseall()) rejected?
Viva la Resistencia
User avatar
mike acker
 
Posts: 126
Joined: 2017-06-28 21:23

Re: D-10 for GCC: was fcloseall() depricated

Postby ruwolf » 2019-07-23 11:00

It is not rejected, you have not declared it.
It is GNU C Library extension.
You probably should turn-on these extensions.
User avatar
ruwolf
 
Posts: 392
Joined: 2008-02-18 05:04
Location: Slovakia, Banovce nad Bebravou, Matice slovenskej 1260/4-7

Re: D-10 for GCC: was fcloseall() depricated

Postby mike acker » 2019-07-23 12:11

interesting

Code: Select all
#define _GNU_SOURCE /* include in order to use fcloseall() */


it would seem this was changed in D-10; I had not needed that declaration earlier
Viva la Resistencia
User avatar
mike acker
 
Posts: 126
Joined: 2017-06-28 21:23

Re: D-10 for GCC: was fcloseall() depricated

Postby stevepusser » 2019-07-23 17:07

Changed in the update to gcc-8 in Debian 10 would be a better way to say it. The same would also apply to any distro that updates to gcc-8, too.
The MX Linux repositories: Backports galore! If we don't have something, just ask and we'll try--we like challenges. New packages: Clipgrab 3.8.6, Hedgewars 1.0.0, PulseEffects 4.6.8, Telegram-desktop 1.8.15, Pale Moon 28.7.2, KeepassXC 2.5.1
User avatar
stevepusser
 
Posts: 11256
Joined: 2009-10-06 05:53


Return to Programming

Who is online

Users browsing this forum: No registered users and 4 guests

fashionable