From c6e572f955e57dc5de3b991483c2b77a3e442517 Mon Sep 17 00:00:00 2001 From: Donald Buczek Date: Mon, 24 Dec 2018 11:36:26 +0100 Subject: [PATCH] time: Update from version 1.7 to 1.9 Version 1.7 is outdated and incorrectly reports RSS scaled by factor 4: $ curl -so mem.cpp https://ideone.com/plain/5bsp0R && make mem && /usr/bin/time -f "time thinks my peak rss is %M kB" ./mem g++ mem.cpp -o mem procfs thinks my peak RSS is: 514652 kB time thinks my peak rss is 2058608 kB The problems was fixed for us by a patch in time-1.7-1 (bee-files/04c1410). However, unlike assumed in the above commit, the bug is fixed in the current release of time, which is 1.9. So instead of patching an obsolete release, we should update to the current release. $ /usr/bin/time --version time (GNU Time) 1.9 Copyright (C) 2018 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later . This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Written by David Keppel, David MacKenzie, and Assaf Gordon. $ curl -so mem.cpp https://ideone.com/plain/5bsp0R && make mem && /usr/bin/time -f "time thinks my peak rss is %M kB" ./mem g++ mem.cpp -o mem procfs thinks my peak RSS is: 514564 kB time thinks my peak rss is 514564 kB Recreate bee file for version 1.9 from template. --- time-1.7-1.bee | 58 ------------------------------------ time.be0 | 79 ++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 79 insertions(+), 58 deletions(-) delete mode 100755 time-1.7-1.bee create mode 100755 time.be0 diff --git a/time-1.7-1.bee b/time-1.7-1.bee deleted file mode 100755 index c0f89cb1a..000000000 --- a/time-1.7-1.bee +++ /dev/null @@ -1,58 +0,0 @@ -#!/bin/env beesh - -SRCURL[0]="http://ftp.gnu.org/gnu/time/time-1.7.tar.gz" - -# https://bugzilla.redhat.com/show_bug.cgi?id=702826 -PATCHURL[0]="https://bugzilla.redhat.com/attachment.cgi?id=497533" - -PGRP=( uncategorized ) - - - -BEE_CONFIGURE=compat - -# EXCLUDE="" - -mee_patch() { - bee_patch -} - -mee_configure() { - bee_configure -} - -mee_build() { - bee_build -} - -mee_install() { -# bee_install bindir=${D}${BINDIR} infodir - - - - - mkdir -pv ${D}{${BINDIR},${INFODIR}} - - cp -v time ${D}${BINDIR} - - ln -sv time ${D}${BINDIR}/gtime - - cp -v ${S}/time.info ${D}${INFODIR} - -} - - - -#bindir = /usr/bin -#sbindir = /usr/sbin -#libexecdir = /usr/lib/time -#datadir = /usr/share -#sysconfdir = /etc -#sharedstatedir = /var -#localstatedir = /var -#libdir = /usr/lib -#infodir = /usr/share/info -#mandir = /usr/share/man -#includedir = /usr/include -#oldincludedir = /usr/include - diff --git a/time.be0 b/time.be0 new file mode 100755 index 000000000..aff9f3ceb --- /dev/null +++ b/time.be0 @@ -0,0 +1,79 @@ +#!/usr/bin/env beesh + +# BEE_VERSION time-1.9-0 + +## this file was created by bee init and should be executed to build a +## bee-package. (Additional hints are located at the end of this file.) + +############################################################################### +## The source URL(s) define the location of the sources that will be +## downloaded. Version variables may be used to simplify reuse of this bee-file. + +SRCURL[0]="https://ftp.gnu.org/gnu/time/time-${PKGVERSION}.tar.gz" + +############################################################################### +## Add URLs/pathes to patch files to the PATCHURL array. +## The sources will be patched in the order of the array. + +# PATCHURL+=() + +############################################################################### +## Uncomment the next statement, if the software may not be able to be built +## outside the source directory and needs to be built inside the source +## directory. + +# build_in_sourcedir + +############################################################################### +## bee cannot detect buildtypes specified in subdirectories. +## Sometimes packages "hide" the real sources in a subdirectory named +## 'src' or 'cmake' or .. +## use 'sourcesubdir_append' to specify this directory if known. + +# sourcesubdir_append src + + +############################################################################### +## Change the default (auto-detected) steps to +## extract, patch, configure/setup, build and install the software. +## Make sure the mee_install function does install everything to the +## image directory "${D}" + +#mee_extract() { +# bee_extract "${@}" +#} + +#mee_patch() { +# bee_patch "${@}" +#} + +#mee_configure() { +# bee_configure +#} + +#mee_build() { +# bee_build +#} + +#mee_install() { +# bee_install +#} +## by default this may be 'make install DESTDIR="${D}"' + +############################################################################### +## +## Additional hints: +## +## The name of this bee-file should follow the following naming convention: +## pkgname-pkgversion-pkgrevision.bee +## +## You may remove all comments as long as SRCURL[0] is set. +## +## Everything in this file will be executed in a bash environment. +## +## Build the package by executing +## './pkg-version-N.bee' or +## 'beesh ./pkg-version-N.bee' +## +## see http://beezinga.org/ +##