Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 13 Feb 2012 09:32:55 GMT
From:      Changming Sun <snnn119@gmail.com>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/165089: The patch of devel/glog is a little wrong
Message-ID:  <201202130932.q1D9WtVK067587@red.freebsd.org>
Resent-Message-ID: <201202130940.q1D9e7I6098682@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         165089
>Category:       ports
>Synopsis:       The patch of devel/glog is a little wrong
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Feb 13 09:40:07 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator:     Changming Sun
>Release:        FreeBSD 9.0
>Organization:
tudou.inc.
>Environment:
FreeBSD test27.localdomain 9.0-RELEASE FreeBSD 9.0-RELEASE #0: Tue Jan  3 07:46:30 UTC 2012     root@farrell.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC  amd64
>Description:
The patch of devel/glog is a little wrong

--- src/utilities.cc.orig       2010-06-15 14:28:09.000000000 +0800
+++ src/utilities.cc    2011-04-07 17:00:18.000000000 +0800
@@ -227,8 +227,6 @@
 #ifndef __NR_gettid
 #ifdef OS_MACOSX
 #define __NR_gettid SYS_gettid
-#elif ! defined __i386__
-#error "Must define __NR_gettid for non-x86 platforms"
 #else
 #define __NR_gettid 224
 #endif


The syscall of "224" is SYS_freebsd7_msgctl

>How-To-Repeat:
portsnap fetch update
read /usr/ports/devel/glog/files/extra-patch-src-utilities.cc 
>Fix:
I don't know how to get thread id in FreeBSD.
If we don't have such a function, we can just return pid.

pid_t GetTID() {
  return getpid();                                          
}


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201202130932.q1D9WtVK067587>