summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /sys-apps/memtest86+/files
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'sys-apps/memtest86+/files')
-rw-r--r--sys-apps/memtest86+/files/39_memtest86+33
-rw-r--r--sys-apps/memtest86+/files/make-memtest86+-boot-floppy111
-rw-r--r--sys-apps/memtest86+/files/make-memtest86+-boot-floppy.139
-rw-r--r--sys-apps/memtest86+/files/memtest86+-1.70-gnu_hash.patch11
-rw-r--r--sys-apps/memtest86+/files/memtest86+-2.01-hardcoded_cc.patch30
-rw-r--r--sys-apps/memtest86+/files/memtest86+-4.00-hardcoded_cc.patch30
-rw-r--r--sys-apps/memtest86+/files/memtest86+-4.20-hardcoded_cc.patch30
-rw-r--r--sys-apps/memtest86+/files/memtest86+-5.01-gcc-473.patch54
-rw-r--r--sys-apps/memtest86+/files/memtest86+-5.01-hardcoded_cc.patch16
9 files changed, 354 insertions, 0 deletions
diff --git a/sys-apps/memtest86+/files/39_memtest86+ b/sys-apps/memtest86+/files/39_memtest86+
new file mode 100644
index 000000000000..14f27a276888
--- /dev/null
+++ b/sys-apps/memtest86+/files/39_memtest86+
@@ -0,0 +1,33 @@
+#!/bin/sh
+
+. /usr/share/grub/grub-mkconfig_lib
+
+memtest=/boot/memtest86plus/memtest
+
+if [ -f "${memtest}" ]; then
+ device="$("${grub_probe}" --target=device "${memtest}")"
+ path="$(make_system_path_relative_to_its_root "${memtest}")"
+ cat <<EOF
+menuentry "Memtest86+" {
+EOF
+ prepare_grub_to_access_device "${device}" | grub_add_tab
+ cat <<EOF
+ linux16 "${path}"
+}
+EOF
+fi
+
+memtest=/boot/memtest86plus/memtest.netbsd
+
+if [ -f "${memtest}" ]; then
+ device="$("${grub_probe}" --target=device "${memtest}")"
+ path="$(make_system_path_relative_to_its_root "${memtest}")"
+ cat <<EOF
+menuentry "Memtest86+ (netbsd)" {
+EOF
+ prepare_grub_to_access_device "${device}" | grub_add_tab
+ cat <<EOF
+ knetbsd "${path}"
+}
+EOF
+fi
diff --git a/sys-apps/memtest86+/files/make-memtest86+-boot-floppy b/sys-apps/memtest86+/files/make-memtest86+-boot-floppy
new file mode 100644
index 000000000000..9c225c740bf4
--- /dev/null
+++ b/sys-apps/memtest86+/files/make-memtest86+-boot-floppy
@@ -0,0 +1,111 @@
+#!/bin/sh
+#
+# Script for making a memtest86 boot floppy using GRUB as bootloader
+#
+
+# (c) 2003 Peter Loje Hansen <pl@2m.dk>
+# - original version
+# (c) 2004 Yann Dirson <dirson@debian.org>
+# - added parameters
+# - ability to work on a floppy image instead of a real floppy
+# - adapted patches from Martin Koeppe <martin@koeppe-net.de>, to use
+# mtools and install full grub
+
+# TODO:
+# - add a flag to generate a default boot entry for (hd0)
+
+set -e
+
+MEMTEST=/boot/memtest86plus/memtest.bin
+FLOPPYIMAGE=/dev/fd0
+GRUBBIN=/sbin/grub
+GRUBLIB=/lib/grub
+MFORMAT=/usr/bin/mformat
+
+arch=$(uname -m)
+
+case "$arch" in
+ i386|i486|i686) GRUBARCH=i386-pc;;
+ x86_64) GRUBARCH=x86_64-pc;;
+ *) error "Unsupported architecture: $arch";;
+esac
+
+error()
+{
+ echo >&2 "$0: $*"
+ exit 1
+}
+
+needsarg()
+{
+ [ $1 -ge 2 ] || error "syntax error"
+}
+
+[ -d $GRUBLIB ] || error "Can't find $GRUBLIB - did you install a recent grub package (0.95+cvs20040624 or later) ?"
+[ -x $MFORMAT ] || error "Can't find mformat - did you install the mtools package ?"
+
+while [ $# -gt 0 ]
+do
+ case "$1" in
+ --help) echo "$0 [--memtest $MEMTEST] [--floppyimage $FLOPPYIMAGE]"; exit 0 ;;
+ --memtest) needsarg $#; MEMTEST="$2"; shift ;;
+ --floppyimage) needsarg $#; FLOPPYIMAGE="$2"; shift ;;
+ *) error "syntax error" ;;
+ esac
+ shift
+done
+
+MOUNTPOINT=$(mktemp -d)
+
+if [ -b "$FLOPPYIMAGE" ]
+then
+ FINALDEV="$FLOPPYIMAGE"
+ FLOPPYIMAGE="$(mktemp)"
+else
+ FINALDEV=""
+fi
+
+echo "* Creating msdos file system"
+echo
+if [ ! -s "$FLOPPYIMAGE" ]; then
+ # unless a non-empty image exists, create a blank one first
+ dd bs=1024 count=1440 if=/dev/zero of="$FLOPPYIMAGE"
+fi
+# FIXME: "-f 1440" should probably be dropped
+mformat -i $FLOPPYIMAGE -f 1440 ::
+
+mmd -i $FLOPPYIMAGE ::/boot
+mmd -i $FLOPPYIMAGE ::/boot/grub
+
+echo
+echo "* Installing GRUB files"
+mcopy -v -i "$FLOPPYIMAGE" - ::/boot/grub/menu.lst <<EOF
+color green/black light-green/black
+default 0
+timeout 10
+title memtest
+kernel (fd0)/boot/memtest.bin
+EOF
+mcopy -v -i "$FLOPPYIMAGE" $GRUBLIB/$GRUBARCH/* ::/boot/grub
+
+echo
+echo "* Installing $MEMTEST"
+mcopy -v -i "$FLOPPYIMAGE" "$MEMTEST" ::/boot/memtest.bin
+
+echo
+echo -n "* Installing GRUB"
+$GRUBBIN --batch --device-map=/dev/null <<EOF
+device (fd0) $FLOPPYIMAGE
+root (fd0)
+setup (fd0)
+quit
+EOF
+
+if [ -n "$FINALDEV" ]; then
+ echo
+ echo "Insert a writable floppy for $FINALDEV and press enter"
+ read FOO
+
+ dd bs=1024 if="$FLOPPYIMAGE" of="$FINALDEV"
+ rm "$FLOPPYIMAGE"
+fi
diff --git a/sys-apps/memtest86+/files/make-memtest86+-boot-floppy.1 b/sys-apps/memtest86+/files/make-memtest86+-boot-floppy.1
new file mode 100644
index 000000000000..e1283e5efc8f
--- /dev/null
+++ b/sys-apps/memtest86+/files/make-memtest86+-boot-floppy.1
@@ -0,0 +1,39 @@
+.\" Man page for make-memtest86+-boot-floppy
+
+.TH make-memtest86+-boot-floppy 1
+
+.SH NAME
+make-memtest86+-boot-floppy \- create a memtest86+ boot-floppy using GRUB.
+
+.SH SYNOPSIS
+
+.B make-memtest86+-boot-floppy [ \-\-memtest
+.I <path to memtest86+-image>
+.B ] [ \-\-floppyimage
+.I <path to floppyimage/device>
+.B ]
+
+.SH DESCRIPTION
+.B make-memtest86+-boot-floppy
+can create a memtest86+ boot floppy using GRUB as the bootloader.
+
+.SH OPTIONS
+
+.IP "\-\-memtest <path to the memtest-image>"
+Path to the memtest86+-image, default is /boot/memtest86+.bin.
+
+.IP "\-\-floppyimage <path to the floppyimage or device>"
+File or device where the boot-image should be written to, default is /dev/fd0.
+
+.IP "\-\-help"
+Display a short message about the options of the tool.
+
+.SH AUTHOR
+This man-page has been written by Thomas Schmidt <thomas@thsnet.de>
+.PP
+Permission is granted to copy, distribute and/or modify this document under
+the terms of the GNU General Public License, Version 2 any
+later version published by the Free Software Foundation.
+.PP
+On Debian systems, the complete text of the GNU General Public
+License can be found in /usr/share/common\-licenses/GPL.
diff --git a/sys-apps/memtest86+/files/memtest86+-1.70-gnu_hash.patch b/sys-apps/memtest86+/files/memtest86+-1.70-gnu_hash.patch
new file mode 100644
index 000000000000..5a9e06dc06d7
--- /dev/null
+++ b/sys-apps/memtest86+/files/memtest86+-1.70-gnu_hash.patch
@@ -0,0 +1,11 @@
+diff -Naurp memtest86+-1.70-orig/memtest_shared.lds memtest86+-1.70/memtest_shared.lds
+--- memtest86+-1.70-orig/memtest_shared.lds 2007-01-27 13:34:16.000000000 +0100
++++ memtest86+-1.70/memtest_shared.lds 2007-01-27 13:41:30.000000000 +0100
+@@ -18,6 +18,7 @@ SECTIONS {
+ .dynsym : { *(.dynsym) }
+ .dynstr : { *(.dynstr) }
+ .hash : { *(.hash) }
++ .gnu.hash : { *(.gnu.hash) }
+ .dynamic : { *(.dynamic) }
+
+ .rel.text : { *(.rel.text .rel.text.*) }
diff --git a/sys-apps/memtest86+/files/memtest86+-2.01-hardcoded_cc.patch b/sys-apps/memtest86+/files/memtest86+-2.01-hardcoded_cc.patch
new file mode 100644
index 000000000000..3b07731daadd
--- /dev/null
+++ b/sys-apps/memtest86+/files/memtest86+-2.01-hardcoded_cc.patch
@@ -0,0 +1,30 @@
+diff -Naurp memtest86+-2.01-orig/Makefile memtest86+-2.01/Makefile
+--- memtest86+-2.01-orig/Makefile 2008-03-11 21:04:28.000000000 +0100
++++ memtest86+-2.01/Makefile 2008-03-11 21:05:25.000000000 +0100
+@@ -8,10 +8,9 @@
+ #
+ FDISK=/dev/fd0
+
+-AS=as -32
+-CC=gcc
+-
+-CFLAGS=-Wall -march=i486 -m32 -Os -fomit-frame-pointer -fno-builtin -ffreestanding -fPIC
++CPPFLAGS=-m32
++CFLAGS=-Wall -m32 -march=i486 -O1 -fomit-frame-pointer -fno-builtin -ffreestanding -fPIC -fno-stack-protector
++ASFLAGS=-32
+
+ OBJS= head.o reloc.o main.o test.o init.o lib.o patn.o screen_buffer.o \
+ config.o linuxbios.o memsize.o pci.o controller.o random.o extra.o \
+@@ -47,10 +46,10 @@ memtest.bin: memtest_shared.bin bootsect
+ memtest_shared.bin -o memtest.bin
+
+ reloc.o: reloc.c
+- $(CC) -c $(CFLAGS) -fno-strict-aliasing reloc.c
++ $(CC) -c $(CFLAGS) -fno-strict-aliasing -fno-stack-protector reloc.c
+
+ test.o: test.c
+- $(CC) -c -Wall -march=i486 -m32 -Os -fomit-frame-pointer -fno-builtin -ffreestanding test.c
++ $(CC) -c -Wall -march=i486 -m32 -O1 -fomit-frame-pointer -fno-builtin -ffreestanding -fno-stack-protector -fno-pie -nopie test.c
+
+ clean:
+ rm -f *.o *.s *.iso memtest.bin memtest memtest_shared memtest_shared.bin
diff --git a/sys-apps/memtest86+/files/memtest86+-4.00-hardcoded_cc.patch b/sys-apps/memtest86+/files/memtest86+-4.00-hardcoded_cc.patch
new file mode 100644
index 000000000000..f2950b64e807
--- /dev/null
+++ b/sys-apps/memtest86+/files/memtest86+-4.00-hardcoded_cc.patch
@@ -0,0 +1,30 @@
+diff -Nuar --exclude '*.orig' --exclude '*rej' --exclude '*~' memtest86+-4.00.orig/Makefile memtest86+-4.00/Makefile
+--- memtest86+-4.00.orig/Makefile 2009-09-21 17:35:46.000000000 -0700
++++ memtest86+-4.00/Makefile 2009-09-25 09:04:23.000000000 -0700
+@@ -8,10 +8,9 @@
+ #
+ FDISK=/dev/fd0
+
+-AS=as -32
+-CC=gcc
+-
+-CFLAGS= -Wall -march=i486 -m32 -O2 -fomit-frame-pointer -fno-builtin -ffreestanding -fPIC
++CPPFLAGS=-m32
++CFLAGS=-Wall -march=i486 -m32 -O1 -fomit-frame-pointer -fno-builtin -ffreestanding -fPIC -fno-stack-protector
++ASFLAGS=-32
+
+ OBJS= head.o reloc.o main.o test.o init.o lib.o patn.o screen_buffer.o \
+ config.o linuxbios.o memsize.o pci.o controller.o random.o spd.o \
+@@ -47,10 +46,10 @@
+ memtest_shared.bin -o memtest.bin
+
+ reloc.o: reloc.c
+- $(CC) -c $(CFLAGS) -fno-strict-aliasing reloc.c
++ $(CC) -c $(CFLAGS) -fno-strict-aliasing -fno-stack-protector reloc.c
+
+ test.o: test.c
+- $(CC) -c -Wall -march=i486 -m32 -Os -fomit-frame-pointer -fno-builtin -ffreestanding test.c
++ $(CC) -c -Wall -march=i486 -m32 -O1 -fomit-frame-pointer -fno-builtin -ffreestanding -fno-stack-protector -fno-pie -nopie test.c
+
+ clean:
+ rm -f *.o *.s *.iso memtest.bin memtest memtest_shared memtest_shared.bin
diff --git a/sys-apps/memtest86+/files/memtest86+-4.20-hardcoded_cc.patch b/sys-apps/memtest86+/files/memtest86+-4.20-hardcoded_cc.patch
new file mode 100644
index 000000000000..2eb750c8dd93
--- /dev/null
+++ b/sys-apps/memtest86+/files/memtest86+-4.20-hardcoded_cc.patch
@@ -0,0 +1,30 @@
+diff -Naurp memtest86+-4.10-orig/Makefile memtest86+-4.10/Makefile
+--- memtest86+-4.10-orig/Makefile 2010-06-24 00:27:22.864634431 +0200
++++ memtest86+-4.10/Makefile 2010-06-24 00:28:42.402478590 +0200
+@@ -8,10 +8,9 @@
+ #
+ FDISK=/dev/fd0
+
+-AS=as -32
+-CC=gcc
+-
+-CFLAGS= -Wall -march=i486 -m32 -O2 -fomit-frame-pointer -fno-builtin -ffreestanding -fPIC -fno-stack-protector
++CFLAGS=-Wall -march=i486 -m32 -O2 -fomit-frame-pointer -fno-builtin -ffreestanding -fPIC -fno-stack-protector
++CPPFLAGS=-m32
++ASFLAGS=-32
+
+ OBJS= head.o reloc.o main.o test.o init.o lib.o patn.o screen_buffer.o \
+ config.o linuxbios.o memsize.o pci.o controller.o random.o spd.o \
+@@ -47,10 +46,10 @@ memtest.bin: memtest_shared.bin bootsect
+ memtest_shared.bin -o memtest.bin
+
+ reloc.o: reloc.c
+- $(CC) -c $(CFLAGS) -fno-strict-aliasing reloc.c
++ $(CC) -c $(CFLAGS) -fno-strict-aliasing -fno-stack-protector reloc.c
+
+ test.o: test.c
+- $(CC) -c -Wall -march=i486 -m32 -Os -fomit-frame-pointer -fno-builtin -ffreestanding test.c
++ $(CC) -c -Wall -march=i486 -m32 -O1 -fomit-frame-pointer -fno-builtin -ffreestanding -fno-stack-protector -fno-pie test.c
+
+ clean:
+ rm -f *.o *.s *.iso memtest.bin memtest memtest_shared memtest_shared.bin
diff --git a/sys-apps/memtest86+/files/memtest86+-5.01-gcc-473.patch b/sys-apps/memtest86+/files/memtest86+-5.01-gcc-473.patch
new file mode 100644
index 000000000000..ff9b15a9e4e1
--- /dev/null
+++ b/sys-apps/memtest86+/files/memtest86+-5.01-gcc-473.patch
@@ -0,0 +1,54 @@
+diff -Narup memtest86+-5.01-orig/controller.c memtest86+-5.01/controller.c
+--- memtest86+-5.01-orig/controller.c 2013-08-09 22:01:58.000000000 -0400
++++ memtest86+-5.01/controller.c 2014-06-22 11:01:17.347923472 -0400
+@@ -292,7 +292,7 @@ static void setup_nhm(void)
+
+ /* First, locate the PCI bus where the MCH is located */
+
+- for(i = 0; i < sizeof(possible_nhm_bus); i++) {
++ for(i = 0; i < sizeof(possible_nhm_bus) / sizeof(possible_nhm_bus[0]); i++) {
+ pci_conf_read( possible_nhm_bus[i], 3, 4, 0x00, 2, &vid);
+ pci_conf_read( possible_nhm_bus[i], 3, 4, 0x02, 2, &did);
+ vid &= 0xFFFF;
+@@ -327,7 +327,7 @@ static void setup_nhm32(void)
+ ctrl.mode = ECC_NONE;
+
+ /* First, locate the PCI bus where the MCH is located */
+- for(i = 0; i < sizeof(possible_nhm_bus); i++) {
++ for(i = 0; i < sizeof(possible_nhm_bus) / sizeof(possible_nhm_bus[0]); i++) {
+ pci_conf_read( possible_nhm_bus[i], 3, 4, 0x00, 2, &vid);
+ pci_conf_read( possible_nhm_bus[i], 3, 4, 0x02, 2, &did);
+ vid &= 0xFFFF;
+diff -Narup memtest86+-5.01-orig/io.h memtest86+-5.01/io.h
+--- memtest86+-5.01-orig/io.h 2013-08-09 22:01:58.000000000 -0400
++++ memtest86+-5.01/io.h 2014-06-22 11:00:19.279251873 -0400
+@@ -31,7 +31,7 @@
+ */
+
+ #define __OUT1(s,x) \
+-extern inline void __out##s(unsigned x value, unsigned short port) {
++static inline void __out##s(unsigned x value, unsigned short port) {
+
+ #define __OUT2(s,s1,s2) \
+ __asm__ __volatile__ ("out" #s " %" s1 "0,%" s2 "1"
+@@ -43,7 +43,7 @@ __OUT1(s##_p,x) __OUT2(s,s1,"w") : : "a"
+ __OUT1(s##c_p,x) __OUT2(s,s1,"") : : "a" (value), "id" (port)); SLOW_DOWN_IO; }
+
+ #define __IN1(s) \
+-extern inline RETURN_TYPE __in##s(unsigned short port) { RETURN_TYPE _v;
++static inline RETURN_TYPE __in##s(unsigned short port) { RETURN_TYPE _v;
+
+ #define __IN2(s,s1,s2) \
+ __asm__ __volatile__ ("in" #s " %" s2 "1,%" s1 "0"
+diff -Narup memtest86+-5.01-orig/Makefile memtest86+-5.01/Makefile
+--- memtest86+-5.01-orig/Makefile 2013-08-09 22:01:58.000000000 -0400
++++ memtest86+-5.01/Makefile 2014-06-22 10:59:27.463573842 -0400
+@@ -12,7 +12,7 @@ FDISK=/dev/fd0
+ AS=as -32
+ CC=gcc
+
+-CFLAGS= -Wall -march=i486 -m32 -O1 -fomit-frame-pointer -fno-builtin \
++CFLAGS= -Wall -march=i486 -m32 -O0 -fomit-frame-pointer -fno-builtin \
+ -ffreestanding -fPIC $(SMP_FL) -fno-stack-protector
+
+ OBJS= head.o reloc.o main.o test.o init.o lib.o patn.o screen_buffer.o \
diff --git a/sys-apps/memtest86+/files/memtest86+-5.01-hardcoded_cc.patch b/sys-apps/memtest86+/files/memtest86+-5.01-hardcoded_cc.patch
new file mode 100644
index 000000000000..f140a7fc6605
--- /dev/null
+++ b/sys-apps/memtest86+/files/memtest86+-5.01-hardcoded_cc.patch
@@ -0,0 +1,16 @@
+--- Makefile.orig 2015-02-01 01:08:33.000000000 +0300
++++ Makefile 2015-02-01 01:10:17.624757244 +0300
+@@ -9,11 +9,10 @@
+ #
+ FDISK=/dev/fd0
+
+-AS=as -32
+-CC=gcc
+-
+ CFLAGS= -Wall -march=i486 -m32 -O0 -fomit-frame-pointer -fno-builtin \
+ -ffreestanding -fPIC $(SMP_FL) -fno-stack-protector
++CPPFLAGS= -m32
++ASFLAGS= -32
+
+ OBJS= head.o reloc.o main.o test.o init.o lib.o patn.o screen_buffer.o \
+ config.o cpuid.o linuxbios.o pci.o memsize.o spd.o error.o dmi.o controller.o \