[Mesa-users] Building OSMesa as static libraries ?

Wonwoo Lee wwlee06 at gmail.com
Fri Jul 12 01:40:00 PDT 2013


Hello.

I have been trying to build OSMesa as a static library, to remove
dependency on OSMesa when I distribute binaries.

However, I do not see a static library libOSMesa.a in Mesa-9.1.4/lib after
build finished.  I don't even see libOSMesa.so.8.0.0 which libOSMesa.so is
linked to.
Does anybody know how to build OSMesa as a static library ?

What I got in lib directory after build finished are as follows :

drwxrwxr-x  3 wlee wlee    4096 Jul 12 10:27 .
drwxrwxr-x 11 wlee wlee    4096 Jul 12 10:32 ..
drwxrwxr-x  2 wlee wlee    4096 Jul 12 10:21 gallium
-rwxrwxr-x  2 wlee wlee 3050908 Jul 12 10:17 i915_dri.so
-rwxrwxr-x  2 wlee wlee 8611291 Jul 12 10:18 i965_dri.so
lrwxrwxrwx  1 wlee wlee      11 Jul 12 09:45 libEGL.so -> libEGL.so.1
-rwxrwxr-x  1 wlee wlee  394044 Jul 12 09:45 libEGL.so.1
lrwxrwxrwx  1 wlee wlee      13 Jul 12 10:12 libglapi.so -> libglapi.so.0
lrwxrwxrwx  1 wlee wlee      17 Jul 12 10:12 libglapi.so.0 ->
libglapi.so.0.0.0
-rwxrwxr-x  2 wlee wlee  978056 Jul 12 10:12 libglapi.so.0.0.0
lrwxrwxrwx  1 wlee wlee      10 Jul 12 10:19 libGL.so -> libGL.so.1
-rwxrwxr-x  2 wlee wlee 2863707 Jul 12 10:19 libGL.so.1
lrwxrwxrwx  1 wlee wlee      18 Jul 12 10:18 libOSMesa.so ->
libOSMesa.so.8.0.0
lrwxrwxrwx  1 wlee wlee      18 Jul 12 10:18 libOSMesa.so.8 ->
libOSMesa.so.8.0.0
-rwxrwxr-x  2 wlee wlee 2416640 Jul 12 10:18 nouveau_vieux_dri.so
-rwxrwxr-x  2 wlee wlee 2399741 Jul 12 10:18 r200_dri.so
-rwxrwxr-x  2 wlee wlee 2236930 Jul 12 10:18 radeon_dri.so
-rwxrwxr-x  2 wlee wlee  149592 Jul 12 10:18 swrast_dri.so



I configured it with the following option :
./configure --enable-osmesa --disable-dri --enable-static

and the it gave me the followings:

        prefix:          /usr/local
        exec_prefix:     ${prefix}
        libdir:          ${exec_prefix}/lib
        includedir:      ${prefix}/include

        OpenGL:          yes (ES1: no ES2: no)
        OpenVG:          no

        OSMesa:          libOSMesa
        GLX:             no

        EGL:             no

        llvm:            yes
        llvm-config:     /usr/bin/llvm-config
        llvm-version:    2.9

        Gallium:         yes
        Gallium dirs:    auxiliary drivers state_trackers
        Target dirs:
        Winsys dirs:     sw
        Driver dirs:     galahad identity llvmpipe noop r300 r600 rbug
softpipe svga trace
        Trackers dirs:

        Shared libs:     no
        Static libs:     yes
        Shared-glapi:    no

        CFLAGS:          -g -O2 -Wall -std=c99
-Werror=implicit-function-declaration -Werror=missing-prototypes
-fno-strict-aliasing -fno-builtin-memcmp
        CXXFLAGS:        -g -O2 -Wall -fno-strict-aliasing
-fno-builtin-memcmp
        Macros:          -D_GNU_SOURCE -DHAVE_PTHREAD -DUSE_X86_64_ASM
-DHAVE_DLOPEN -DHAVE_POSIX_MEMALIGN -DHAVE_LLVM=0x0209

        LLVM_CFLAGS:     -I/usr/lib/llvm-2.9/include  -D_GNU_SOURCE
-D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS
        LLVM_CXXFLAGS:   -I/usr/lib/llvm-2.9/include  -D_GNU_SOURCE
-D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS    -fno-exceptions -fPIC
-Woverloaded-virtual -Wcast-qual
        LLVM_CPPFLAGS:   -I/usr/lib/llvm-2.9/include  -D_GNU_SOURCE
-D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS

        PYTHON2:         python2

        Run 'make' to build Mesa


Thanks in advance.
Wonwoo Lee
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/mesa-users/attachments/20130712/f4191c55/attachment.html>


More information about the mesa-users mailing list