summaryrefslogtreecommitdiff
path: root/src/nonstd
diff options
context:
space:
mode:
Diffstat (limited to 'src/nonstd')
-rw-r--r--src/nonstd/_FTM/_POSIX_C_SOURCE.c0
-rw-r--r--src/nonstd/_FTM/_POSIX_SOURCE.c5
-rw-r--r--src/nonstd/_FTM/_XOPEN_SOURCE.c0
-rw-r--r--src/nonstd/_FTM/_XOPEN_SOURCE_EXTENDED.c0
-rw-r--r--src/nonstd/_PREDEF/__DATE__.c12
-rw-r--r--src/nonstd/_PREDEF/__FILE__.c14
-rw-r--r--src/nonstd/_PREDEF/__LINE__.c14
-rw-r--r--src/nonstd/_PREDEF/__STDC_HOSTED__.c10
-rw-r--r--src/nonstd/_PREDEF/__STDC_IEC_559_COMPLEX__.c10
-rw-r--r--src/nonstd/_PREDEF/__STDC_IEC_559__.c10
-rw-r--r--src/nonstd/_PREDEF/__STDC_ISO_10646__.c13
-rw-r--r--src/nonstd/_PREDEF/__STDC_VERSION__.c13
-rw-r--r--src/nonstd/_PREDEF/__STDC__.c14
-rw-r--r--src/nonstd/_PREDEF/__TIME__.c12
-rw-r--r--src/nonstd/__libc_start.c48
-rw-r--r--src/nonstd/x86-32.s18
-rw-r--r--src/nonstd/x86-64.s21
17 files changed, 0 insertions, 214 deletions
diff --git a/src/nonstd/_FTM/_POSIX_C_SOURCE.c b/src/nonstd/_FTM/_POSIX_C_SOURCE.c
deleted file mode 100644
index e69de29b..00000000
--- a/src/nonstd/_FTM/_POSIX_C_SOURCE.c
+++ /dev/null
diff --git a/src/nonstd/_FTM/_POSIX_SOURCE.c b/src/nonstd/_FTM/_POSIX_SOURCE.c
deleted file mode 100644
index b594f3d9..00000000
--- a/src/nonstd/_FTM/_POSIX_SOURCE.c
+++ /dev/null
@@ -1,5 +0,0 @@
-#define _POSIX_SOURCE /** feature test macro **/
-/*
-FTM(POSIX.1-1988)
-POSIX(1)
-*/
diff --git a/src/nonstd/_FTM/_XOPEN_SOURCE.c b/src/nonstd/_FTM/_XOPEN_SOURCE.c
deleted file mode 100644
index e69de29b..00000000
--- a/src/nonstd/_FTM/_XOPEN_SOURCE.c
+++ /dev/null
diff --git a/src/nonstd/_FTM/_XOPEN_SOURCE_EXTENDED.c b/src/nonstd/_FTM/_XOPEN_SOURCE_EXTENDED.c
deleted file mode 100644
index e69de29b..00000000
--- a/src/nonstd/_FTM/_XOPEN_SOURCE_EXTENDED.c
+++ /dev/null
diff --git a/src/nonstd/_PREDEF/__DATE__.c b/src/nonstd/_PREDEF/__DATE__.c
deleted file mode 100644
index 14e40fcb..00000000
--- a/src/nonstd/_PREDEF/__DATE__.c
+++ /dev/null
@@ -1,12 +0,0 @@
-#define __DATE__ /** date of compilation **/
-
-/***
-is automatically defined by the compiler as the date of program
-compilation, in the format DEFINITION("Mmm dd yyyy").
-***/
-
-/*
-VALUE_TYPE(string literal)
-VALUE_FIXED(VAR("date-of-compilation"))
-STDC(1)
-*/
diff --git a/src/nonstd/_PREDEF/__FILE__.c b/src/nonstd/_PREDEF/__FILE__.c
deleted file mode 100644
index 257ae89b..00000000
--- a/src/nonstd/_PREDEF/__FILE__.c
+++ /dev/null
@@ -1,14 +0,0 @@
-#define __FILE__ /** source file name **/
-
-/***
-is automatically defined by the compiler as the file name of the
-current source file being compiled as a character string literal.
-
-THIS() can be changed using PPDIR(line).
-***/
-
-/*
-VALUE_TYPE(string literal)
-VALUE_FIXED(VAR(the current file name))
-STDC(1)
-*/
diff --git a/src/nonstd/_PREDEF/__LINE__.c b/src/nonstd/_PREDEF/__LINE__.c
deleted file mode 100644
index c6acb1b1..00000000
--- a/src/nonstd/_PREDEF/__LINE__.c
+++ /dev/null
@@ -1,14 +0,0 @@
-#define __LINE__ /** source file line number **/
-
-/***
-is automatically defined by the compiler as the current logical source
-line in the source file being compiled.
-
-THIS() can be changed during compilation using PPDIR(line).
-***/
-
-/*
-VALUE_TYPE(TYPE(int))
-VALUE_FIXED(VAR(the current line number))
-STDC(1)
-*/
diff --git a/src/nonstd/_PREDEF/__STDC_HOSTED__.c b/src/nonstd/_PREDEF/__STDC_HOSTED__.c
deleted file mode 100644
index 48fe28b7..00000000
--- a/src/nonstd/_PREDEF/__STDC_HOSTED__.c
+++ /dev/null
@@ -1,10 +0,0 @@
-#define __STDC_HOSTED__ /** hosted or free-standing implementation **/
-
-/***
-is defined to the integer constant CONST(1) if the implementation
-is hosted, CONST(0) otherwise.
-***/
-
-/*
-STDC(199901)
-*/
diff --git a/src/nonstd/_PREDEF/__STDC_IEC_559_COMPLEX__.c b/src/nonstd/_PREDEF/__STDC_IEC_559_COMPLEX__.c
deleted file mode 100644
index a8d1f810..00000000
--- a/src/nonstd/_PREDEF/__STDC_IEC_559_COMPLEX__.c
+++ /dev/null
@@ -1,10 +0,0 @@
-#define __STDC_IEC_559_COMPLEX__ /** IEC 60559 complex arithmetic **/
-
-/***
-is defined to CONST(1) if the implementation conforms to Annex G
-of ISO/IEC 9899 (IEC 60559 complex arithmetic).
-***/
-
-/*
-STDC(199901)
-*/
diff --git a/src/nonstd/_PREDEF/__STDC_IEC_559__.c b/src/nonstd/_PREDEF/__STDC_IEC_559__.c
deleted file mode 100644
index bdc441c4..00000000
--- a/src/nonstd/_PREDEF/__STDC_IEC_559__.c
+++ /dev/null
@@ -1,10 +0,0 @@
-#define __STDC_IEC_559__ /** IEC 60559 floating-point arithmetic **/
-
-/***
-is defined to CONST(1) if the implementation conforms to Annex G
-of ISO/IEC 9899 (IEC 60559 floating-point arithmetic).
-***/
-
-/*
-STDC(199901)
-*/
diff --git a/src/nonstd/_PREDEF/__STDC_ISO_10646__.c b/src/nonstd/_PREDEF/__STDC_ISO_10646__.c
deleted file mode 100644
index 3379c855..00000000
--- a/src/nonstd/_PREDEF/__STDC_ISO_10646__.c
+++ /dev/null
@@ -1,13 +0,0 @@
-#define __STDC_ISO_10646__ /** supported UCS version **/
-
-/***
-is defined if TYPE(wchar_t) represents characters encoded
-in conformance with ISO/IEC 10646. In this case, THIS() is
-defined as an integer CONST(yyyymmL), where CONST(yyyy)
-represents the year and CONST(mm) the month of the supported
-version of ISO/IEC 10646.
-***/
-
-/*
-STDC(199901)
-*/
diff --git a/src/nonstd/_PREDEF/__STDC_VERSION__.c b/src/nonstd/_PREDEF/__STDC_VERSION__.c
deleted file mode 100644
index 56a23d90..00000000
--- a/src/nonstd/_PREDEF/__STDC_VERSION__.c
+++ /dev/null
@@ -1,13 +0,0 @@
-#define __STDC_VERSION__ /** supported C standard **/
-
-/***
-declares the supported version of ISO/IEC 9899. If THIS() is not defined,
-the implementation only supports ISO/IEC 9899:1990, without AMD1.
-***/
-
-/*
-VALUE_SELECT(`199409L', `ISO/IEC 9899:1990 AMD1')
-VALUE_SELECT(`199901L', `ISO/IEC 9899:1999')
-VALUE_SELECT(`201112L', `ISO/IEC 9899:2011')
-STDC(199409)
-*/
diff --git a/src/nonstd/_PREDEF/__STDC__.c b/src/nonstd/_PREDEF/__STDC__.c
deleted file mode 100644
index 5bcfe7aa..00000000
--- a/src/nonstd/_PREDEF/__STDC__.c
+++ /dev/null
@@ -1,14 +0,0 @@
-#define __STDC__ (1)
-
-/** standard C support **/
-
-/***
-is automatically defined by the compiler to indicate that it supports
-some version of ISO/IEC 9899.
-***/
-
-/*
-VALUE_TYPE(TYPE(int))
-VALUE_FIXED(1)
-STDC(1)
-*/
diff --git a/src/nonstd/_PREDEF/__TIME__.c b/src/nonstd/_PREDEF/__TIME__.c
deleted file mode 100644
index 472e42c0..00000000
--- a/src/nonstd/_PREDEF/__TIME__.c
+++ /dev/null
@@ -1,12 +0,0 @@
-#define __TIME__ /** time of compilation **/
-
-/***
-is automatically defined by the compiler as the time of compilation
-in the format DEFINITION("hh:mm:ss").
-***/
-
-/*
-VALUE_TYPE(string literal)
-VALUE_FIXED(VAR("time of compilation"))
-STDC(1)
-*/
diff --git a/src/nonstd/__libc_start.c b/src/nonstd/__libc_start.c
deleted file mode 100644
index d8fd5875..00000000
--- a/src/nonstd/__libc_start.c
+++ /dev/null
@@ -1,48 +0,0 @@
-#include "stdlib.h"
-#include "stdio.h"
-#include "locale.h"
-#include "../stdio/_stdio.h"
-
-#ifdef _POSIX_SOURCE
-#define DEFAULT_LOCALE "POSIX"
-#include "unistd.h"
-#else
-#define DEFAULT_LOCALE "C"
-#include "../_syscall.h"
-#include "../termios/NCCS.c"
-#include "../termios/cc_t.c"
-#include "../termios/tcflag_t.c"
-#include "../termios/struct_termios.c"
-static struct termios __tios;
-#define isatty(fd) (__syscall(__syscall_lookup(tcgetattr), fd, &__tios) == 0)
-#endif
-
-void __libc_start(int argc, char **argv)
-{
- extern int main(int, char*[]);
-
- stdin = __stdio.FILES + 0;
- stdin->fd = 0;
- /* freopen(", "r", stdin); */
- setvbuf(stdin, NULL, isatty(0) ? _IOLBF : _IOFBF, BUFSIZ);
-
- stdout = __stdio.FILES + 1;
- stdout->fd = 1;
- /* freopen(NULL, "w", stdout); */
- setvbuf(stdin, NULL, isatty(1) ? _IOLBF : _IOFBF, BUFSIZ);
-
- stderr = __stdio.FILES + 2;
- stderr->fd = 2;
- /* freopen(NULL, "w", stderr); */
- setvbuf(stderr, NULL, _IONBF, 0);
-
- stdin->next = stdout;
- stdout->next = stderr;
-
- stdout->prev = stdin;
- stderr->prev = stdout;
-
- /* setlocale(LC_ALL, DEFAULT_LOCALE); */
-
- exit(main(argc, argv));
-}
diff --git a/src/nonstd/x86-32.s b/src/nonstd/x86-32.s
deleted file mode 100644
index ad60201d..00000000
--- a/src/nonstd/x86-32.s
+++ /dev/null
@@ -1,18 +0,0 @@
-.global __syscall
-__syscall:
- mov 4(%esp), %eax
- mov 8(%esp), %ebx
- mov 12(%esp), %ecx
- mov 16(%esp), %edx
- mov 20(%esp), %esi
- mov 24(%esp), %edi
- mov 28(%esp), %ebp
- sysenter
- ret
-
-/* FIXME: this seems to be unpossible to put in a shared library */
-/* FIXME: it may be worthwhile to separate this into crt1.s */
-.global _start
-_start:
- /* TODO */
- call __libc_start
diff --git a/src/nonstd/x86-64.s b/src/nonstd/x86-64.s
deleted file mode 100644
index 87ff1637..00000000
--- a/src/nonstd/x86-64.s
+++ /dev/null
@@ -1,21 +0,0 @@
-.global __syscall
-__syscall:
- mov %rdi, %rax
- mov %rsi, %rdi
- mov %rdx, %rsi
- mov %rcx, %rdx
- mov %r8, %r10
- mov %r9, %r8
- mov 8(%rsp), %r9
- syscall
- ret
-
-.global _start
-_start:
- popq %rdi
- movq %rsp, %rsi
- call __libc_start
-
-.global __stack_chk_fail
-__stack_chk_fail:
- ret