Make this port usable again:

- depend upon gentoo stage 3 linux base (build dependency only!)
 - bail out and suggest to use the package when the default linux base port
   is installed at compile time (build time conflict with gentoo stage 3)
 - patch stuff for the kdump in -current
 - reword the description (this is a FreeBSD native program)
 - portlint
 - someone may want to write a linux replacement for mksubr
This commit is contained in:
Alexander Leidinger 2006-07-19 20:02:22 +00:00
parent c00a914dc0
commit 65eb110812
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=168271
3 changed files with 47 additions and 9 deletions

View File

@ -7,7 +7,7 @@
PORTNAME= linux_kdump
PORTVERSION= 1.5
PORTREVISION= 1
PORTREVISION= 2
CATEGORIES= devel linux
MASTER_SITES= ${MASTER_SITE_LOCAL}
MASTER_SITE_SUBDIR= marcel
@ -15,10 +15,11 @@ MASTER_SITE_SUBDIR= marcel
MAINTAINER= freebsd-emulation@FreeBSD.org
COMMENT= Linux-compatability ktrace.out processor
BUILD_DEPENDS= /compat/linux/usr/bin/gcc:${PORTSDIR}/devel/linux_devtools
BUILD_DEPENDS= ${LINUXBASE}/usr/bin/gcc:${PORTSDIR}/emulators/linux_base-gentoo-stage3
ONLY_FOR_ARCHS= i386
MAN1= linux_kdump.1
ONLY_FOR_ARCHS= i386 amd64
MAN1= linux_kdump.1.gz
NOMANCOMPRESS= true
PLIST_FILES= bin/linux_kdump
.include <bsd.port.pre.mk>
@ -35,10 +36,13 @@ pre-everything::
.endif
.if !exists(${SRCDIR}/sys/i386/linux/syscalls.master)
IGNORE= "requires kernel source present in ${SRCDIR}/sys"
IGNORE= requires kernel source present in ${SRCDIR}/sys
.endif
.if !exists(${SRCDIR}/usr.bin/ktrace/subr.c)
IGNORE= "requires ktrace source present in ${SRCDIR}/usr.bin/ktrace"
IGNORE= requires ktrace source present in ${SRCDIR}/usr.bin/ktrace
.endif
.if exists(${LINUXBASE}/etc/fedora-release)
IGNORE= does not build with the default linux base, use the package instead
.endif
.include <bsd.port.post.mk>

View File

@ -0,0 +1,34 @@
--- Makefile.orig Wed Jul 19 21:27:48 2006
+++ Makefile Wed Jul 19 21:43:08 2006
@@ -2,14 +2,19 @@
PROG= linux_kdump
SRCS= kdump.c linux_ioctl.c subr.c syscallnames.c
+.if exists(${SRCDIR}/usr.bin/kdump/kdump_subr.h)
+SRCS+= kdump_subr.c
+CLEANFILES+=kdump_subr.c
+.endif
CLEANFILES+=linux_ioctl.c syscallnames.c
BINDIR= /bin
DESTDIR=${PREFIX}
MANDIR= /man/man
SRCDIR?=/usr/src
+LINUXBASE?=/compat/linux
-CFLAGS+=-I${SRCDIR}/usr.bin/ktrace -I${SRCDIR}
+CFLAGS+=-I${SRCDIR}/usr.bin/ktrace -I${SRCDIR}/usr.bin/kdump -I${SRCDIR}
.PATH: ${SRCDIR}/usr.bin/ktrace
default: depend all
@@ -22,5 +27,10 @@
linux_ioctl.c: mkioctls.linux
/bin/sh ${.CURDIR}/mkioctls.linux
+
+.if exists(${SRCDIR}/usr.bin/kdump/kdump_subr.h)
+kdump_subr.c: ${SRCDIR}/usr.bin/kdump/mksubr
+ /bin/sh ${SRCDIR}/usr.bin/kdump/mksubr ${LINUXBASE}/usr/include > ${.TARGET}
+.endif
.include <bsd.prog.mk>

View File

@ -1,3 +1,3 @@
Linux_kdump produces human-readable output from ktrace.out files
generated by the FreeBSD utility ktrace(1) when run with a Linux
binary.
The FreeBSD native linux_kdump utility produces human-readable output
from ktrace.out files generated by the FreeBSD utility ktrace(1) when
used on a Linux binary.