summaryrefslogtreecommitdiffstats
path: root/lib/libvgl
diff options
context:
space:
mode:
authordim <dim@FreeBSD.org>2010-10-04 18:16:38 +0000
committerdim <dim@FreeBSD.org>2010-10-04 18:16:38 +0000
commit3bbacb240e75ca4266dba7678b9250f24179b689 (patch)
tree7642b88cfa8ae54bf33d55e872dead4e2e12cfd1 /lib/libvgl
parentd013da415dd2b7a8073b2660fb947ff690541886 (diff)
downloadFreeBSD-src-3bbacb240e75ca4266dba7678b9250f24179b689.zip
FreeBSD-src-3bbacb240e75ca4266dba7678b9250f24179b689.tar.gz
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)
Diffstat (limited to 'lib/libvgl')
-rw-r--r--lib/libvgl/simple.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/libvgl/simple.c b/lib/libvgl/simple.c
index b7d789a..09ca9b0 100644
--- a/lib/libvgl/simple.c
+++ b/lib/libvgl/simple.c
@@ -249,8 +249,8 @@ VGLFilledBox(VGLBitmap *object, int x1, int y1, int x2, int y2, u_long color)
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, int yc, int a, int b, u_long color)
}
}
-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);
OpenPOWER on IntegriCloud