Bug 216789 - sysutils/mcelog: Updated to 148
Summary: sysutils/mcelog: Updated to 148
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Nikolai Lifanov
URL: https://github.com/andikleen/mcelog
Keywords: easy, patch-ready
Depends on:
Blocks:
 
Reported: 2017-02-04 18:30 UTC by Ultima
Modified: 2017-02-13 22:22 UTC (History)
2 users (show)

See Also:


Attachments
mcelog.diff (1.76 KB, patch)
2017-02-04 18:30 UTC, Ultima
Ultima1252: maintainer-approval+
Details | Diff
proposed mcelog patch (2.59 KB, patch)
2017-02-06 14:46 UTC, Nikolai Lifanov
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ultima 2017-02-04 18:30:37 UTC
Created attachment 179607 [details]
mcelog.diff

This is an update to mcelog to the most current version, 148.

* Updated to 148

 - Intel Xeons from Ivy Bridge onwards support a processor identification number.
 - Fix warning with gcc 6.x
 - Makefile: Make `git` check portable (POSIX compatible)
 - replace asprintf with xasprintf as per memutil.c
 - Return -ENOMEM for vasprintf in sysfs_write

portlint -AC:
WARN: Makefile: for new port, make $FreeBSD$ tag in comment section empty, to make SVN happy.
WARN: /usr/local/poudriere/ports/test/sysutils/mcelog/pkg-message: possible use of absolute pathname "/path/to/log".
0 fatal errors and 2 warnings found.


poudriere bulk -tC:
12amd64: success https://poudriere.ultimasbox.com/data/12amd64-test/2017-02-04_13h17m09s/logs/mcelog-148.log
12i386: success https://poudriere.ultimasbox.com/data/12i386-test/2017-02-04_13h17m10s/logs/mcelog-148.log
110amd64: success https://poudriere.ultimasbox.com/data/110amd64-test/2017-02-04_13h17m07s/logs/mcelog-148.log
110i386: success https://poudriere.ultimasbox.com/data/110i386-test/2017-02-04_13h17m08s/logs/mcelog-148.log
103amd64: success https://poudriere.ultimasbox.com/data/103amd64-test/2017-02-04_13h17m05s/logs/mcelog-148.log
103i386: success https://poudriere.ultimasbox.com/data/103i386-test/2017-02-04_13h17m06s/logs/mcelog-148.log
Comment 1 Nikolai Lifanov freebsd_committer freebsd_triage 2017-02-06 14:29:02 UTC
Hi!

I don't think the git version thing is desirable. We don't want to produce a different package depending on what the user has installed when building a port.
This needs to be addressed by either depending on git or removing the section.

This also highlights that the top of the file always sets prefix to /usr/local,
while PREFIX is a user-defined variable that can be set to something else.
Perhaps both this and the CFLAGS components of the patch could be replaced by adding "MAKE_ARGS+= CFLAGS=${CFLAGS} prefix=${PREFIX}" to the FreeBSD port Makefile instead?
Comment 2 Nikolai Lifanov freebsd_committer freebsd_triage 2017-02-06 14:45:01 UTC
I propose this patch instead:
Comment 3 Nikolai Lifanov freebsd_committer freebsd_triage 2017-02-06 14:46:10 UTC
Created attachment 179677 [details]
proposed mcelog patch

o respect PREFIX set in make.conf
o produce the same package regardless of whether git is installed
Comment 4 Ultima 2017-02-06 17:54:00 UTC
Comment on attachment 179677 [details]
proposed mcelog patch

Looks good to me.
Comment 5 Ultima 2017-02-06 17:54:33 UTC
Comment on attachment 179607 [details]
mcelog.diff

>Index: sysutils/mcelog/Makefile
>===================================================================
>--- sysutils/mcelog/Makefile	(revision 433327)
>+++ sysutils/mcelog/Makefile	(working copy)
>@@ -2,7 +2,7 @@
> # $FreeBSD$
> 
> PORTNAME=	mcelog
>-PORTVERSION=	147
>+PORTVERSION=	148
> DISTVERSIONPREFIX=	v
> CATEGORIES=	sysutils
> 
>Index: sysutils/mcelog/distinfo
>===================================================================
>--- sysutils/mcelog/distinfo	(revision 433327)
>+++ sysutils/mcelog/distinfo	(working copy)
>@@ -1,3 +1,3 @@
>-TIMESTAMP = 1484491926
>-SHA256 (andikleen-mcelog-v147_GH0.tar.gz) = f18c5c12a8c8addf56f66f0046a8f0c7ba262f48f95bf57abed8430df0eeebe6
>-SIZE (andikleen-mcelog-v147_GH0.tar.gz) = 296947
>+TIMESTAMP = 1486231306
>+SHA256 (andikleen-mcelog-v148_GH0.tar.gz) = 3de7312ee13b0968ae8e1aa0a77acaaee89a0ed7de45f7ce557939723df3dc04
>+SIZE (andikleen-mcelog-v148_GH0.tar.gz) = 296927
>Index: sysutils/mcelog/files/patch-Makefile
>===================================================================
>--- sysutils/mcelog/files/patch-Makefile	(revision 433327)
>+++ sysutils/mcelog/files/patch-Makefile	(working copy)
>@@ -1,4 +1,4 @@
>---- Makefile.orig	2016-10-18 22:32:19 UTC
>+--- Makefile.orig	2017-02-04 00:51:04 UTC
> +++ Makefile
> @@ -1,5 +1,4 @@
> -CFLAGS := -g -Os
>@@ -41,15 +41,6 @@
>  
>  # dbquery intentionally not installed by default
>  install: mcelog mcelog.conf mcelog.conf.5 mcelog.triggers.5
>-@@ -82,7 +88,7 @@ depend: .depend
>- 
>- version.tmp: FORCE
>- 	( echo -n "char version[] = \"" ; 	\
>--	if type -p git >/dev/null; then 	\
>-+	if command -v git >/dev/null; then 	\
>- 	if [ -d .git ] ; then 			\
>- 		git describe --tags HEAD | tr -d '\n'; 	\
>- 	else 					\
> @@ -98,8 +104,6 @@ version.c: version.tmp
>  .depend: ${SRC}
>  	${CC} -MM -I. ${SRC} > .depend.X && mv .depend.X .depend
Comment 6 Ultima 2017-02-06 17:56:37 UTC
Trying to add a +, but it won't let me =/
Comment 7 Nikolai Lifanov freebsd_committer freebsd_triage 2017-02-06 18:48:17 UTC
Hi! Don't worry about it!
Comment 8 commit-hook freebsd_committer freebsd_triage 2017-02-06 18:50:17 UTC
A commit references this bug:

Author: lifanov
Date: Mon Feb  6 18:49:27 UTC 2017
New revision: 433508
URL: https://svnweb.freebsd.org/changeset/ports/433508

Log:
  update sysutils/mcelog to 148

   - Intel Xeons from Ivy Bridge onwards support a processor identification number.
   - Fix warning with gcc 6.x
   - replace asprintf with xasprintf as per memutil.c
   - Return -ENOMEM for vasprintf in sysfs_write

  PR:		216789
  Submitted by:	ultima1252@gmail.com (maintainer)
  Reviewed by:	matthew
  Approved by:	matthew (mentor)
  Differential Revision:	https://reviews.freebsd.org/D9454

Changes:
  head/sysutils/mcelog/Makefile
  head/sysutils/mcelog/distinfo
  head/sysutils/mcelog/files/patch-Makefile
Comment 9 Nikolai Lifanov freebsd_committer freebsd_triage 2017-02-13 22:22:25 UTC
Committed, thanks!