From owner-svn-src-head@FreeBSD.ORG Mon Oct 4 18:16:39 2010 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1B38E106566C; Mon, 4 Oct 2010 18:16:39 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0AE118FC1C; Mon, 4 Oct 2010 18:16:39 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o94IGcEv022699; Mon, 4 Oct 2010 18:16:38 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o94IGcDx022697; Mon, 4 Oct 2010 18:16:38 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201010041816.o94IGcDx022697@svn.freebsd.org> From: Dimitry Andric Date: Mon, 4 Oct 2010 18:16:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r213412 - head/lib/libvgl X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 04 Oct 2010 18:16:39 -0000 Author: dim Date: Mon Oct 4 18:16:38 2010 New Revision: 213412 URL: http://svn.freebsd.org/changeset/base/213412 Log: Change libvgl's set4pixels() and set2lines() functions from plain 'inline' to 'static inline'. Otherwise, a C99 compiler (such as clang) will output an undefined symbol for those functions in the resulting object file. (Even gcc will do this, when you use "-std=c99".) This should fix the "undefined reference to `set4pixels'" errors that some people were seeing during ports building, when their world was compiled with clang. Approved by: rpaulo (mentor) Modified: head/lib/libvgl/simple.c Modified: head/lib/libvgl/simple.c ============================================================================== --- head/lib/libvgl/simple.c Mon Oct 4 18:09:01 2010 (r213411) +++ head/lib/libvgl/simple.c Mon Oct 4 18:16:38 2010 (r213412) @@ -249,8 +249,8 @@ VGLFilledBox(VGLBitmap *object, int x1, for (y=y1; y<=y2; y++) VGLLine(object, x1, y, x2, y, color); } -void -inline set4pixels(VGLBitmap *object, int x, int y, int xc, int yc, u_long color) +static inline void +set4pixels(VGLBitmap *object, int x, int y, int xc, int yc, u_long color) { if (x!=0) { VGLSetXY(object, xc+x, yc+y, color); @@ -290,8 +290,8 @@ VGLEllipse(VGLBitmap *object, int xc, in } } -void -inline set2lines(VGLBitmap *object, int x, int y, int xc, int yc, u_long color) +static inline void +set2lines(VGLBitmap *object, int x, int y, int xc, int yc, u_long color) { if (x!=0) { VGLLine(object, xc+x, yc+y, xc-x, yc+y, color);