Sponsored Content
Full Discussion: the sys_errlist.h problem
Top Forums Programming the sys_errlist.h problem Post 302356297 by eljuventino on Friday 25th of September 2009 05:54:02 AM
Old 09-25-2009
the sys_errlist.h problem

hi everyone !!!i hope that all the members are in good mood help me in my problem!!

when i'm trying to compile with gcc i got this problem:

Quote:
gcc -c -DLINUX -DUNIX_OPSYS -DDEBUG -I/home/oracle/Open2/COMMON/inc -I/home/oracle/Open2/dbg -I/home/oracle/Open2/syu/inc -I/home/oracle/Open2/syu/LGM/inc -I/usr/local/oracle/9.2.0/precomp/public -DLINUX -DUNIX_OPSYS -DDEBUG -I/home/oracle/Open2/COMMON/inc -I/home/oracle/Open2/dbg -I/home/oracle/Open2/syu/inc -I/home/oracle/Open2/syu/LGM/inc -I/usr/local/oracle/9.2.0/precomp/public -c -o su_lgm_lib_ctim.o su_lgm_lib_ctim.c
su_lgm_lib_ctim.c:39: erreur: conflicting types for ‘sys_errlist'
/usr/include/bits/sys_errlist.h:28: erreur: previous declaration of ‘sys_errlist' was here
make: *** [su_lgm_lib_ctim.o] Erreur 1
when i go to the code there is nothing unusual :

Code:
/****************************************************************************/
/* Project: ePOST/Open2 */
/* File Name: su_lgm_lib_ctim.c */
/* Subsystem: System Utilities */
/* Module: LGM - Log Manager internal libraries */
/* Process: LGM */
/* Description: Log Manage common functions */
/* Author(s): R. Navone */
/* Created: 24-Set-1996 */
/****************************************************************************/
/* Modification History */
/* */
/* Revision Date Who modified Description */
/* ........ ..-...-.... ............. ............................... */
/****************************************************************************/

/****************************************************************************/
/* INCLUDEs and DEFINEs */
/****************************************************************************/

#include "su_lgm.h"
#include "su_debug.h"


/* What string. It must be defined in all source files */
static char lgmlib_c[]="@(#)$Workfile: su_lgm_lib_ctim.c $,$Revision: 2.0 $,$Modtime: 30 Jan 2003 15:36:32 $";

#ifdef FL_STATIC
static char *SrC_NAmE = __FILE__;
#define _FL SrC_NAmE,__LINE__
#else
#define _FL __FILE__,__LINE__
#endif

/****************************************************************************/
/* GLOBAL/EXTERNAL VARIABLES */
/****************************************************************************/
extern int errno, sys_nerr;
extern char *sys_errlist[];
extern int Debug;

/****************************************************************************/
/* FUNCTIONS DEFINITION */
/****************************************************************************/
/****************************************************************************/
/* Function: our_ctime */
/* L.M. Date: 24-Jun-1996 */
/* Description: Like the orginal ctime(), but the returned string doesn't */
/* contain new line (s). */
/****************************************************************************/
char *our_ctime(time_t t)
{
register char *p1, *p2;

p1 = p2 = (char *)ctime(&t);
while(*p1)
{
if (*p1 == '\n')
{
*p1 = 0;
return(p2);
}
p1++;
}
return(p2);
}
i tried to resolve this problem so i tried to go to the
/usr/include/bits/sys_errlist.h

and i open it but i didn't understand anything:
Code:
Declare sys_errlist and sys_nerr, or don't. Compatibility (do) version.
Copyright (C) 2002 Free Software Foundation, Inc.
This file is part of the GNU C Library.

The GNU C Library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.

The GNU C Library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public
License along with the GNU C Library; if not, write to the Free
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */

#ifndef _STDIO_H
# error "Never include <bits/sys_errlist.h> directly; use <stdio.h> instead."
#endif

/* sys_errlist and sys_nerr are deprecated. Use strerror instead. */

#ifdef __USE_BSD
extern int sys_nerr;
extern __const char *__const sys_errlist[];
#endif
#ifdef __USE_GNU
extern int _sys_nerr;
extern __const char *__const _sys_errlist[];
#endif
so i included the stdio.h in the file and nothing happen,i tried to use the -D OPTION to tell the complierv to use __USE_GNU

any idea for this problem!!
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

SSH Problem auth problem

Hi, Just recently we seem to be getting the following error message relating to SSH when we run the UNIX script in background mode: warning: You have no controlling tty. Cannot read confirmation.^M warning: Authentication failed.^M Disconnected; key exchange or algorithm negotiation... (1 Reply)
Discussion started by: budrito
1 Replies

2. Shell Programming and Scripting

problem with dd command or maybe AFS problem

Hi, folks. Sorry for bothering, but maybe someone could help me please. The problem is the following: there is some script that copies files from local file system to AFS. The copying is performed with dd command. The script copies data into some AFS volumes. The problem appeared with one... (0 Replies)
Discussion started by: Anta
0 Replies

3. Solaris

sys_nerr and *sys_errlist[] in 64-bit

The variables sys_nerr and *sys_errlist no more exist in 64-bit compiler option.I know one way is to use strerror() function.But I have very long interlinked code which i have to migrate from 32-bit to 64-bit .Can any one tell any other way of doing the same without modifying much od the... (2 Replies)
Discussion started by: vishalzone2002
2 Replies

4. Solaris

problem in finding a hardware problem

Hi I am right now facing a strange hardware problem. System get booted with the following error: Fatal Error Reset CPU 0000.0000.0000.0003 AFSR 0100.0000.0000.0000 SCE AFAR 0000.07c6.0000.1000 SC Alert: Host System has Reset It happen 4 or 5 times and get the same error every time.I... (8 Replies)
Discussion started by: girish.batra
8 Replies

5. AIX

user login problem & Files listing problem.

1) when user login to the server the session got colosed. How will resolve? 2) While firing the command ls -l we are not able to see the any files in the director. but over all view the file system using the command df -g it is showing 91% used. what will be the problem? Thanks in advance. (1 Reply)
Discussion started by: pernasivam
1 Replies

6. UNIX for Dummies Questions & Answers

DHCP problem and eth1 problem

At work I am trying to get this one Linux machine (let's call it ctesgm07) to behave like another Linux machine that we have (let's call it test007). test007 returns the following version info: cat /etc/debian_version: lenny/sid uname -a: Linux test007 2.6.27-7-generic #1 SMP Tue Nov 4... (0 Replies)
Discussion started by: sllinux
0 Replies

7. AIX

AIX OS problem? network problem?

Dear ALL. I installed AIX OS on customer sites. but Only one site is too slow when I connected telnet, ftp.. Ping is too fast. but telnet and FTP is not connected.. of course i check the configuration file on aix but it's normal. Do any Idea?? thanks in advance. - Jun - (3 Replies)
Discussion started by: Jeon Jun Seok
3 Replies

8. IP Networking

Problem with forwarding emails (SPF problem)

Hi, This is rather a question from a "user" than from a sys admin, but I think this forum is apropriate for the question. I have an adress with automatic email forwarding and for some senders (two hietherto), emails are bouncing. This has really created a lot of problems those two time so I... (0 Replies)
Discussion started by: carwe
0 Replies

9. UNIX for Dummies Questions & Answers

sed Or Grep Problem OR Terminal Problem?

I don't know if you guys get this problem sometimes at Terminal but I had been having this problem since yesterday :( Maybe I overdid the Terminal. Even the codes that used to work doesn't work anymore. Here is what 's happening: * I wanted to remove lines containing digits so I used this... (25 Replies)
Discussion started by: Nexeu
25 Replies

10. IP Networking

Router problem or ISP problem ?

Hi everyone, I am experiencing discontinuity of Internet service, this started 1 month ago. Everything worked very well for 1 year of intensive use, but now, I have problems reaching my gateway. The gateway is not my router but a node belonging to my ISP and I share the same public IP with... (3 Replies)
Discussion started by: remic
3 Replies
All times are GMT -4. The time now is 02:34 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy