summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gitignore1
-rw-r--r--package/base-files/Makefile4
-rw-r--r--target/config/Config.in1
-rw-r--r--target/config/Config.in.runtime3
-rw-r--r--target/m68k/Makefile8
-rw-r--r--target/m68k/aranym.cfg.in195
-rw-r--r--target/m68k/kernel/aranym-m68k8
-rw-r--r--toolchain/musl/Makefile6
-rw-r--r--toolchain/musl/Makefile.inc5
-rw-r--r--toolchain/musl/patches/musl-git-20140319.patch8864
10 files changed, 212 insertions, 8883 deletions
diff --git a/.gitignore b/.gitignore
index 55f82fdd7..b2a8d1a21 100644
--- a/.gitignore
+++ b/.gitignore
@@ -53,3 +53,4 @@
/target/config/Config.in.system
/target/config/Config.in.native
/target/config/Config.in.arch
+/target/m68k/aranym.cfg
diff --git a/package/base-files/Makefile b/package/base-files/Makefile
index 0dee1aa94..7c0a7f1a7 100644
--- a/package/base-files/Makefile
+++ b/package/base-files/Makefile
@@ -6,7 +6,7 @@ include $(TOPDIR)/mk/rootfs.mk
PKG_NAME:= base-files
PKG_VERSION:= 1.0
-PKG_RELEASE:= 74
+PKG_RELEASE:= 75
PKG_SECTION:= base
PKG_DESCR:= basic files and scripts
PKG_BUILDDEP:= pkgconf-host file-host
@@ -61,7 +61,7 @@ endif
cat ./files/inittab.vga >> $(IDIR_BASE_FILES)/etc/inittab
test -z $(ADK_RUNTIME_GETTY_SERIAL) || \
cat ./files/inittab.serial >> $(IDIR_BASE_FILES)/etc/inittab
- $(SED) 's#@DEVICE@#$(ADK_RUNTIME_CONSOLE_SERIAL_DEVICE)#' $(IDIR_BASE_FILES)/etc/inittab
+ $(SED) 's#@DEVICE@#$(ADK_RUNTIME_CONSOLE_SERIAL_DEVICE)#g' $(IDIR_BASE_FILES)/etc/inittab
$(SED) 's#@SPEED@#$(ADK_RUNTIME_CONSOLE_SERIAL_SPEED)#' $(IDIR_BASE_FILES)/etc/inittab
test -z $(ADK_RUNTIME_HOSTNAME) || \
echo $(ADK_RUNTIME_HOSTNAME) > $(IDIR_BASE_FILES)/etc/hostname; \
diff --git a/target/config/Config.in b/target/config/Config.in
index 05f495449..6125a2c81 100644
--- a/target/config/Config.in
+++ b/target/config/Config.in
@@ -747,7 +747,6 @@ config ADK_TARGET_ROOTFS_INITRAMFS
depends on !ADK_HARDWARE_VBOX
depends on !ADK_TARGET_SYSTEM_RASPBERRY_PI
select ADK_KERNEL_BLK_DEV_INITRD
- select ADK_KERNEL_BLK_DEV_RAM if ADK_TARGET_SYSTEM_ARANYM_M68K
help
create an read-only initramfs system.
diff --git a/target/config/Config.in.runtime b/target/config/Config.in.runtime
index 721f623de..7acdd26ed 100644
--- a/target/config/Config.in.runtime
+++ b/target/config/Config.in.runtime
@@ -59,6 +59,7 @@ config ADK_RUNTIME_GETTY_VGA
default y if ADK_TARGET_SYSTEM_RASPBERRY_PI
default y if ADK_TARGET_SYSTEM_LEMOTE_YEELONG
default y if ADK_TARGET_SYSTEM_IBM_X40
+ default y if ADK_TARGET_SYSTEM_ARANYM_M68K
default n
help
Start getty on VGA console. (tty1-tty6)
@@ -69,6 +70,7 @@ config ADK_RUNTIME_GETTY_SERIAL
default n if ADK_TARGET_SYSTEM_RASPBERRY_PI
default n if ADK_TARGET_SYSTEM_LEMOTE_YEELONG
default n if ADK_TARGET_SYSTEM_IBM_X40
+ default n if ADK_TARGET_SYSTEM_ARANYM_M68K
default y
help
Start getty on serial console.
@@ -80,7 +82,6 @@ config ADK_RUNTIME_CONSOLE_SERIAL_DEVICE
default "ttyAMA0" if ADK_TARGET_QEMU_ARM_MODEL_VERSATILEPB || ADK_TARGET_QEMU_ARM_MODEL_VEXPRESS_A9
default "ttySC1" if ADK_TARGET_SYSTEM_QEMU_SH4 || ADK_TARGET_SYSTEM_QEMU_SH4EB
default "ttymxc0" if ADK_TARGET_SYSTEM_CUBOX_I
- default "nfcon0" if ADK_TARGET_SYSTEM_ARANYM_M68K
default "ttyS0"
config ADK_RUNTIME_CONSOLE_SERIAL_SPEED
diff --git a/target/m68k/Makefile b/target/m68k/Makefile
index 0e7324c25..78206042c 100644
--- a/target/m68k/Makefile
+++ b/target/m68k/Makefile
@@ -26,6 +26,14 @@ imageinstall: $(FW_DIR)/$(INITRAMFS)
@cp $(KERNEL) $(FW_DIR)/$(TARGET_KERNEL)
@echo 'The kernel file is: $(FW_DIR)/${TARGET_KERNEL}'
@echo 'The initramfs image is: ${FW_DIR}/${INITRAMFS}'
+ifeq ($(ADK_TARGET_SYSTEM_ARANYM_M68K),y)
+ @sed -e "s#@@KERNEL@@#$(FW_DIR)/$(TARGET_KERNEL)#" \
+ -e "s#@@INITRAMFS@@#${FW_DIR}/${INITRAMFS}#" \
+ $(TOPDIR)/target/m68k/aranym.cfg.in \
+ > $(TOPDIR)/target/m68k/aranym.cfg
+ @echo 'Start aranym with: aranym-mmu -l -c target/m68k/aranym.cfg'
+ @echo 'Ungrab mouse with middle mouse click'
+endif
endif
ifeq ($(ADK_TARGET_FS),initramfs-piggyback)
imageinstall: createinitramfs
diff --git a/target/m68k/aranym.cfg.in b/target/m68k/aranym.cfg.in
new file mode 100644
index 000000000..a2fd30170
--- /dev/null
+++ b/target/m68k/aranym.cfg.in
@@ -0,0 +1,195 @@
+[GLOBAL]
+FastRAM = 32
+Floppy =
+TOS = ROM
+EmuTOS = etos512k.img
+Bootstrap = mintara.prg
+BootstrapArgs =
+BootDrive =
+GMTime = No
+
+[STARTUP]
+GrabMouse = No
+Debugger = No
+
+[IKBD]
+WheelEiffel = No
+AltGr = Yes
+
+[HOTKEYS]
+Setup = 19:0
+Quit = 19:0x1
+Reboot = 19:0x40
+Ungrab = 27:0x141
+Debug = 19:0x100
+Screenshot = 316:0
+Fullscreen = 302:0
+
+[JIT]
+JIT = Yes
+JITFPU = Yes
+JITCacheSize = 8192
+JITLazyFlush = 1
+JITBlackList =
+JITInline = No
+
+[VIDEO]
+FullScreen = No
+BootColorDepth = -1
+VidelRefresh = 2
+VidelMonitor = -1
+SingleBlitComposing = No
+SingleBlitRefresh = No
+
+[TOS]
+Cookie_MCH = 50000
+RedirConsole = No
+
+[IDE0]
+Present = No
+IsCDROM = No
+ByteSwap = No
+ReadOnly = No
+Path =
+Cylinders = 0
+Heads = 0
+SectorsPerTrack = 0
+ModelName = Master
+
+[IDE1]
+Present = No
+IsCDROM = No
+ByteSwap = No
+ReadOnly = No
+Path =
+Cylinders = 0
+Heads = 0
+SectorsPerTrack = 0
+ModelName = Slave
+
+[PARTITION0]
+Path =
+Present = No
+PartID = BGM
+ByteSwap = No
+ReadOnly = No
+
+[HOSTFS]
+A =
+B =
+C =
+D =
+E =
+F =
+G =
+H =
+I =
+J =
+K =
+L =
+M =
+N =
+O =
+P =
+Q =
+R =
+S =
+T =
+U =
+V =
+W =
+X =
+Y =
+Z =
+
+[OPENGL]
+Enabled = No
+Filtered = No
+Library =
+
+[ETH0]
+Type = bridge
+Tunnel = tap0
+HostIP = 172.24.30.12
+AtariIP = 172.24.42.46
+Netmask = 255.255.0.0
+MAC = 00:41:45:54:48:30
+
+[LILO]
+Kernel = @@KERNEL@@
+Args = console=tty debug=par
+Ramdisk = @@INITRAMFS@@
+
+[MIDI]
+Type = none
+File =
+Sequencer = /dev/sequencer
+
+[CDROMS]
+A = -1
+B = -1
+C = -1
+D = -1
+E = -1
+F = -1
+G = -1
+H = -1
+I = -1
+J = -1
+K = -1
+L = -1
+M = -1
+N = -1
+O = -1
+P = -1
+Q = -1
+R = -1
+S = -1
+T = -1
+U = -1
+V = -1
+W = -1
+X = -1
+Y = -1
+Z = -1
+
+[AUTOZOOM]
+Enabled = No
+IntegerCoefs = No
+FixedSize = No
+Width = 640
+Height = 480
+
+[NFOSMESA]
+ChannelSize = 0
+LibGL = libGL.so
+LibOSMesa = libOSMesa.so
+
+[PARALLEL]
+Type = file
+File = stderr
+Parport = /dev/parport0
+
+[SERIAL]
+Serport = /dev/ttyS0
+
+[NATFEATS]
+CDROM = sdl
+Vdi = soft
+
+[NFVDI]
+UseHostMouseCursor = No
+
+[AUDIO]
+Frequency = 22050
+Channels = 2
+Bits = 16
+Samples = 1024
+
+[JOYSTICKS]
+Ikbd0 = -1
+Ikbd1 = 0
+JoypadA = -1
+JoypadAButtons = 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
+JoypadB = -1
+JoypadBButtons = 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
diff --git a/target/m68k/kernel/aranym-m68k b/target/m68k/kernel/aranym-m68k
index 93bf0022f..ac513fdc6 100644
--- a/target/m68k/kernel/aranym-m68k
+++ b/target/m68k/kernel/aranym-m68k
@@ -4,12 +4,8 @@ CONFIG_M68KCLASSIC=y
CONFIG_M68040=y
CONFIG_FPU=y
CONFIG_ATARI=y
-CONFIG_NET_VENDOR_AMD=y
-CONFIG_NET_CADENCE=y
+CONFIG_NATFEAT=y
+CONFIG_NFETH=y
CONFIG_SERIO=y
CONFIG_SERIO_SERPORT=y
CONFIG_SERIO_LIBPS2=y
-CONFIG_SERIAL_8250=y
-CONFIG_SERIAL_8250_CONSOLE=y
-CONFIG_SERIAL_8250_NR_UARTS=4
-CONFIG_SERIAL_8250_RUNTIME_UARTS=4
diff --git a/toolchain/musl/Makefile b/toolchain/musl/Makefile
index f13a2613d..6701c502a 100644
--- a/toolchain/musl/Makefile
+++ b/toolchain/musl/Makefile
@@ -9,12 +9,6 @@ include ${TOPDIR}/mk/buildhlp.mk
ifeq ($(CPU_ARCH),ppc)
GNU_TARGET_NAME:= $(subst ppc,powerpc,$(GNU_TARGET_NAME))
endif
-ifeq ($(CPU_ARCH),mips64el)
-GNU_TARGET_NAME:= $(subst mips64el,mips,$(GNU_TARGET_NAME))
-endif
-ifeq ($(CPU_ARCH),mips64)
-GNU_TARGET_NAME:= $(subst mips64,mips,$(GNU_TARGET_NAME))
-endif
$(WRKBUILD)/.headers:
(cd $(WRKBUILD); CC='$(TARGET_CC)' CROSS_COMPILE='$(TARGET_CROSS)' \
diff --git a/toolchain/musl/Makefile.inc b/toolchain/musl/Makefile.inc
index 506280532..40cf4fcf0 100644
--- a/toolchain/musl/Makefile.inc
+++ b/toolchain/musl/Makefile.inc
@@ -2,8 +2,7 @@
# material, please see the LICENCE file in the top-level directory.
PKG_NAME:= musl
-PKG_VERSION:= 0.9.15
+PKG_VERSION:= 1.0.0
PKG_RELEASE:= 1
-PKG_MD5SUM:= 06f590a38c85722ee9343db2416425f4
+PKG_MD5SUM:= e54664fdf211d27737e328c4462b545e
PKG_SITES:= http://www.musl-libc.org/releases/
-DISTFILES:= $(PKG_NAME)-$(PKG_VERSION).tar.gz
diff --git a/toolchain/musl/patches/musl-git-20140319.patch b/toolchain/musl/patches/musl-git-20140319.patch
deleted file mode 100644
index f319d904a..000000000
--- a/toolchain/musl/patches/musl-git-20140319.patch
+++ /dev/null
@@ -1,8864 +0,0 @@
-diff -Nur musl-0.9.15/arch/arm/bits/sem.h musl-git/arch/arm/bits/sem.h
---- musl-0.9.15/arch/arm/bits/sem.h 1970-01-01 01:00:00.000000000 +0100
-+++ musl-git/arch/arm/bits/sem.h 2014-03-19 07:42:48.000000000 +0100
-@@ -0,0 +1,16 @@
-+struct semid_ds {
-+ struct ipc_perm sem_perm;
-+ time_t sem_otime;
-+ time_t __unused1;
-+ time_t sem_ctime;
-+ time_t __unused2;
-+#if __BYTE_ORDER == __LITTLE_ENDIAN
-+ unsigned short sem_nsems;
-+ char __sem_nsems_pad[sizeof(time_t)-sizeof(short)];
-+#else
-+ char __sem_nsems_pad[sizeof(time_t)-sizeof(short)];
-+ unsigned short sem_nsems;
-+#endif
-+ time_t __unused3;
-+ time_t __unused4;
-+};
-diff -Nur musl-0.9.15/arch/arm/bits/shm.h musl-git/arch/arm/bits/shm.h
---- musl-0.9.15/arch/arm/bits/shm.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/arm/bits/shm.h 2014-03-19 07:42:48.000000000 +0100
-@@ -16,3 +16,14 @@
- unsigned long __pad1;
- unsigned long __pad2;
- };
-+
-+struct shminfo {
-+ unsigned long shmmax, shmmin, shmmni, shmseg, shmall, __unused[4];
-+};
-+
-+struct shm_info {
-+ int __used_ids;
-+ unsigned long shm_tot, shm_rss, shm_swp;
-+ unsigned long __swap_attempts, __swap_successes;
-+};
-+
-diff -Nur musl-0.9.15/arch/arm/bits/signal.h musl-git/arch/arm/bits/signal.h
---- musl-0.9.15/arch/arm/bits/signal.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/arm/bits/signal.h 2014-03-19 07:42:48.000000000 +0100
-@@ -18,6 +18,12 @@
- } mcontext_t;
- #endif
-
-+struct sigaltstack {
-+ void *ss_sp;
-+ int ss_flags;
-+ size_t ss_size;
-+};
-+
- typedef struct __ucontext {
- unsigned long uc_flags;
- struct __ucontext *uc_link;
-diff -Nur musl-0.9.15/arch/arm/bits/termios.h musl-git/arch/arm/bits/termios.h
---- musl-0.9.15/arch/arm/bits/termios.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/arm/bits/termios.h 2014-03-19 07:42:48.000000000 +0100
-@@ -42,6 +42,7 @@
- #define IXANY 0004000
- #define IXOFF 0010000
- #define IMAXBEL 0020000
-+#define IUTF8 0040000
-
- #define OPOST 0000001
- #define OLCUC 0000002
-@@ -75,9 +76,6 @@
- #define VT0 0000000
- #define VT1 0040000
-
--/* ?? */
--#define XTABS 0014000
--
- #define B0 0000000
- #define B50 0000001
- #define B75 0000002
-@@ -125,8 +123,6 @@
- #define HUPCL 0002000
- #define CLOCAL 0004000
-
--#define CRTSCTS 020000000000
--
- #define ISIG 0000001
- #define ICANON 0000002
- #define ECHO 0000010
-@@ -137,14 +133,11 @@
- #define TOSTOP 0000400
- #define IEXTEN 0100000
-
--/* Extensions? */
--#define CBAUDEX 0010000
- #define ECHOCTL 0001000
- #define ECHOPRT 0002000
- #define ECHOKE 0004000
- #define FLUSHO 0010000
- #define PENDIN 0040000
--#define EXTPROC 0200000
-
- #define TCOOFF 0
- #define TCOON 1
-@@ -158,3 +151,10 @@
- #define TCSANOW 0
- #define TCSADRAIN 1
- #define TCSAFLUSH 2
-+
-+#if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
-+#define CBAUDEX 0010000
-+#define CRTSCTS 020000000000
-+#define EXTPROC 0200000
-+#define XTABS 0014000
-+#endif
-diff -Nur musl-0.9.15/arch/arm/syscall_arch.h musl-git/arch/arm/syscall_arch.h
---- musl-0.9.15/arch/arm/syscall_arch.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/arm/syscall_arch.h 2014-03-19 07:42:48.000000000 +0100
-@@ -3,6 +3,8 @@
- ((union { long long ll; long l[2]; }){ .ll = x }).l[1]
- #define __SYSCALL_LL_O(x) 0, __SYSCALL_LL_E((x))
-
-+long (__syscall)(long, ...);
-+
- #ifndef __clang__
-
- #define __asm_syscall(...) do { \
-diff -Nur musl-0.9.15/arch/i386/bits/sem.h musl-git/arch/i386/bits/sem.h
---- musl-0.9.15/arch/i386/bits/sem.h 1970-01-01 01:00:00.000000000 +0100
-+++ musl-git/arch/i386/bits/sem.h 2014-03-19 07:42:48.000000000 +0100
-@@ -0,0 +1,16 @@
-+struct semid_ds {
-+ struct ipc_perm sem_perm;
-+ time_t sem_otime;
-+ time_t __unused1;
-+ time_t sem_ctime;
-+ time_t __unused2;
-+#if __BYTE_ORDER == __LITTLE_ENDIAN
-+ unsigned short sem_nsems;
-+ char __sem_nsems_pad[sizeof(time_t)-sizeof(short)];
-+#else
-+ char __sem_nsems_pad[sizeof(time_t)-sizeof(short)];
-+ unsigned short sem_nsems;
-+#endif
-+ time_t __unused3;
-+ time_t __unused4;
-+};
-diff -Nur musl-0.9.15/arch/i386/bits/shm.h musl-git/arch/i386/bits/shm.h
---- musl-0.9.15/arch/i386/bits/shm.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/i386/bits/shm.h 2014-03-19 07:42:48.000000000 +0100
-@@ -16,3 +16,14 @@
- unsigned long __pad1;
- unsigned long __pad2;
- };
-+
-+struct shminfo {
-+ unsigned long shmmax, shmmin, shmmni, shmseg, shmall, __unused[4];
-+};
-+
-+struct shm_info {
-+ int __used_ids;
-+ unsigned long shm_tot, shm_rss, shm_swp;
-+ unsigned long __swap_attempts, __swap_successes;
-+};
-+
-diff -Nur musl-0.9.15/arch/i386/bits/signal.h musl-git/arch/i386/bits/signal.h
---- musl-0.9.15/arch/i386/bits/signal.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/i386/bits/signal.h 2014-03-19 07:42:48.000000000 +0100
-@@ -53,6 +53,12 @@
- } mcontext_t;
- #endif
-
-+struct sigaltstack {
-+ void *ss_sp;
-+ int ss_flags;
-+ size_t ss_size;
-+};
-+
- typedef struct __ucontext {
- unsigned long uc_flags;
- struct __ucontext *uc_link;
-diff -Nur musl-0.9.15/arch/i386/bits/termios.h musl-git/arch/i386/bits/termios.h
---- musl-0.9.15/arch/i386/bits/termios.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/i386/bits/termios.h 2014-03-19 07:42:48.000000000 +0100
-@@ -42,6 +42,7 @@
- #define IXANY 0004000
- #define IXOFF 0010000
- #define IMAXBEL 0020000
-+#define IUTF8 0040000
-
- #define OPOST 0000001
- #define OLCUC 0000002
-@@ -75,9 +76,6 @@
- #define VT0 0000000
- #define VT1 0040000
-
--/* ?? */
--#define XTABS 0014000
--
- #define B0 0000000
- #define B50 0000001
- #define B75 0000002
-@@ -125,8 +123,6 @@
- #define HUPCL 0002000
- #define CLOCAL 0004000
-
--#define CRTSCTS 020000000000
--
- #define ISIG 0000001
- #define ICANON 0000002
- #define ECHO 0000010
-@@ -137,14 +133,11 @@
- #define TOSTOP 0000400
- #define IEXTEN 0100000
-
--/* Extensions? */
--#define CBAUDEX 0010000
- #define ECHOCTL 0001000
- #define ECHOPRT 0002000
- #define ECHOKE 0004000
- #define FLUSHO 0010000
- #define PENDIN 0040000
--#define EXTPROC 0200000
-
- #define TCOOFF 0
- #define TCOON 1
-@@ -158,3 +151,10 @@
- #define TCSANOW 0
- #define TCSADRAIN 1
- #define TCSAFLUSH 2
-+
-+#if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
-+#define CBAUDEX 0010000
-+#define CRTSCTS 020000000000
-+#define EXTPROC 0200000
-+#define XTABS 0014000
-+#endif
-diff -Nur musl-0.9.15/arch/microblaze/bits/sem.h musl-git/arch/microblaze/bits/sem.h
---- musl-0.9.15/arch/microblaze/bits/sem.h 1970-01-01 01:00:00.000000000 +0100
-+++ musl-git/arch/microblaze/bits/sem.h 2014-03-19 07:42:48.000000000 +0100
-@@ -0,0 +1,16 @@
-+struct semid_ds {
-+ struct ipc_perm sem_perm;
-+ time_t sem_otime;
-+ time_t __unused1;
-+ time_t sem_ctime;
-+ time_t __unused2;
-+#if __BYTE_ORDER == __LITTLE_ENDIAN
-+ unsigned short sem_nsems;
-+ char __sem_nsems_pad[sizeof(time_t)-sizeof(short)];
-+#else
-+ char __sem_nsems_pad[sizeof(time_t)-sizeof(short)];
-+ unsigned short sem_nsems;
-+#endif
-+ time_t __unused3;
-+ time_t __unused4;
-+};
-diff -Nur musl-0.9.15/arch/microblaze/bits/shm.h musl-git/arch/microblaze/bits/shm.h
---- musl-0.9.15/arch/microblaze/bits/shm.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/microblaze/bits/shm.h 2014-03-19 07:42:48.000000000 +0100
-@@ -16,3 +16,14 @@
- unsigned long __pad1;
- unsigned long __pad2;
- };
-+
-+struct shminfo {
-+ unsigned long shmmax, shmmin, shmmni, shmseg, shmall, __unused[4];
-+};
-+
-+struct shm_info {
-+ int __used_ids;
-+ unsigned long shm_tot, shm_rss, shm_swp;
-+ unsigned long __swap_attempts, __swap_successes;
-+};
-+
-diff -Nur musl-0.9.15/arch/microblaze/bits/signal.h musl-git/arch/microblaze/bits/signal.h
---- musl-0.9.15/arch/microblaze/bits/signal.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/microblaze/bits/signal.h 2014-03-19 07:42:48.000000000 +0100
-@@ -21,6 +21,12 @@
- } mcontext_t;
- #endif
-
-+struct sigaltstack {
-+ void *ss_sp;
-+ int ss_flags;
-+ size_t ss_size;
-+};
-+
- typedef struct __ucontext {
- unsigned long uc_flags;
- struct __ucontext *uc_link;
-diff -Nur musl-0.9.15/arch/microblaze/bits/termios.h musl-git/arch/microblaze/bits/termios.h
---- musl-0.9.15/arch/microblaze/bits/termios.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/microblaze/bits/termios.h 2014-03-19 07:42:48.000000000 +0100
-@@ -42,6 +42,7 @@
- #define IXANY 0004000
- #define IXOFF 0010000
- #define IMAXBEL 0020000
-+#define IUTF8 0040000
-
- #define OPOST 0000001
- #define OLCUC 0000002
-@@ -75,9 +76,6 @@
- #define VT0 0000000
- #define VT1 0040000
-
--/* ?? */
--#define XTABS 0014000
--
- #define B0 0000000
- #define B50 0000001
- #define B75 0000002
-@@ -125,8 +123,6 @@
- #define HUPCL 0002000
- #define CLOCAL 0004000
-
--#define CRTSCTS 020000000000
--
- #define ISIG 0000001
- #define ICANON 0000002
- #define ECHO 0000010
-@@ -137,14 +133,11 @@
- #define TOSTOP 0000400
- #define IEXTEN 0100000
-
--/* Extensions? */
--#define CBAUDEX 0010000
- #define ECHOCTL 0001000
- #define ECHOPRT 0002000
- #define ECHOKE 0004000
- #define FLUSHO 0010000
- #define PENDIN 0040000
--#define EXTPROC 0200000
-
- #define TCOOFF 0
- #define TCOON 1
-@@ -158,3 +151,10 @@
- #define TCSANOW 0
- #define TCSADRAIN 1
- #define TCSAFLUSH 2
-+
-+#if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
-+#define CBAUDEX 0010000
-+#define CRTSCTS 020000000000
-+#define EXTPROC 0200000
-+#define XTABS 0014000
-+#endif
-diff -Nur musl-0.9.15/arch/microblaze/syscall_arch.h musl-git/arch/microblaze/syscall_arch.h
---- musl-0.9.15/arch/microblaze/syscall_arch.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/microblaze/syscall_arch.h 2014-03-19 07:42:48.000000000 +0100
-@@ -3,6 +3,8 @@
- ((union { long long ll; long l[2]; }){ .ll = x }).l[1]
- #define __SYSCALL_LL_O(x) 0, __SYSCALL_LL_E((x))
-
-+long (__syscall)(long, ...);
-+
- #ifndef __clang__
-
- static __inline long __syscall0(long n)
-diff -Nur musl-0.9.15/arch/mips/bits/fenv.h musl-git/arch/mips/bits/fenv.h
---- musl-0.9.15/arch/mips/bits/fenv.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/mips/bits/fenv.h 2014-03-19 07:42:48.000000000 +0100
-@@ -1,3 +1,7 @@
-+#ifdef __mips_soft_float
-+#define FE_ALL_EXCEPT 0
-+#define FE_TONEAREST 0
-+#else
- #define FE_INEXACT 4
- #define FE_UNDERFLOW 8
- #define FE_OVERFLOW 16
-@@ -10,6 +14,7 @@
- #define FE_TOWARDZERO 1
- #define FE_UPWARD 2
- #define FE_DOWNWARD 3
-+#endif
-
- typedef unsigned short fexcept_t;
-
-diff -Nur musl-0.9.15/arch/mips/bits/sem.h musl-git/arch/mips/bits/sem.h
---- musl-0.9.15/arch/mips/bits/sem.h 1970-01-01 01:00:00.000000000 +0100
-+++ musl-git/arch/mips/bits/sem.h 2014-03-19 07:42:48.000000000 +0100
-@@ -0,0 +1,14 @@
-+struct semid_ds {
-+ struct ipc_perm sem_perm;
-+ time_t sem_otime;
-+ time_t sem_ctime;
-+#if __BYTE_ORDER == __LITTLE_ENDIAN
-+ unsigned short sem_nsems;
-+ char __sem_nsems_pad[sizeof(time_t)-sizeof(short)];
-+#else
-+ char __sem_nsems_pad[sizeof(time_t)-sizeof(short)];
-+ unsigned short sem_nsems;
-+#endif
-+ time_t __unused3;
-+ time_t __unused4;
-+};
-diff -Nur musl-0.9.15/arch/mips/bits/setjmp.h musl-git/arch/mips/bits/setjmp.h
---- musl-0.9.15/arch/mips/bits/setjmp.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/mips/bits/setjmp.h 2014-03-19 07:42:48.000000000 +0100
-@@ -1 +1 @@
--typedef unsigned long long __jmp_buf[15];
-+typedef unsigned long long __jmp_buf[13];
-diff -Nur musl-0.9.15/arch/mips/bits/shm.h musl-git/arch/mips/bits/shm.h
---- musl-0.9.15/arch/mips/bits/shm.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/mips/bits/shm.h 2014-03-19 07:42:48.000000000 +0100
-@@ -13,3 +13,14 @@
- unsigned long __pad1;
- unsigned long __pad2;
- };
-+
-+struct shminfo {
-+ unsigned long shmmax, shmmin, shmmni, shmseg, shmall, __unused[4];
-+};
-+
-+struct shm_info {
-+ int __used_ids;
-+ unsigned long shm_tot, shm_rss, shm_swp;
-+ unsigned long __swap_attempts, __swap_successes;
-+};
-+
-diff -Nur musl-0.9.15/arch/mips/bits/signal.h musl-git/arch/mips/bits/signal.h
---- musl-0.9.15/arch/mips/bits/signal.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/mips/bits/signal.h 2014-03-19 07:42:48.000000000 +0100
-@@ -38,13 +38,18 @@
- } mcontext_t;
- #endif
-
-+struct sigaltstack {
-+ void *ss_sp;
-+ size_t ss_size;
-+ int ss_flags;
-+};
-+
- typedef struct __ucontext {
- unsigned long uc_flags;
- struct __ucontext *uc_link;
- stack_t uc_stack;
- mcontext_t uc_mcontext;
- sigset_t uc_sigmask;
-- unsigned long uc_regspace[128];
- } ucontext_t;
-
- #define SA_NOCLDSTOP 1
-diff -Nur musl-0.9.15/arch/mips/bits/statfs.h musl-git/arch/mips/bits/statfs.h
---- musl-0.9.15/arch/mips/bits/statfs.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/mips/bits/statfs.h 2014-03-19 07:42:48.000000000 +0100
-@@ -1,7 +1,8 @@
- struct statfs {
-- unsigned long f_type, f_bsize;
-- fsblkcnt_t f_blocks, f_bfree, f_bavail;
-+ unsigned long f_type, f_bsize, f_frsize;
-+ fsblkcnt_t f_blocks, f_bfree;
- fsfilcnt_t f_files, f_ffree;
-+ fsblkcnt_t f_bavail;
- fsid_t f_fsid;
-- unsigned long f_namelen, f_frsize, f_flags, f_spare[4];
-+ unsigned long f_namelen, f_flags, f_spare[5];
- };
-diff -Nur musl-0.9.15/arch/mips/bits/termios.h musl-git/arch/mips/bits/termios.h
---- musl-0.9.15/arch/mips/bits/termios.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/mips/bits/termios.h 2014-03-19 07:42:48.000000000 +0100
-@@ -77,9 +77,6 @@
- #define VT0 0000000
- #define VT1 0040000
-
--/* ?? */
--#define XTABS 0014000
--
- #define B0 0000000
- #define B50 0000001
- #define B75 0000002
-@@ -129,12 +126,6 @@
- #define PARODD 0001000
- #define HUPCL 0002000
- #define CLOCAL 0004000
--#define CBAUDEX 0010000
--
--#define CIBAUD 002003600000
--#define CMSPAR 010000000000
--#define CRTSCTS 020000000000
--#define IBSHIFT 16
-
- #define ISIG 0000001
- #define ICANON 0000002
-@@ -152,9 +143,6 @@
- #define PENDIN 0040000
- #define TOSTOP 0100000
- #define ITOSTOP 0100000
--#define EXTPROC 0200000
--
--#define TIOCSER_TEMT 1
-
- #define TCOOFF 0
- #define TCOON 1
-@@ -168,3 +156,14 @@
- #define TCSANOW 0
- #define TCSADRAIN 1
- #define TCSAFLUSH 2
-+
-+#if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
-+#define CBAUDEX 0010000
-+#define CIBAUD 002003600000
-+#define IBSHIFT 16
-+#define CMSPAR 010000000000
-+#define CRTSCTS 020000000000
-+#define EXTPROC 0200000
-+#define XTABS 0014000
-+#define TIOCSER_TEMT 1
-+#endif
-diff -Nur musl-0.9.15/arch/mips/reloc.h musl-git/arch/mips/reloc.h
---- musl-0.9.15/arch/mips/reloc.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/mips/reloc.h 2014-03-19 07:42:48.000000000 +0100
-@@ -8,7 +8,13 @@
- #define ENDIAN_SUFFIX ""
- #endif
-
--#define LDSO_ARCH "mips" ENDIAN_SUFFIX
-+#ifdef __mips_soft_float
-+#define FP_SUFFIX "-sf"
-+#else
-+#define FP_SUFFIX ""
-+#endif
-+
-+#define LDSO_ARCH "mips" ENDIAN_SUFFIX FP_SUFFIX
-
- #define IS_COPY(x) ((x)==R_MIPS_COPY)
- #define IS_PLT(x) 1
-diff -Nur musl-0.9.15/arch/mips/syscall_arch.h musl-git/arch/mips/syscall_arch.h
---- musl-0.9.15/arch/mips/syscall_arch.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/mips/syscall_arch.h 2014-03-19 07:42:48.000000000 +0100
-@@ -3,6 +3,8 @@
- ((union { long long ll; long l[2]; }){ .ll = x }).l[1]
- #define __SYSCALL_LL_O(x) 0, __SYSCALL_LL_E((x))
-
-+long (__syscall)(long, ...);
-+
- #ifndef __clang__
-
- #define __asm_syscall(...) do { \
-diff -Nur musl-0.9.15/arch/powerpc/bits/ipc.h musl-git/arch/powerpc/bits/ipc.h
---- musl-0.9.15/arch/powerpc/bits/ipc.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/powerpc/bits/ipc.h 2014-03-19 07:42:48.000000000 +0100
-@@ -7,8 +7,9 @@
- gid_t cgid;
- mode_t mode;
- int __ipc_perm_seq;
-- long __pad1;
-- long __pad2;
-+ int __pad1;
-+ long long __pad2;
-+ long long __pad3;
- };
-
- #define IPC_64 0x100
-diff -Nur musl-0.9.15/arch/powerpc/bits/msg.h musl-git/arch/powerpc/bits/msg.h
---- musl-0.9.15/arch/powerpc/bits/msg.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/powerpc/bits/msg.h 2014-03-19 07:42:48.000000000 +0100
-@@ -1,12 +1,12 @@
- struct msqid_ds
- {
- struct ipc_perm msg_perm;
-- time_t msg_stime;
- int __unused1;
-- time_t msg_rtime;
-+ time_t msg_stime;
- int __unused2;
-- time_t msg_ctime;
-+ time_t msg_rtime;
- int __unused3;
-+ time_t msg_ctime;
- unsigned long msg_cbytes;
- msgqnum_t msg_qnum;
- msglen_t msg_qbytes;
-diff -Nur musl-0.9.15/arch/powerpc/bits/sem.h musl-git/arch/powerpc/bits/sem.h
---- musl-0.9.15/arch/powerpc/bits/sem.h 1970-01-01 01:00:00.000000000 +0100
-+++ musl-git/arch/powerpc/bits/sem.h 2014-03-19 07:42:48.000000000 +0100
-@@ -0,0 +1,10 @@
-+struct semid_ds {
-+ struct ipc_perm sem_perm;
-+ int __unused1;
-+ time_t sem_otime;
-+ int __unused2;
-+ time_t sem_ctime;
-+ unsigned short __sem_nsems_pad, sem_nsems;
-+ long __unused3;
-+ long __unused4;
-+};
-diff -Nur musl-0.9.15/arch/powerpc/bits/shm.h musl-git/arch/powerpc/bits/shm.h
---- musl-0.9.15/arch/powerpc/bits/shm.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/powerpc/bits/shm.h 2014-03-19 07:42:48.000000000 +0100
-@@ -3,16 +3,28 @@
- struct shmid_ds
- {
- struct ipc_perm shm_perm;
-- size_t shm_segsz;
-- time_t shm_atime;
- int __unused1;
-- time_t shm_dtime;
-+ time_t shm_atime;
- int __unused2;
-- time_t shm_ctime;
-+ time_t shm_dtime;
- int __unused3;
-+ time_t shm_ctime;
-+ int __unused4;
-+ size_t shm_segsz;
- pid_t shm_cpid;
- pid_t shm_lpid;
- unsigned long shm_nattch;
- unsigned long __pad1;
- unsigned long __pad2;
- };
-+
-+struct shminfo {
-+ unsigned long shmmax, shmmin, shmmni, shmseg, shmall, __unused[4];
-+};
-+
-+struct shm_info {
-+ int __used_ids;
-+ unsigned long shm_tot, shm_rss, shm_swp;
-+ unsigned long __swap_attempts, __swap_successes;
-+};
-+
-diff -Nur musl-0.9.15/arch/powerpc/bits/signal.h musl-git/arch/powerpc/bits/signal.h
---- musl-0.9.15/arch/powerpc/bits/signal.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/powerpc/bits/signal.h 2014-03-19 07:42:48.000000000 +0100
-@@ -49,6 +49,12 @@
-
- #endif
-
-+struct sigaltstack {
-+ void *ss_sp;
-+ int ss_flags;
-+ size_t ss_size;
-+};
-+
- typedef struct __ucontext {
- unsigned long uc_flags;
- struct __ucontext *uc_link;
-diff -Nur musl-0.9.15/arch/powerpc/bits/socket.h musl-git/arch/powerpc/bits/socket.h
---- musl-0.9.15/arch/powerpc/bits/socket.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/powerpc/bits/socket.h 2014-03-19 07:42:48.000000000 +0100
-@@ -1,12 +1,12 @@
- struct msghdr
- {
- void *msg_name;
-- int msg_namelen;
-+ socklen_t msg_namelen;
- struct iovec *msg_iov;
-- unsigned long msg_iovlen;
-+ int msg_iovlen;
- void *msg_control;
-- unsigned long msg_controllen;
-- unsigned msg_flags;
-+ socklen_t msg_controllen;
-+ int msg_flags;
- };
-
- struct cmsghdr
-diff -Nur musl-0.9.15/arch/powerpc/bits/termios.h musl-git/arch/powerpc/bits/termios.h
---- musl-0.9.15/arch/powerpc/bits/termios.h 2014-01-03 21:12:17.000000000 +0100
-+++ musl-git/arch/powerpc/bits/termios.h 2014-03-19 07:42:48.000000000 +0100
-@@ -66,7 +66,6 @@
- #define TAB1 00002000
- #define TAB2 00004000
- #define TAB3 00006000
--#define XTABS 00006000
- #define CRDLY 00030000
- #define CR0 00000000
- #define CR1 00010000
-@@ -101,7 +100,6 @@
- #define B38400 0000017
- #define EXTA B19200
- #define EXTB B38400
--#define CBAUDEX 0000000
- #define B57600 00020
- #define B115200 00021
- #define B230400 00022
-@@ -120,9 +118,6 @@
- #define B4000000 00036
- #define BOTHER 00037
-
--#define CIBAUD 077600000
--#define IBSHIFT 16
--
- #define CSIZE 00001400
- #define CS5 00000000
- #define CS6 00000400
-@@ -136,8 +131,6 @@
- #define HUPCL 00040000
-
- #define CLOCAL 00100000
--#define CMSPAR 010000000000
--#define CRTSCTS 020000000000
-
- #define ISIG 0x00000080
- #define ICANON 0x00000100
-@@ -154,7 +147,6 @@
- #define FLUSHO 0x00800000
- #define PENDIN 0x20000000
- #define IEXTEN 0x00000400
--#define EXTPROC 0x10000000
-
- #define TCOOFF 0
- #define TCOON 1
-@@ -168,3 +160,13 @@
- #define TCSANOW 0
- #define TCSADRAIN 1
- #define TCSAFLUSH 2
-+
-+#if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
-+#define CBAUDEX 0000000
-+#define CIBAUD 077600000
-+#define IBSHIFT 16
-+#define CMSPAR 010000000000
-+#define CRTSCTS 020000000000
-+#define EXTPROC 0x10000000
-+#define XTABS 00006000
-+#endif
-diff -Nur musl-0.9.15/arch/sh/atomic.h musl-git/arch/sh/atomic.h
---- musl-0.9.15/arch/sh/atomic.h 1970-01-01 01:00:00.000000000 +0100
-+++ musl-git/arch/sh/atomic.h 2014-03-19 07:42:48.000000000 +0100
-@@ -0,0 +1,87 @@
-+#ifndef _INTERNAL_ATOMIC_H
-+#define _INTERNAL_ATOMIC_H
-+
-+#include <stdint.h>
-+
-+static inline int a_ctz_l(unsigned long x)
-+{
-+ static const char debruijn32[32] = {
-+ 0, 1, 23, 2, 29, 24, 19, 3, 30, 27, 25, 11, 20, 8, 4, 13,
-+ 31, 22, 28, 18, 26, 10, 7, 12, 21, 17, 9, 6, 16, 5, 15, 14
-+ };
-+ return debruijn32[(x&-x)*0x076be629 >> 27];
-+}
-+
-+static inline int a_ctz_64(uint64_t x)
-+{
-+ uint32_t y = x;
-+ if (!y) {
-+ y = x>>32;
-+ return 32 + a_ctz_l(y);
-+ }
-+ return a_ctz_l(y);
-+}
-+
-+int __sh_cas(volatile int *, int, int);
-+int __sh_swap(volatile int *, int);
-+int __sh_fetch_add(volatile int *, int);
-+void __sh_store(volatile int *, int);
-+void __sh_and(volatile int *, int);
-+void __sh_or(volatile int *, int);
-+
-+#define a_cas(p,t,s) __sh_cas(p,t,s)
-+#define a_swap(x,v) __sh_swap(x,v)
-+#define a_fetch_add(x,v) __sh_fetch_add(x, v)
-+#define a_store(x,v) __sh_store(x, v)
-+#define a_and(x,v) __sh_and(x, v)
-+#define a_or(x,v) __sh_or(x, v)
-+
-+static inline void *a_cas_p(volatile void *p, void *t, void *s)
-+{
-+ return (void *)a_cas(p, (int)t, (int)s);
-+}
-+
-+static inline long a_cas_l(volatile void *p, long t, long s)
-+{
-+ return a_cas(p, t, s);
-+}
-+
-+static inline void a_inc(volatile int *x)
-+{
-+ a_fetch_add(x, 1);
-+}
-+
-+static inline void a_dec(volatile int *x)
-+{
-+ a_fetch_add(x, -1);
-+}
-+
-+static inline void a_spin()
-+{
-+}
-+
-+static inline void a_crash()
-+{
-+ *(volatile char *)0=0;
-+}
-+
-+static inline void a_or_l(volatile void *p, long v)
-+{
-+ a_or(p, v);
-+}
-+
-+static inline void a_and_64(volatile uint64_t *p, uint64_t v)
-+{
-+ union { uint64_t v; uint32_t r[2]; } u = { v };
-+ a_and((int *)p, u.r[0]);
-+ a_and((int *)p+1, u.r[1]);
-+}
-+
-+static inline void a_or_64(volatile uint64_t *p, uint64_t v)
-+{
-+ union { ui