* sim/ucsim/gui.src/serio.src/fileio.cc
* sim/ucsim/gui.src/serio.src/frontend.cc
* sim/ucsim/gui.src/serio.src/main.cc
* sim/ucsim/gui.src/serio.src/posix_signal.cc
* support/Util/NewAlloc.c
* as/hc08/lklibr.c
* as/mcs51/lklibr.c
* as/z80/aslist.c
* as/z80/assym.c
git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@2989
4a8a32a2-be11-0410-ad9d-
d568d2c75423
+2003-11-03 Bernhard Held <bernhard@bernhardheld.de>
+
+ Use headers defined in the C[++] standards:
+ * sim/ucsim/gui.src/serio.src/fileio.cc
+ * sim/ucsim/gui.src/serio.src/frontend.cc
+ * sim/ucsim/gui.src/serio.src/main.cc
+ * sim/ucsim/gui.src/serio.src/posix_signal.cc
+ * support/Util/NewAlloc.c
+ * as/hc08/lklibr.c
+ * as/mcs51/lklibr.c
+ * as/z80/aslist.c
+ * as/z80/assym.c
+
2003-11-03 Jesus Calvino-Fraga <jesusc@ece.ubc.ca>
* Added MSVC projects for hc08 assembler and linker:
2003-11-03 Jesus Calvino-Fraga <jesusc@ece.ubc.ca>
* Added MSVC projects for hc08 assembler and linker:
#if defined(__APPLE__) && defined(__MACH__)
#include <sys/types.h>
#include <sys/malloc.h>
#if defined(__APPLE__) && defined(__MACH__)
#include <sys/types.h>
#include <sys/malloc.h>
+#elseif !defined(__FreeBSD__)
#include <malloc.h>
#endif
#include <stdio.h>
#include <malloc.h>
#endif
#include <stdio.h>
#if defined(__APPLE__) && defined(__MACH__)
#include <sys/types.h>
#include <sys/malloc.h>
#if defined(__APPLE__) && defined(__MACH__)
#include <sys/types.h>
#include <sys/malloc.h>
+#elseif !defined(__FreeBSD__)
#include <malloc.h>
#endif
#include <stdio.h>
#include <malloc.h>
#endif
#include <stdio.h>
#include <stdio.h>
#include <setjmp.h>
#include <string.h>
#include <stdio.h>
#include <setjmp.h>
#include <string.h>
#if defined(__APPLE__) && defined(__MACH__)
#include <sys/types.h>
#include <sys/malloc.h>
#if defined(__APPLE__) && defined(__MACH__)
#include <sys/types.h>
#include <sys/malloc.h>
#include <malloc.h>
#endif
#include <malloc.h>
#endif
#include "asm.h"
/*)Module aslist.c
#include "asm.h"
/*)Module aslist.c
#include <stdio.h>
#include <setjmp.h>
#include <string.h>
#include <stdio.h>
#include <setjmp.h>
#include <string.h>
#if defined(__APPLE__) && defined(__MACH__)
#include <sys/types.h>
#include <sys/malloc.h>
#if defined(__APPLE__) && defined(__MACH__)
#include <sys/types.h>
#include <sys/malloc.h>
* fileio.cc - file input and output *
******************************************************************************/
#include <sys/types.h>
* fileio.cc - file input and output *
******************************************************************************/
#include <sys/types.h>
#include <stdlib.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <stdlib.h>
#include <sys/stat.h>
#include <fcntl.h>
// make the input fifo
if(mkfifo(DEF_INFILE, S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH) == -1) {
if(errno != EEXIST) {
// make the input fifo
if(mkfifo(DEF_INFILE, S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH) == -1) {
if(errno != EEXIST) {
- cerr << "mkfifo(): Error number " << errno << " occourred: " << strerror(errno) << "\n";
+ std::cerr << "mkfifo(): Error number " << errno << " occourred: " << strerror(errno) << "\n";
exit(-1);
}
}
// the input fifo - non blocking
if ((fdin = open(DEF_INFILE, O_RDONLY|O_NONBLOCK)) == -1) {
exit(-1);
}
}
// the input fifo - non blocking
if ((fdin = open(DEF_INFILE, O_RDONLY|O_NONBLOCK)) == -1) {
- cerr << "open(): Error number " << errno << " occourred: " << strerror(errno) << "\n";
+ std::cerr << "open(): Error number " << errno << " occourred: " << strerror(errno) << "\n";
exit(-1);
}
// make the output fifo
if(mkfifo(DEF_OUTFILE, S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH) == -1) {
if(errno != EEXIST) {
exit(-1);
}
// make the output fifo
if(mkfifo(DEF_OUTFILE, S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH) == -1) {
if(errno != EEXIST) {
- cerr << "mkfifo(): Error number " << errno << " occourred: " << strerror(errno) << "\n";
+ std::cerr << "mkfifo(): Error number " << errno << " occourred: " << strerror(errno) << "\n";
exit(-1);
}
}
// the output fifo
if ((fdout = open(DEF_OUTFILE, O_RDWR|O_NONBLOCK)) == -1) {
exit(-1);
}
}
// the output fifo
if ((fdout = open(DEF_OUTFILE, O_RDWR|O_NONBLOCK)) == -1) {
- cerr << "open(): Error number " << errno << " occourred: " << strerror(errno) << "\n";
+ std::cerr << "open(): Error number " << errno << " occourred: " << strerror(errno) << "\n";
// make the input fifo
if(mkfifo(infile, S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH) == -1) {
if(errno != EEXIST) {
// make the input fifo
if(mkfifo(infile, S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH) == -1) {
if(errno != EEXIST) {
- cerr << "mkfifo(): Error number " << errno << " occourred: " << strerror(errno);
+ std::cerr << "mkfifo(): Error number " << errno << " occourred: " << strerror(errno);
exit(-1);
}
}
// the input fifo - non blocking
if ((fdin = open(infile, O_RDONLY|O_NONBLOCK)) == -1) {
exit(-1);
}
}
// the input fifo - non blocking
if ((fdin = open(infile, O_RDONLY|O_NONBLOCK)) == -1) {
- cerr << "open(): Error number " << errno << " occourred: " << strerror(errno);
+ std::cerr << "open(): Error number " << errno << " occourred: " << strerror(errno);
exit(-1);
}
// make the output fifo
if(mkfifo(outfile, S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH) == -1) {
if(errno != EEXIST) {
exit(-1);
}
// make the output fifo
if(mkfifo(outfile, S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH) == -1) {
if(errno != EEXIST) {
- cerr << "mkfifo(): Error number " << errno << " occourred: " << strerror(errno);
+ std::cerr << "mkfifo(): Error number " << errno << " occourred: " << strerror(errno);
exit(-1);
}
}
// the output fifo
if ((fdout = open(outfile, O_RDWR|O_NONBLOCK)) == -1) {
exit(-1);
}
}
// the output fifo
if ((fdout = open(outfile, O_RDWR|O_NONBLOCK)) == -1) {
- cerr << "open(): Error number " << errno << " occourred: " << strerror(errno);
+ std::cerr << "open(): Error number " << errno << " occourred: " << strerror(errno);
if((ret = write(fdout, &b, 1)) != 1)
{
if((ret = write(fdout, &b, 1)) != 1)
{
- cerr << "write(): Error number " << errno << " occourred: " << strerror(errno);
+ std::cerr << "write(): Error number " << errno << " occourred: " << strerror(errno);
if((ret == -1) && (errno != EAGAIN))
{
if((ret == -1) && (errno != EAGAIN))
{
- cerr << "read(): Error number " << errno << " occourred: " << strerror(errno);
+ std::cerr << "read(): Error number " << errno << " occourred: " << strerror(errno);
if((ret = write(fdout, str, strlen(str))) != (int)strlen(str))
{
if((ret = write(fdout, str, strlen(str))) != (int)strlen(str))
{
- cerr << "write(): Error number " << errno << " occourred: " << strerror(errno);
+ std::cerr << "write(): Error number " << errno << " occourred: " << strerror(errno);
if((ret == -1) && (errno != EAGAIN))
{
if((ret == -1) && (errno != EAGAIN))
{
- cerr << "read(): Error number " << errno << " occourred: " << strerror(errno);
+ std::cerr << "read(): Error number " << errno << " occourred: " << strerror(errno);
* frontend.cc - the ncurses frontend *
******************************************************************************/
#include <sys/types.h>
* frontend.cc - the ncurses frontend *
******************************************************************************/
#include <sys/types.h>
#include <stdlib.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <stdlib.h>
#include <sys/stat.h>
#include <fcntl.h>
* main.cc - the main stuff *
******************************************************************************/
#include <sys/types.h>
* main.cc - the main stuff *
******************************************************************************/
#include <sys/types.h>
#include <stdlib.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <stdlib.h>
#include <sys/stat.h>
#include <fcntl.h>
// usage
void PrintUsage(char *progname)
{
// usage
void PrintUsage(char *progname)
{
-cout << "Usage: " << progname << " [-i <filename>] [-o <filename>] [-h]\n";
-cout << "-i <filename>\t<filename> is the pipe to the controllers' serial input\n";
-cout << "-o <filename>\t<filename> is the pipe to the controllers' serial output\n";
-cout << "-h\t\tshow the help\n";
-cout << "\nTim Hurman - t.hurman@virgin.net\n";
+std::cout << "Usage: " << progname << " [-i <filename>] [-o <filename>] [-h]\n";
+std::cout << "-i <filename>\t<filename> is the pipe to the controllers' serial input\n";
+std::cout << "-o <filename>\t<filename> is the pipe to the controllers' serial output\n";
+std::cout << "-h\t\tshow the help\n";
+std::cout << "\nTim Hurman - t.hurman@virgin.net\n";
errflg++;
break;
default:
errflg++;
break;
default:
- cerr << "Invalid or unknown switch\n";
+ std::cerr << "Invalid or unknown switch\n";
if(string[0] != 0)
fobj->SendByte(string[0]);
if(string[0] != 0)
fobj->SendByte(string[0]);
if(fobj->RecvStr(string) > 0)
view->AddStrOutWin(string);
if(fobj->RecvStr(string) > 0)
view->AddStrOutWin(string);
*/
#include <sys/types.h>
*/
#include <sys/types.h>
#include <sys/wait.h> /* header for waitpid() and various macros */
#include <signal.h> /* header for signal functions */
#include <stdlib.h>
#include <sys/wait.h> /* header for waitpid() and various macros */
#include <signal.h> /* header for signal functions */
#include <stdlib.h>
/* set the signal handler */
if(sigaction(SIGNAL, &act, NULL) < 0)
{
/* set the signal handler */
if(sigaction(SIGNAL, &act, NULL) < 0)
{
- cerr << "sigaction(): " << strerror(errno) << "\n";
+ std::cerr << "sigaction(): " << strerror(errno) << "\n";
/* block it */
if(sigprocmask(SIG_BLOCK, &set, NULL) < 0)
{
/* block it */
if(sigprocmask(SIG_BLOCK, &set, NULL) < 0)
{
- cerr << "sigprocmask(): " << strerror(errno) << "\n";
+ std::cerr << "sigprocmask(): " << strerror(errno) << "\n";
/* block it */
if(sigprocmask(SIG_UNBLOCK, &set, NULL) < 0)
{
/* block it */
if(sigprocmask(SIG_UNBLOCK, &set, NULL) < 0)
{
- cerr << "sigprocmask(): " << strerror(errno) << "\n";
+ std::cerr << "sigprocmask(): " << strerror(errno) << "\n";
#include <stdio.h>
#if defined(__APPLE__) && defined(__MACH__)
#include <sys/malloc.h>
#include <stdio.h>
#if defined(__APPLE__) && defined(__MACH__)
#include <sys/malloc.h>
+#elseif !defined(__FreeBSD__)
#include <malloc.h>
#endif
#include <stdlib.h>
#include <malloc.h>
#endif
#include <stdlib.h>