Skip to content

Commit e68c9d2

Browse files
committed
openbios-git: move to dev
1 parent 77f5055 commit e68c9d2

File tree

2 files changed

+92
-0
lines changed

2 files changed

+92
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
From 277489f19bd0e58396606973bb79b6faa8e1e0a5 Mon Sep 17 00:00:00 2001
2+
From: martell <[email protected]>
3+
Date: Thu, 30 Oct 2014 20:45:19 +0000
4+
Subject: [PATCH] fix printk to use FMT-cell instead of %x where it should
5+
6+
---
7+
arch/unix/unix.c | 8 ++++----
8+
1 file changed, 4 insertions(+), 4 deletions(-)
9+
10+
diff --git a/arch/unix/unix.c b/arch/unix/unix.c
11+
index 1f628eb..db70e0a 100644
12+
--- a/arch/unix/unix.c
13+
+++ b/arch/unix/unix.c
14+
@@ -324,10 +324,10 @@ segv_handler(int signo __attribute__ ((unused)),
15+
if (PC >= (ucell) dict && PC <= (ucell) dict + dicthead)
16+
addr = *(ucell *) PC;
17+
18+
- printk("panic: segmentation violation at %x\n", (ucell)si->si_addr);
19+
- printk("dict=0x%x here=0x%x(dict+0x%x) pc=0x%x(dict+0x%x)\n",
20+
+ printk("panic: segmentation violation at " FMT_cell "\n", (ucell)si->si_addr);
21+
+ printk("dict=0x" FMT_cell " here=0x" FMT_cell " (dict+0x" FMT_cell ") pc=0x" FMT_cell "(dict+0x" FMT_cell ")\n",
22+
(ucell)dict, (ucell)dict + dicthead, dicthead, PC, PC - (ucell) dict);
23+
- printk("dstackcnt=%d rstackcnt=%d instruction=%x\n",
24+
+ printk("dstackcnt=%d rstackcnt=%d instruction=" FMT_cell "\n",
25+
dstackcnt, rstackcnt, addr);
26+
27+
#ifdef CONFIG_DEBUG_DSTACK
28+
@@ -566,7 +566,7 @@ int main(int argc, char *argv[])
29+
if (optind + 1 != argc)
30+
printk("Warning: only first dictionary used.\n");
31+
32+
- printk("dictionary loaded (%d bytes).\n", dicthead);
33+
+ printk("dictionary loaded (" FMT_cell "bytes).\n", dicthead);
34+
printk("Initializing memory...");
35+
}
36+
init_memory();
37+
--
38+
2.1.2
39+

openbios-git/PKGBUILD

+53
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
# Maintainer: Martell Malone <[email protected]>
2+
3+
_realname=openbios
4+
pkgname="${_realname}-git"
5+
_ver_base=1.1
6+
pkgver=1.1.1261.b95d533
7+
pkgrel=1
8+
pkgdesc="OpenBIOS"
9+
arch=('i686' 'x86_64')
10+
url="https://www.openbios.org/"
11+
license=('GPL2')
12+
makedepends=('git' 'gcc' 'make' 'fcode-utils')
13+
14+
source=("${_realname}"::"git+https://git.qemu.org/git/openbios.git"
15+
"0001-fix-printk-to-use-FMT-cell-instead-of-x-where-it-sho.patch")
16+
sha256sums=('SKIP'
17+
'SKIP')
18+
19+
pkgver() {
20+
cd "$srcdir/$_realname"
21+
printf "%s.%s.%s" "$_ver_base" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
22+
}
23+
24+
25+
26+
prepare() {
27+
cd "$srcdir/$_realname"
28+
git am $srcdir/0001-fix-printk-to-use-FMT-cell-instead-of-x-where-it-sho.patch
29+
#patches here please :)
30+
}
31+
32+
build() {
33+
cd $srcdir/${_realname}
34+
35+
if [ "$CARCH" = "x86_64" ]
36+
then
37+
./config/scripts/switch-arch amd64
38+
fi
39+
40+
if [ "$CARCH" = "i686" ]
41+
then
42+
./config/scripts/switch-arch x86
43+
fi
44+
45+
make -j1
46+
}
47+
48+
package() {
49+
cd $srcdir/${pkgname}
50+
mkdir -p ${pkgdir}/usr/bin
51+
52+
//todo
53+
}

0 commit comments

Comments
 (0)