Bug 53664 - es1_conversion.c:130:5: error: implicit declaration of function '_mesa_DrawTexf' [-Werror=implicit-function-declaration]
Summary: es1_conversion.c:130:5: error: implicit declaration of function '_mesa_DrawTe...
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Mesa core (show other bugs)
Version: git
Hardware: x86-64 (AMD64) Linux (All)
: medium blocker
Assignee: mesa-dev
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-08-18 01:28 UTC by Vinson Lee
Modified: 2012-08-18 13:55 UTC (History)
3 users (show)

See Also:
i915 platform:
i915 features:


Attachments
make log (12.00 KB, text/x-log)
2012-08-18 04:11 UTC, Darxus
Details
configure log (11.99 KB, text/x-log)
2012-08-18 04:12 UTC, Darxus
Details
config.log (102.16 KB, text/plain)
2012-08-18 05:48 UTC, Vinson Lee
Details

Description Vinson Lee 2012-08-18 01:28:27 UTC
mesa: 34472a0d8713c4eb300c9d1de0844c8b78bcf1ab (master)

$ make
[...]
  CC     es1_conversion.lo
../../src/mesa/main/es1_conversion.c: In function '_es_DrawTexxOES':
../../src/mesa/main/es1_conversion.c:130:5: error: implicit declaration of function '_mesa_DrawTexf' [-Werror=implicit-function-declaration]
../../src/mesa/main/es1_conversion.c: In function '_es_DrawTexxvOES':
../../src/mesa/main/es1_conversion.c:147:5: error: implicit declaration of function '_mesa_DrawTexfv' [-Werror=implicit-function-declaration]


34472a0d8713c4eb300c9d1de0844c8b78bcf1ab is the first bad commit
commit 34472a0d8713c4eb300c9d1de0844c8b78bcf1ab
Author: Ian Romanick <ian.d.romanick@intel.com>
Date:   Fri Jul 27 14:38:37 2012 -0700

    mesa/es: Don't generate ES1 type conversion wrappers
    
    These are gradually going to get whittled away and eventually folded into the
    source files with the native type functions.
    
    v2: Add (speculative) SConscript changes.  These may be broken.
    
    Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
    Reviewed-by: Brian Paul <brianp@vmware.com>

:040000 040000 316b3b1391077e9d035f9003301d4e426233327d c976a2a6b27c781382a7e3282f08c66fe4a4290f M	src
Comment 1 Ian Romanick 2012-08-18 02:39:37 UTC
I can't reproduce that here.  These function prototypes come from src/mesa/main/drawtex.h, which is included at line 29 of es1_conversion.c.  Is this limited to scons builds?  If you can reproduce it with automake, what options do you use?
Comment 2 Brian Paul 2012-08-18 02:49:18 UTC
I can't repro this either.
Comment 3 Ian Romanick 2012-08-18 03:16:20 UTC
The only way I could see this occurring is if FEATURE_OES_draw_texture was somehow undefined.  This only happens when FEATURE_ES1 is not defined.  In this case, es1_conversion.c shouldn't even be built.

If this is scons-only, then my speculative SConscript changes are, in fact, broken. :(
Comment 4 Darxus 2012-08-18 04:11:27 UTC
Created attachment 65721 [details]
make log

I'm also getting this.

Using:  ./autogen.sh --prefix=$installdir --enable-gles2 --disable-gallium-egl --with-egl-platforms=wayland,x11,drm --enable-gbm --enable-shared-glapi --with-gallium-drivers=r300,r600,swrast,nouveau,svga

Attaching configure and make logs.  Let me know if I can get you anything else.  I'll work on bisecting.
Comment 5 Darxus 2012-08-18 04:12:08 UTC
Created attachment 65722 [details]
configure log
Comment 6 Darxus 2012-08-18 04:14:15 UTC
First known bad commit:  34472a0d8713c4eb300c9d1de0844c8b78bcf1ab
Last known good commit:  d707e337f5f9a7b6ed465ade1b0b7c06606dde22

And they're sequential... no bisecting for me.
Comment 7 Vinson Lee 2012-08-18 05:48:17 UTC
The SCons build passes.

$ scons
[...]
scons: done building targets.


The automake build fails.

$ ./autogen.sh --with-dri-drivers=swrast --with-gallium-drivers=
[...]
        prefix:          /usr/local
        exec_prefix:     ${prefix}
        libdir:          ${exec_prefix}/lib
        includedir:      ${prefix}/include

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

        OSMesa:          no
        DRI drivers:     swrast
        DRI driver dir:  ${libdir}/dri
        GLX:             DRI-based

        GLU:             yes

        EGL:             yes
        EGL platforms:   x11
        EGL drivers:     builtin:egl_glx builtin:egl_dri2

        llvm:            no

        Gallium:         no

        Shared libs:     yes
        Static libs:     no

        CFLAGS:          -g -O2 -Wall -std=c99 -Werror=implicit-function-declaration -Werror=missing-prototypes -fno-strict-aliasing -fno-builtin-memcmp -fPIC
        CXXFLAGS:        -g -O2 -Wall -fno-strict-aliasing -fno-builtin-memcmp -fPIC
        Macros:          -D_GNU_SOURCE -DPTHREADS -DUSE_X86_64_ASM -DHAVE_POSIX_MEMALIGN -DIN_DRI_DRIVER -DUSE_XCB -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER -DHAVE_ALIAS -DHAVE_MINCORE -DHAVE_LIBUDEV

        PYTHON2:         python2

        Run 'make' to build Mesa

$ make
[...]
  CC     es1_conversion.lo
../../src/mesa/main/es1_conversion.c: In function '_es_DrawTexxOES':
../../src/mesa/main/es1_conversion.c:130:5: error: implicit declaration of function '_mesa_DrawTexf' [-Werror=implicit-function-declaration]
../../src/mesa/main/es1_conversion.c: In function '_es_DrawTexxvOES':
../../src/mesa/main/es1_conversion.c:147:5: error: implicit declaration of function '_mesa_DrawTexfv' [-Werror=implicit-function-declaration]
Comment 8 Vinson Lee 2012-08-18 05:48:51 UTC
Created attachment 65724 [details]
config.log
Comment 9 Tilman Sauerbeck 2012-08-18 09:51:52 UTC
Looks like es1_conversion.c should use #if instead of #ifdef for the FEATURE_ES1 check.

I submitted a patch to the mailing list.
Comment 10 Brian Paul 2012-08-18 13:55:01 UTC
Thanks.  I repro'd the issue here and your patch fixes it.  Thanks, Tilman!  Pushed as d0ace4e949d0e2f11e6f0fb0fd97ccde58457937


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.