mirror of
https://github.com/openembedded/meta-openembedded.git
synced 2025-12-15 23:05:34 +01:00
angstrom-layers: add util-linux-ng 2.17 to meta-openembedded
Signed-off-by: Koen Kooi <k-kooi@ti.com>
This commit is contained in:
parent
2b41bf1cc7
commit
70d5fa3baa
|
|
@ -0,0 +1,14 @@
|
||||||
|
Index: util-linux-ng-2.17/fdisk/fdiskbsdlabel.h
|
||||||
|
===================================================================
|
||||||
|
--- util-linux-ng-2.17.orig/fdisk/fdiskbsdlabel.h 2010-07-07 14:13:04.073530165 +0200
|
||||||
|
+++ util-linux-ng-2.17/fdisk/fdiskbsdlabel.h 2010-07-07 14:13:43.053535150 +0200
|
||||||
|
@@ -48,7 +48,8 @@
|
||||||
|
|
||||||
|
#if defined (i386) || defined (__sparc__) || defined (__arm__) || \
|
||||||
|
defined (__mips__) || defined (__s390__) || defined (__sh__) || \
|
||||||
|
- defined(__x86_64__) || defined (__avr32__) || defined(__cris__)
|
||||||
|
+ defined(__x86_64__) || defined (__avr32__) || defined(__cris__) || \
|
||||||
|
+ defined (__nios2__)
|
||||||
|
#define BSD_LABELSECTOR 1
|
||||||
|
#define BSD_LABELOFFSET 0
|
||||||
|
#elif defined (__alpha__) || defined (__powerpc__) || defined (__ia64__) || defined (__hppa__)
|
||||||
70
recipes-core/util-linux-ng/util-linux-ng-2.17/tls.patch
Normal file
70
recipes-core/util-linux-ng/util-linux-ng-2.17/tls.patch
Normal file
|
|
@ -0,0 +1,70 @@
|
||||||
|
Index: util-linux-ng-2.16/m4/tls.m4
|
||||||
|
===================================================================
|
||||||
|
--- util-linux-ng-2.16.orig/m4/tls.m4 2009-07-04 01:20:03.000000000 +0200
|
||||||
|
+++ util-linux-ng-2.16/m4/tls.m4 2009-07-30 01:57:30.151697033 +0200
|
||||||
|
@@ -18,31 +18,26 @@
|
||||||
|
# version as well.
|
||||||
|
#
|
||||||
|
AC_DEFUN([AX_TLS], [
|
||||||
|
- AC_MSG_CHECKING(for thread local storage (TLS) class)
|
||||||
|
- AC_CACHE_VAL(ac_cv_tls, [
|
||||||
|
- ax_tls_keywords="__thread __declspec(thread) none"
|
||||||
|
- for ax_tls_keyword in $ax_tls_keywords; do
|
||||||
|
- case $ax_tls_keyword in
|
||||||
|
- none) ac_cv_tls=none ; break ;;
|
||||||
|
- *)
|
||||||
|
- AC_TRY_COMPILE(
|
||||||
|
- [#include <stdlib.h>
|
||||||
|
- static void
|
||||||
|
- foo(void) {
|
||||||
|
- static ] $ax_tls_keyword [ int bar;
|
||||||
|
- exit(1);
|
||||||
|
- }],
|
||||||
|
- [],
|
||||||
|
- [ac_cv_tls=$ax_tls_keyword ; break],
|
||||||
|
- ac_cv_tls=none
|
||||||
|
- )
|
||||||
|
- esac
|
||||||
|
- done
|
||||||
|
-])
|
||||||
|
+ AC_CACHE_CHECK([for thread local storage (TLS) class],
|
||||||
|
+ ac_cv_tls,
|
||||||
|
+ [AC_LINK_IFELSE([__thread int a; int b; int main() { return a = b; }],
|
||||||
|
+ [chktls_save_LDFLAGS="$LDFLAGS"
|
||||||
|
+ LDFLAGS="-shared -Wl,--no-undefined $LDFLAGS"
|
||||||
|
+ chktls_save_CFLAGS="$CFLAGS"
|
||||||
|
+ CFLAGS="-fPIC $CFLAGS"
|
||||||
|
+ dnl If -shared works, test if TLS works in a shared library.
|
||||||
|
+ AC_LINK_IFELSE([int f() { return 0; }],
|
||||||
|
+ AC_LINK_IFELSE([__thread int a; int b; int f() { return a = b; }],
|
||||||
|
+ [ac_cv_tls=yes],
|
||||||
|
+ [ac_cv_tls=no]),
|
||||||
|
+ [ac_cv_tls=yes])
|
||||||
|
+ CFLAGS="$chktls_save_CFLAGS"
|
||||||
|
+ LDFLAGS="$chktls_save_LDFLAGS"], [ac_cv_tls=no])
|
||||||
|
+ ])
|
||||||
|
|
||||||
|
- if test "$ac_cv_tls" != "none"; then
|
||||||
|
- dnl AC_DEFINE([TLS], [], [If the compiler supports a TLS storage class define it to that here])
|
||||||
|
- AC_DEFINE_UNQUOTED([TLS], $ac_cv_tls, [If the compiler supports a TLS storage class define it to that here])
|
||||||
|
- fi
|
||||||
|
- AC_MSG_RESULT($ac_cv_tls)
|
||||||
|
+ AS_IF([test "x$ac_cv_tls" = "xyes"],
|
||||||
|
+ [AC_DEFINE([TLS], 1,
|
||||||
|
+ [Define this if the compiler supports __thread for Thread-Local Storage])
|
||||||
|
+ $1],
|
||||||
|
+ [$2])
|
||||||
|
])
|
||||||
|
Index: util-linux-ng-2.16/shlibs/uuid/src/gen_uuid.c
|
||||||
|
===================================================================
|
||||||
|
--- util-linux-ng-2.16.orig/shlibs/uuid/src/gen_uuid.c 2009-07-30 02:31:48.518159459 +0200
|
||||||
|
+++ util-linux-ng-2.16/shlibs/uuid/src/gen_uuid.c 2009-07-30 02:32:04.867871183 +0200
|
||||||
|
@@ -99,7 +99,7 @@
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef TLS
|
||||||
|
-#define THREAD_LOCAL static TLS
|
||||||
|
+#define THREAD_LOCAL static __thread
|
||||||
|
#else
|
||||||
|
#define THREAD_LOCAL static
|
||||||
|
#endif
|
||||||
|
|
@ -0,0 +1,13 @@
|
||||||
|
Index: util-linux-ng-2.16/misc-utils/cal.c
|
||||||
|
===================================================================
|
||||||
|
--- util-linux-ng-2.16.orig/misc-utils/cal.c 2009-07-03 16:20:01.000000000 -0700
|
||||||
|
+++ util-linux-ng-2.16/misc-utils/cal.c 2009-07-18 23:21:37.000000000 -0700
|
||||||
|
@@ -407,7 +407,7 @@
|
||||||
|
strcpy(day_headings,"");
|
||||||
|
strcpy(j_day_headings,"");
|
||||||
|
|
||||||
|
-#ifdef HAVE_LANGINFO_H
|
||||||
|
+#ifdef HAVE_LANGINFO_H && !defined(__UCLIBC__)
|
||||||
|
# define weekday(wd) nl_langinfo(ABDAY_1+wd)
|
||||||
|
#else
|
||||||
|
# define weekday(wd) _time_info->abbrev_wkday[wd]
|
||||||
|
|
@ -0,0 +1,23 @@
|
||||||
|
Index: util-linux-ng-2.14/login-utils/login.c
|
||||||
|
===================================================================
|
||||||
|
--- util-linux-ng-2.14.orig/login-utils/login.c 2008-05-28 16:01:02.000000000 -0700
|
||||||
|
+++ util-linux-ng-2.14/login-utils/login.c 2009-03-04 18:31:42.000000000 -0800
|
||||||
|
@@ -358,6 +358,7 @@
|
||||||
|
char *childArgv[10];
|
||||||
|
char *buff;
|
||||||
|
int childArgc = 0;
|
||||||
|
+ struct sigaction act;
|
||||||
|
#ifdef HAVE_SECURITY_PAM_MISC_H
|
||||||
|
int retcode;
|
||||||
|
pam_handle_t *pamh = NULL;
|
||||||
|
@@ -373,7 +374,9 @@
|
||||||
|
pid = getpid();
|
||||||
|
|
||||||
|
signal(SIGALRM, timedout);
|
||||||
|
- siginterrupt(SIGALRM,1); /* we have to interrupt syscalls like ioclt() */
|
||||||
|
+ (void) sigaction(SIGALRM, NULL, &act);
|
||||||
|
+ act.sa_flags &= ~SA_RESTART;
|
||||||
|
+ sigaction(SIGALRM, &act, NULL);
|
||||||
|
alarm((unsigned int)timeout);
|
||||||
|
signal(SIGQUIT, SIG_IGN);
|
||||||
|
signal(SIGINT, SIG_IGN);
|
||||||
321
recipes-core/util-linux-ng/util-linux-ng.inc
Normal file
321
recipes-core/util-linux-ng/util-linux-ng.inc
Normal file
|
|
@ -0,0 +1,321 @@
|
||||||
|
DESCRIPTION = "Util-linux-ng is a suite of essential utilities for any Linux system."
|
||||||
|
SECTION = "base"
|
||||||
|
LICENSE = "GPL"
|
||||||
|
DEPENDS = "${@base_contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)} udev zlib ncurses virtual/libintl"
|
||||||
|
DEPENDS_virtclass-native = "zlib-native ncurses-native lzo-native gettext-native"
|
||||||
|
|
||||||
|
inherit autotools gettext
|
||||||
|
|
||||||
|
INC_PR = "r33"
|
||||||
|
|
||||||
|
# allows for a release candidate
|
||||||
|
RC ?= ""
|
||||||
|
|
||||||
|
SRC_URI = "${KERNELORG_MIRROR}/pub/linux/utils/util-linux-ng/v${PV}/util-linux-ng-${PV}${RC}.tar.bz2;name=archive"
|
||||||
|
|
||||||
|
SRC_URI_append_chinook-compat = " file://chinook_libtool.patch "
|
||||||
|
|
||||||
|
PACKAGES =+ "${PN}-fdisk ${PN}-cfdisk ${PN}-sfdisk ${PN}-swaponoff \
|
||||||
|
${PN}-losetup ${PN}-umount ${PN}-mount ${PN}-readprofile \
|
||||||
|
${PN}-fsck ${PN}-blkid ${PN}-mountall ${PN}-reset"
|
||||||
|
|
||||||
|
PACKAGES_virtclass-native = ""
|
||||||
|
|
||||||
|
PACKAGES_DYNAMIC = "libblkid* libuuid*"
|
||||||
|
|
||||||
|
# Provide old util-linux names (several recipes still use DEPENDS or RDEPENDS_${PN} = "util-linux"):
|
||||||
|
PROVIDES = "util-linux"
|
||||||
|
RPROVIDES_${PN} = "util-linux"
|
||||||
|
RPROVIDES_util-linux-ng-fdisk = "util-linux-fdisk"
|
||||||
|
RPROVIDES_util-linux-ng-cfdisk = "util-linux-cfdisk"
|
||||||
|
RPROVIDES_util-linux-ng-sfdisk = "util-linux-sfdisk"
|
||||||
|
RPROVIDES_util-linux-ng-swaponoff = "util-linux-swaponoff"
|
||||||
|
RPROVIDES_util-linux-ng-losetup = "util-linux-losetup"
|
||||||
|
RPROVIDES_util-linux-ng-umount = "util-linux-umount"
|
||||||
|
RPROVIDES_util-linux-ng-mount = "util-linux-mount"
|
||||||
|
RPROVIDES_util-linux-ng-readprofile = "util-linux-readprofile"
|
||||||
|
RPROVIDES_util-linux-ng-fsck = "e2fsprogs-fsck"
|
||||||
|
RPROVIDES_util-linux-ng-blkid = "e2fsprogs-blkid"
|
||||||
|
|
||||||
|
FILES_${PN}-doc += "/usr/share/misc/getopt/getopt-*.*"
|
||||||
|
FILES_${PN} = "${bindir} ${sbindir} ${base_bindir} ${base_sbindir}"
|
||||||
|
|
||||||
|
FILES_util-linux-ng-fdisk = "${base_sbindir}/fdisk.${PN}"
|
||||||
|
FILES_util-linux-ng-cfdisk = "${base_sbindir}/cfdisk"
|
||||||
|
# Moved to ${sbindir} in new versions:
|
||||||
|
FILES_util-linux-ng-sfdisk = "${base_sbindir}/sfdisk ${sbindir}/sfdisk"
|
||||||
|
FILES_util-linux-ng-swaponoff = "${base_sbindir}/swapon.${PN} ${base_sbindir}/swapoff.${PN}"
|
||||||
|
FILES_util-linux-ng-losetup = "${base_sbindir}/losetup.${PN}"
|
||||||
|
FILES_util-linux-ng-mount = "${base_bindir}/mount.${PN} ${sysconfdir}/default/mountall"
|
||||||
|
FILES_util-linux-ng-umount = "${base_bindir}/umount.${PN}"
|
||||||
|
# Moved to ${base_sbindir} by do_install:
|
||||||
|
FILES_util-linux-ng-readprofile = "${sbindir}/readprofile.${PN}"
|
||||||
|
FILES_util-linux-ng-fsck = "${base_sbindir}/fsck.${PN}"
|
||||||
|
FILES_util-linux-ng-blkid = "${base_sbindir}/blkid.${PN}"
|
||||||
|
FILES_${PN}-mountall = "${sysconfdir}/default/mountall.${PN}"
|
||||||
|
FILES_${PN}-reset = "${bindir}/reset.${PN}"
|
||||||
|
|
||||||
|
RREPLACES_util-linux-ng-blkid = "e2fsprogs-blkid"
|
||||||
|
RREPLACES_${PN}-mountall = "busybox-mountall"
|
||||||
|
|
||||||
|
RRECOMMENDS_${PN} = "${PN}-fdisk ${PN}-cfdisk ${PN}-sfdisk ${PN}-mount ${PN}-readprofile"
|
||||||
|
RDEPENDS_${PN} = "${PN}-mountall ${PN}-umount ${PN}-swaponoff ${PN}-losetup ${PN}-fsck ${PN}-blkid"
|
||||||
|
RDEPENDS_${PN}-reset = "ncurses-tools"
|
||||||
|
|
||||||
|
RRECOMMENDS_${PN}_virtclass-native = ""
|
||||||
|
RDEPENDS_${PN}_virtclass-native = ""
|
||||||
|
|
||||||
|
EXTRA_OECONF = "--disable-use-tty-group --disable-makeinstall-chown \
|
||||||
|
--enable-kill --enable-last --enable-mesg --enable-raw --enable-login-utils \
|
||||||
|
--enable-arch --enable-init --enable-partx --enable-schedutils \
|
||||||
|
--with-fsprobe=builtin --enable-libuuid --enable-libblkid \
|
||||||
|
--enable-fsck --enable-reset"
|
||||||
|
|
||||||
|
LDFLAGS_append_libc-uclibc = "${@['',' -lintl'][bb.data.getVar('USE_NLS', d, 1) == 'yes']}"
|
||||||
|
LDFLAGS_virtclass-native = "${BUILD_LDFLAGS}"
|
||||||
|
|
||||||
|
S = "${WORKDIR}/util-linux-ng-${PV}${RC}"
|
||||||
|
|
||||||
|
do_configure_prepend_chinook-compat () {
|
||||||
|
|
||||||
|
for i in lt~obsolete.m4 ltsugar.m4 libtool.m4 ltoptions.m4 ltversion.m4
|
||||||
|
do
|
||||||
|
rm ${S}/m4/${i}
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
do_compile () {
|
||||||
|
set -e
|
||||||
|
oe_runmake ARCH=${TARGET_ARCH} CPU= CPUOPT= \
|
||||||
|
'OPT=${CFLAGS}' 'CC=${CC}' 'LD=${LD}' \
|
||||||
|
'LDFLAGS=${LDFLAGS}'
|
||||||
|
}
|
||||||
|
|
||||||
|
checklink() {
|
||||||
|
local targ link value
|
||||||
|
targ="$1"
|
||||||
|
link="$2"
|
||||||
|
ext="$3"
|
||||||
|
if test -h "$link"
|
||||||
|
then
|
||||||
|
value="$(readlink "$link")"
|
||||||
|
if test "$value" = "$targ"
|
||||||
|
then
|
||||||
|
rm "$link"
|
||||||
|
ln -s "$targ"."${PN}" "$link$ext"
|
||||||
|
return 0
|
||||||
|
else
|
||||||
|
echo "$link: '$value' found '$targ' expected" >&2
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
echo "$link: not a symbolic link" >&2
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
do_install () {
|
||||||
|
# with ccache the timestamps on compiled files may
|
||||||
|
# end up earlier than on their inputs, this allows
|
||||||
|
# for the resultant compilation in the install step.
|
||||||
|
oe_runmake ARCH=${TARGET_ARCH} CPU= CPUOPT= \
|
||||||
|
'OPT=${CFLAGS}' 'CC=${CC}' 'LD=${LD}' \
|
||||||
|
'LDFLAGS=${LDFLAGS}' 'DESTDIR=${D}' install
|
||||||
|
mkdir -p ${D}${base_bindir}
|
||||||
|
|
||||||
|
sbinprogs="agetty blockdev ctrlaltdel cfdisk"
|
||||||
|
sbinprogs_a="pivot_root hwclock mkswap shutdown mkfs.minix fsck.minix losetup swapon fdisk fsck blkid vigr vipw"
|
||||||
|
usrbinprogs_a="chfn chsh hexdump last logger mesg newgrp renice wall setsid chrt reset cal script flock"
|
||||||
|
usrsbinprogs_a="readprofile"
|
||||||
|
binprogs_a="dmesg kill more umount mount login"
|
||||||
|
|
||||||
|
if [ "${base_sbindir}" != "${sbindir}" ]; then
|
||||||
|
mkdir -p ${D}${base_sbindir}
|
||||||
|
for p in $sbinprogs $sbinprogs_a; do
|
||||||
|
if [ -f "${D}${sbindir}/$p" ]; then
|
||||||
|
mv "${D}${sbindir}/$p" "${D}${base_sbindir}/$p"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "${base_bindir}" != "${bindir}" ]; then
|
||||||
|
mkdir -p ${D}${base_bindir}
|
||||||
|
for p in $binprogs_a; do
|
||||||
|
if [ -f "${D}${bindir}/$p" ]; then
|
||||||
|
mv "${D}${bindir}/$p" "${D}${base_bindir}/$p"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
|
for p in $usrbinprogs_a; do
|
||||||
|
if [ -f "${D}${bindir}/$p" ]; then
|
||||||
|
mv "${D}${bindir}/$p" "${D}${bindir}/$p.${PN}"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
for p in $usrsbinprogs_a; do
|
||||||
|
if [ -f "${D}${sbindir}/$p" ]; then
|
||||||
|
mv "${D}${sbindir}/$p" "${D}${sbindir}/$p.${PN}"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
for p in $binprogs_a; do
|
||||||
|
if [ -f "${D}${base_bindir}/$p" ]; then
|
||||||
|
mv "${D}${base_bindir}/$p" "${D}${base_bindir}/$p.${PN}"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
for p in $sbinprogs_a; do
|
||||||
|
if [ -f "${D}${base_sbindir}/$p" ]; then
|
||||||
|
mv "${D}${base_sbindir}/$p" "${D}${base_sbindir}/$p.${PN}"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
install -d ${D}${sysconfdir}/default/
|
||||||
|
echo 'MOUNTALL="-t nonfs,nosmbfs,noncpfs"' > ${D}${sysconfdir}/default/mountall.${PN}
|
||||||
|
|
||||||
|
rm ${D}${sbindir}/swapoff -f
|
||||||
|
ln -sf ${base_sbindir}/swapon.${PN} ${D}${base_sbindir}/swapoff.${PN}
|
||||||
|
ln -sf ${base_sbindir}/shutdown ${D}${base_sbindir}/reboot.${PN}
|
||||||
|
ln -sf ${base_sbindir}/shutdown ${D}${base_sbindir}/halt.${PN}
|
||||||
|
ln -sf ${base_sbindir}/shutdown ${D}${base_sbindir}/fastboot
|
||||||
|
ln -sf ${base_sbindir}/shutdown ${D}${base_sbindir}/fasthalt
|
||||||
|
}
|
||||||
|
|
||||||
|
python populate_packages_prepend () {
|
||||||
|
ulinxng_libdir = bb.data.expand('${libdir}', d)
|
||||||
|
ulinxng_libdir_dbg = bb.data.expand('${libdir}/.debug', d)
|
||||||
|
do_split_packages(d, ulinxng_libdir, '^lib(.*)\.so$', 'lib%s-dev', 'util-linux-ng %s development package', extra_depends='${PN}-dev', allow_links=True)
|
||||||
|
do_split_packages(d, ulinxng_libdir, '^lib(.*)\.la$', 'lib%s-dev', 'util-linux-ng %s development package', extra_depends='${PN}-dev')
|
||||||
|
do_split_packages(d, ulinxng_libdir, '^lib(.*)\.a$', 'lib%s-dev', 'util-linux-ng %s development package', extra_depends='${PN}-dev')
|
||||||
|
do_split_packages(d, ulinxng_libdir, '^lib(.*)\.so\.*', 'lib%s', 'util-linux-ng %s library', extra_depends='', allow_links=True)
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
pkg_postinst_${PN} () {
|
||||||
|
update-alternatives --install ${base_bindir}/dmesg dmesg dmesg.${PN} 100
|
||||||
|
update-alternatives --install ${base_bindir}/kill kill kill.${PN} 100
|
||||||
|
update-alternatives --install ${base_bindir}/more more more.${PN} 100
|
||||||
|
update-alternatives --install ${base_sbindir}/mkswap mkswap mkswap.${PN} 100
|
||||||
|
test -x ${base_sbindir}/pivot_root.${PN} && \
|
||||||
|
update-alternatives --install ${base_sbindir}/pivot_root pivot_root pivot_root.${PN} 100
|
||||||
|
update-alternatives --install ${base_sbindir}/sln sln sln.${PN} 100
|
||||||
|
update-alternatives --install ${base_sbindir}/mkfs.minix mkfs.minix mkfs.minix.${PN} 100
|
||||||
|
update-alternatives --install ${base_sbindir}/fsck.minix fsck.minix fsck.minix.${PN} 100
|
||||||
|
update-alternatives --install ${bindir}/hexdump hexdump hexdump.${PN} 100
|
||||||
|
update-alternatives --install ${bindir}/last last last.${PN} 100
|
||||||
|
update-alternatives --install ${bindir}/logger logger logger.${PN} 100
|
||||||
|
update-alternatives --install ${bindir}/mesg mesg mesg.${PN} 100
|
||||||
|
update-alternatives --install ${bindir}/renice renice renice.${PN} 100
|
||||||
|
update-alternatives --install ${bindir}/wall wall wall.${PN} 100
|
||||||
|
update-alternatives --install ${bindir}/chfn chfn chfn.${PN} 100
|
||||||
|
update-alternatives --install ${bindir}/newgrp newgrp newgrp.${PN} 100
|
||||||
|
update-alternatives --install ${bindir}/chsh chsh chsh.${PN} 100
|
||||||
|
update-alternatives --install ${bindir}/cal cal cal.${PN} 100
|
||||||
|
update-alternatives --install ${bindir}/script script script.${PN} 100
|
||||||
|
update-alternatives --install ${bindir}/flock flock flock.${PN} 100
|
||||||
|
update-alternatives --install ${base_bindir}/login login login.${PN} 100
|
||||||
|
update-alternatives --install ${base_sbindir}/vipw vipw vipw.${PN} 100
|
||||||
|
update-alternatives --install ${base_sbindir}/vigr vigr vigr.${PN} 100
|
||||||
|
update-alternatives --install ${bindir}/setsid setsid setsid.${PN} 100
|
||||||
|
update-alternatives --install ${bindir}/chrt chrt chrt.${PN} 100
|
||||||
|
|
||||||
|
# There seems to be problem, atleast on nslu2, with these, until they are
|
||||||
|
# fixed the busybox ones have higher priority
|
||||||
|
update-alternatives --install ${base_sbindir}/hwclock hwclock hwclock.${PN} 10
|
||||||
|
update-alternatives --install ${base_sbindir}/shutdown shutdown shutdown.${PN} 10
|
||||||
|
update-alternatives --install ${base_sbindir}/reboot reboot reboot.${PN} 10
|
||||||
|
update-alternatives --install ${base_sbindir}/halt halt halt.${PN} 10
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_prerm_${PN} () {
|
||||||
|
test -x ${base_sbindir}/pivot_root.${PN} && \
|
||||||
|
update-alternatives --remove pivot_root pivot_root.${PN}
|
||||||
|
|
||||||
|
for i in dmesg kill more halt hwclock mkswap reboot shutdown sln mkfs.minix fsck.minix hexdump setsid chrt last logger mesg renice wall vipw vigr chfn newgrp chsh login cal script flock; do
|
||||||
|
update-alternatives --remove $i $i.${PN}
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst_util-linux-ng-reset() {
|
||||||
|
update-alternatives --install ${bindir}/reset reset reset.${PN} 100
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_prerm_util-linux-ng-reset () {
|
||||||
|
update-alternatives --remove reset reset.${PN}
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst_util-linux-ng-fdisk () {
|
||||||
|
update-alternatives --install ${base_sbindir}/fdisk fdisk fdisk.${PN} 100
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_prerm_util-linux-ng-fdisk () {
|
||||||
|
update-alternatives --remove fdisk fdisk.${PN}
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst_util-linux-ng-mount () {
|
||||||
|
update-alternatives --install ${base_bindir}/mount mount mount.${PN} 100
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_prerm_util-linux-ng-mount () {
|
||||||
|
update-alternatives --remove mount mount.${PN}
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst_util-linux-ng-umount () {
|
||||||
|
update-alternatives --install ${base_bindir}/umount umount umount.${PN} 100
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_prerm_util-linux-ng-umount () {
|
||||||
|
update-alternatives --remove umount umount.${PN}
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst_util-linux-ng-losetup () {
|
||||||
|
update-alternatives --install ${base_sbindir}/losetup losetup losetup.${PN} 100
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_prerm_util-linux-ng-losetup () {
|
||||||
|
update-alternatives --remove losetup losetup.${PN}
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst_util-linux-ng-swaponoff () {
|
||||||
|
update-alternatives --install ${base_sbindir}/swapoff swapoff swapon.${PN} 100
|
||||||
|
update-alternatives --install ${base_sbindir}/swapon swapon swapon.${PN} 100
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_prerm_util-linux-ng-swaponoff () {
|
||||||
|
update-alternatives --remove swapoff swapon.${PN}
|
||||||
|
update-alternatives --remove swapon swapon.${PN}
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst_util-linux-ng-readprofile() {
|
||||||
|
update-alternatives --install ${sbindir}/readprofile readprofile readprofile.${PN} 100
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_prerm_util-linux-ng-readprofile () {
|
||||||
|
update-alternatives --remove readprofile readprofile.${PN} 100
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst_util-linux-ng-mountall () {
|
||||||
|
update-alternatives --install ${sysconfdir}/default/mountall default_mountall mountall.${PN} 100
|
||||||
|
}
|
||||||
|
pkg_prerm_util-linux-ng-mountall () {
|
||||||
|
update-alternatives --remove default_mountall mountall.${PN}
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst_util-linux-ng-fsck () {
|
||||||
|
update-alternatives --install ${base_sbindir}/fsck fsck fsck.${PN} 100
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_prerm_util-linux-ng-fsck () {
|
||||||
|
update-alternatives --remove fsck fsck.${PN}
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst_util-linux-ng-blkid () {
|
||||||
|
update-alternatives --install ${base_sbindir}/blkid blkid blkid.${PN} 100
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_prerm_util-linux-ng-blkid () {
|
||||||
|
update-alternatives --remove blkid blkid.${PN}
|
||||||
|
}
|
||||||
|
|
||||||
|
BBCLASSEXTEND = "native"
|
||||||
|
|
@ -0,0 +1,13 @@
|
||||||
|
Index: util-linux-ng-2.16/configure.ac
|
||||||
|
===================================================================
|
||||||
|
--- util-linux-ng-2.16.orig/configure.ac 2009-07-22 20:14:46.896898772 +0200
|
||||||
|
+++ util-linux-ng-2.16/configure.ac 2009-07-22 20:15:08.223644774 +0200
|
||||||
|
@@ -70,7 +70,7 @@
|
||||||
|
AC_C_BIGENDIAN
|
||||||
|
|
||||||
|
dnl libtool-2
|
||||||
|
-LT_INIT
|
||||||
|
+AM_PROG_LIBTOOL
|
||||||
|
|
||||||
|
PKG_PROG_PKG_CONFIG
|
||||||
|
|
||||||
41
recipes-core/util-linux-ng/util-linux-ng/fix-make-c.patch
Normal file
41
recipes-core/util-linux-ng/util-linux-ng/fix-make-c.patch
Normal file
|
|
@ -0,0 +1,41 @@
|
||||||
|
From: Karel Zak <kzak@redhat.com>
|
||||||
|
Date: Mon, 11 May 2009 09:49:00 +0000 (+0200)
|
||||||
|
Subject: build-sys: fix "make -C" bug
|
||||||
|
X-Git-Url: http://git.kernel.org/?p=utils%2Futil-linux-ng%2Futil-linux-ng.git;a=commitdiff_plain;h=2ef7d41e6bbb7c842c06e911ffc562335a467b5d
|
||||||
|
|
||||||
|
build-sys: fix "make -C" bug
|
||||||
|
|
||||||
|
Running:
|
||||||
|
|
||||||
|
./configure --with-fsprobe=builtin
|
||||||
|
make -C mount mount
|
||||||
|
|
||||||
|
causes the following error:
|
||||||
|
|
||||||
|
gcc -std=gnu99 -DHAVE_CONFIG_H -I. -I.. -include ../config.h
|
||||||
|
-I../include -DLOCALEDIR=\"/home/matthew/util-linux-ng/share/locale\"
|
||||||
|
-fsigned-char -I../libs/blkid/src -g -O2 -MT mount-setproctitle.o
|
||||||
|
-MD -MP -MF .deps/mount-setproctitle.Tpo -c -o mount-setproctitle.o
|
||||||
|
`test -f '../lib/setproctitle.c' || echo './'`../lib/setproctitle.c mv
|
||||||
|
-f .deps/mount-setproctitle.Tpo .deps/mount-setproctitle.Po
|
||||||
|
make -C
|
||||||
|
make: option requires an argument -- 'C'
|
||||||
|
Usage: make [options] [target] ...
|
||||||
|
...
|
||||||
|
|
||||||
|
Reported-by: Matthew Burgess <matthew@linuxfromscratch.org>
|
||||||
|
Signed-off-by: Karel Zak <kzak@redhat.com>
|
||||||
|
---
|
||||||
|
|
||||||
|
diff --git a/config/include-Makefile.am b/config/include-Makefile.am
|
||||||
|
index b42a0c3..d5da619 100644
|
||||||
|
--- a/config/include-Makefile.am
|
||||||
|
+++ b/config/include-Makefile.am
|
||||||
|
@@ -17,6 +17,7 @@ dist_noinst_DATA = $(dist_man_MANS)
|
||||||
|
# Paths to in-tree libraries (use ul_ prefix to avoid possible collisions)
|
||||||
|
#
|
||||||
|
ul_libblkid_srcdir = $(top_srcdir)/libs/blkid/src
|
||||||
|
+ul_libblkid_builddir = $(top_builddir)/libs/blkid/src
|
||||||
|
ul_libblkid_la = $(top_builddir)/libs/blkid/src/libblkid.la
|
||||||
|
|
||||||
|
$(ul_libblkid_la):
|
||||||
55
recipes-core/util-linux-ng/util-linux-ng/optional-uuid.patch
Normal file
55
recipes-core/util-linux-ng/util-linux-ng/optional-uuid.patch
Normal file
|
|
@ -0,0 +1,55 @@
|
||||||
|
From: Karel Zak <kzak@redhat.com>
|
||||||
|
Date: Tue, 12 May 2009 19:22:19 +0000 (+0200)
|
||||||
|
Subject: blkid: make libuuid optional
|
||||||
|
X-Git-Url: http://git.kernel.org/?p=utils%2Futil-linux-ng%2Futil-linux-ng.git;a=commitdiff_plain;h=cdd17c7a73cab10a34bf80616225b8215ac4e2ed
|
||||||
|
|
||||||
|
blkid: make libuuid optional
|
||||||
|
|
||||||
|
read.c:28:23: error: uuid/uuid.h: No such file or directory
|
||||||
|
make[3]: *** [read.lo] Error 1
|
||||||
|
make[3]: *** Waiting for unfinished jobs....
|
||||||
|
|
||||||
|
Reported-by: Olaf <mailinglists@ban-solms.de>
|
||||||
|
Signed-off-by: Karel Zak <kzak@redhat.com>
|
||||||
|
---
|
||||||
|
|
||||||
|
diff --git a/libs/blkid/src/config.c b/libs/blkid/src/config.c
|
||||||
|
index 2e59218..9091736 100644
|
||||||
|
--- a/libs/blkid/src/config.c
|
||||||
|
+++ b/libs/blkid/src/config.c
|
||||||
|
@@ -24,9 +24,6 @@
|
||||||
|
#include <errno.h>
|
||||||
|
#endif
|
||||||
|
#include <stdint.h>
|
||||||
|
-#ifdef HAVE_LIBUUID
|
||||||
|
-#include <uuid/uuid.h>
|
||||||
|
-#endif
|
||||||
|
#include <stdarg.h>
|
||||||
|
|
||||||
|
#include "blkdev.h"
|
||||||
|
diff --git a/libs/blkid/src/evaluate.c b/libs/blkid/src/evaluate.c
|
||||||
|
index a9c9fba..f0ae126 100644
|
||||||
|
--- a/libs/blkid/src/evaluate.c
|
||||||
|
+++ b/libs/blkid/src/evaluate.c
|
||||||
|
@@ -27,9 +27,6 @@
|
||||||
|
#include <errno.h>
|
||||||
|
#endif
|
||||||
|
#include <stdint.h>
|
||||||
|
-#ifdef HAVE_LIBUUID
|
||||||
|
-#include <uuid/uuid.h>
|
||||||
|
-#endif
|
||||||
|
#include <stdarg.h>
|
||||||
|
|
||||||
|
#include "pathnames.h"
|
||||||
|
diff --git a/libs/blkid/src/read.c b/libs/blkid/src/read.c
|
||||||
|
index 4163874..b5e9cd0 100644
|
||||||
|
--- a/libs/blkid/src/read.c
|
||||||
|
+++ b/libs/blkid/src/read.c
|
||||||
|
@@ -25,7 +25,6 @@
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include "blkidP.h"
|
||||||
|
-#include "uuid/uuid.h"
|
||||||
|
|
||||||
|
#ifdef HAVE_STRTOULL
|
||||||
|
#define STRTOULL strtoull /* defined in stdlib.h if you try hard enough */
|
||||||
|
|
@ -0,0 +1,25 @@
|
||||||
|
Index: util-linux-ng-2.15/libs/blkid/src/blkidP.h
|
||||||
|
===================================================================
|
||||||
|
--- util-linux-ng-2.15.orig/libs/blkid/src/blkidP.h 2009-07-01 23:09:57.000000000 +0200
|
||||||
|
+++ util-linux-ng-2.15/libs/blkid/src/blkidP.h 2009-07-01 23:10:09.000000000 +0200
|
||||||
|
@@ -18,6 +18,7 @@
|
||||||
|
|
||||||
|
#include <sys/types.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
+#include <stdarg.h>
|
||||||
|
|
||||||
|
#include "bitops.h" /* $(top_srcdir)/include/ */
|
||||||
|
#include "blkid.h"
|
||||||
|
Index: util-linux-ng-2.15/misc-utils/cal.c
|
||||||
|
===================================================================
|
||||||
|
--- util-linux-ng-2.15.orig/misc-utils/cal.c 2009-07-01 23:16:54.000000000 +0200
|
||||||
|
+++ util-linux-ng-2.15/misc-utils/cal.c 2009-07-01 23:17:08.000000000 +0200
|
||||||
|
@@ -291,7 +291,7 @@
|
||||||
|
* the locale database, which can be overridden with the
|
||||||
|
* -s (Sunday) or -m (Monday) options.
|
||||||
|
*/
|
||||||
|
-#ifdef HAVE_LANGINFO_H
|
||||||
|
+#if defined(HAVE_LANGINFO_H) && !defined(__UCLIBC__)
|
||||||
|
/*
|
||||||
|
* You need to use 2 locale variables to get the first day of the week.
|
||||||
|
* This is needed to support first_weekday=2 and first_workday=1 for
|
||||||
16
recipes-core/util-linux-ng/util-linux-ng_2.17.bb
Normal file
16
recipes-core/util-linux-ng/util-linux-ng_2.17.bb
Normal file
|
|
@ -0,0 +1,16 @@
|
||||||
|
require util-linux-ng.inc
|
||||||
|
|
||||||
|
PR = "${INC_PR}.2"
|
||||||
|
|
||||||
|
SRC_URI += "file://uclibc-compile.patch \
|
||||||
|
file://util-linux-ng-replace-siginterrupt.patch \
|
||||||
|
file://fdiskbsdlabel.h-nios2.patch \
|
||||||
|
"
|
||||||
|
|
||||||
|
# fallocate is glibc 2.10, fallocate64 is glibc 2.11
|
||||||
|
# we need to disable it for older versions
|
||||||
|
EXTRA_OECONF += "ac_cv_func_fallocate=no"
|
||||||
|
EXTRA_OECONF_virtclass-native += "--disable-fallocate --disable-use-tty-group"
|
||||||
|
|
||||||
|
SRC_URI[archive.md5sum] = "11cc8a0138019e7060dd275d47dbc096"
|
||||||
|
SRC_URI[archive.sha256sum] = "8720f7233394b68d17095707c195ebb014943c1075a18fb5fd21ec108f012be3"
|
||||||
Loading…
Reference in New Issue
Block a user