Bug 38699 - Can't compile with d3d1x since commit 73df31eedd0f33c8a9907855cb247c8f87964c48
Summary: Can't compile with d3d1x since commit 73df31eedd0f33c8a9907855cb247c8f87964c48
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Other (show other bugs)
Version: git
Hardware: All All
: medium critical
Assignee: mesa-dev
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-06-26 19:15 UTC by Alexandre Demers
Modified: 2011-06-28 04:03 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Alexandre Demers 2011-06-26 19:15:01 UTC
Can't compile mesa master with d3d1x state tracker. Encountered error:
make[5]: Entering directory `/home/dema1701/projects/mesa/mesa/src/gallium/state_trackers/d3d1x/dxgi'
g++ -c -I. -I../../../../../src/gallium/include -I../../../../../src/gallium/auxiliary -I../../../../../src/gallium/drivers -I../../../../../include -Iinclude -I../gd3dapi -I../d3dapi -I../w32api -I../d3d1xstutil/include -I../include -I../../../include -I../../../auxiliary -I../../../state_trackers/egl/common -g -O2 -Wall -fno-strict-aliasing -m64 -g  -fPIC  -D_GNU_SOURCE -DPTHREADS -DDEBUG -DTEXTURE_FLOAT_ENABLED -DHAVE_POSIX_MEMALIGN -DUSE_XCB -DGLX_USE_TLS -DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER -DGLX_DIRECT_RENDERING -DGLX_INDIRECT_RENDERING -DHAVE_ALIAS -DHAVE_LIBUDEV -DHAVE_XCB_DRI2 -DXCB_DRI2_CONNECT_DEVICE_NAME_BROKEN -DHAVE_XEXTPROTO_71 -fvisibility=hidden -DDXGI_DRIVER_SEARCH_DIR=\"/usr/lib/x86_64-linux-gnu/egl\" -DGALLIUM_DXGI_USE_X11 src/dxgi_native.cpp -o src/dxgi_native.o
In file included from ../w32api/windef.h:252:0,
                 from ../w32api/windows.h:41,
                 from ../w32api/rpc.h:29,
                 from ../w32api/objbase.h:19,
                 from ../d3d1xstutil/include/d3d1xstutil.h:45,
                 from src/dxgi_private.h:34,
                 from src/dxgi_native.cpp:27:
../w32api/winnt.h:685:35: warning: attributes ignored on elaborated-type-specifier that is not a forward declaration
In file included from ../w32api/objbase.h:20:0,
                 from ../d3d1xstutil/include/d3d1xstutil.h:45,
                 from src/dxgi_private.h:34,
                 from src/dxgi_native.cpp:27:
../w32api/rpcndr.h:177:1: warning: ‘_MIDL_STUB_MESSAGE’ has a field ‘_MIDL_STUB_MESSAGE::SavedContextHandles’ whose type uses the anonymous namespace
../w32api/rpcndr.h:479:32: warning: ‘_SCONTEXT_QUEUE’ has a field ‘_SCONTEXT_QUEUE::ArrayOfObjects’ whose type uses the anonymous namespace
src/dxgi_native.cpp: In constructor ‘GalliumDXGIAdapter::GalliumDXGIAdapter(GalliumDXGIFactory*, const native_platform*, void*)’:
src/dxgi_native.cpp:263:13: error: ‘const struct native_platform’ has no member named ‘set_event_handler’
src/dxgi_native.cpp:265:54: error: too many arguments to function
src/dxgi_native.cpp:267:70: error: too many arguments to function
src/dxgi_native.cpp: In function ‘void GalliumDXGIUseX11Display(_XDisplay*, IGalliumDXGIBackend*)’:
src/dxgi_native.cpp:1430:57: error: too few arguments to function ‘const native_platform* native_get_x11_platform(const native_event_handler*)’
../../../state_trackers/egl/common/native.h:280:1: note: declared here
src/dxgi_native.cpp: In function ‘HRESULT CreateDXGIFactory1(const IID&, void**)’:
src/dxgi_native.cpp:1496:61: error: too few arguments to function ‘const native_platform* native_get_x11_platform(const native_event_handler*)’
../../../state_trackers/egl/common/native.h:280:1: note: declared here
make[5]: *** [src/dxgi_native.o] Error 1


After bisecting, culprit commit is:

commit 73df31eedd0f33c8a9907855cb247c8f87964c48
Author: Chia-I Wu <olv@lunarg.com>
Date:   Sat Jun 25 14:52:57 2011 +0900

    st/egl: reorganize backend initialization
    
    Remove set_event_handler() and pass the event handler with
    native_get_XXX_platform().  Add init_screen() so that the pipe screen is
    created later.  This way we don't need to pass user_data to
    create_display().
Comment 1 Chia-I Wu 2011-06-26 20:22:13 UTC
I've pushed a fix (compile tested).  Can you try again?
Comment 2 Alexandre Demers 2011-06-26 20:39:34 UTC
Better but it doesn't seem OK though. Here how it ends:

make[3]: Entering directory `/home/dema1701/projects/mesa/mesa/src/gallium/targets/egl-static'
/bin/bash ../../../../bin/mklib -o egl_gallium.so -noprefix -linker 'g++' \
		-L../../../../x86_64-linux-gnu -ldflags '-Wl,--no-undefined ' \
		-cplusplus -install ../../../../x86_64-linux-gnu/egl  \
		egl.o egl_pipe.o egl_st.o -Wl,--start-group ../../../../src/gallium/auxiliary/libgallium.a ../../../../src/gallium/drivers/identity/libidentity.a ../../../../src/gallium/drivers/r600/libr600.a ../../../../src/gallium/drivers/rbug/librbug.a ../../../../src/gallium/drivers/softpipe/libsoftpipe.a ../../../../src/gallium/drivers/trace/libtrace.a ../../../../src/gallium/state_trackers/egl/libegl.a ../../../../src/gallium/state_trackers/vega/libvega.a ../../../../src/gallium/winsys/r600/drm/libr600winsys.a ../../../../src/gallium/winsys/sw/xlib/libws_xlib.a ../../../../src/mesa/libmesagallium.a -Wl,--end-group \
		-L/lib/x86_64-linux-gnu -L/usr/lib/x86_64-linux-gnu -lEGL -lOpenVG -lX11 -lXext -lXfixes -ldl -ldrm -ldrm_radeon -lglapi -lm -lpthread -lrt -ludev
mklib: Making Linux shared library:  egl_gallium.so
../../../../src/gallium/state_trackers/egl/libegl.a(egl_g3d_api.o): In function `egl_g3d_choose_config':
/home/dema1701/projects/mesa/mesa/src/gallium/state_trackers/egl/common/egl_g3d_api.c:140: undefined reference to `_eglFilterConfigArray'
collect2: ld returned 1 exit status
mklib: Installing egl_gallium.so in ../../../../x86_64-linux-gnu/egl
mv: cannot stat `egl_gallium.so': No such file or directory
Comment 3 Chia-I Wu 2011-06-26 20:43:14 UTC
Does

  $ make -C src/egl clean
  $ make

help?  The symbol was introduced to libEGL in another commit.
Comment 4 Alexandre Demers 2011-06-27 08:09:27 UTC
Still there with your suggestion. Should I open a different bug report?
Comment 5 Chia-I Wu 2011-06-27 08:35:02 UTC
Yes.

It could be that the system libEGL get picked for linking and it does not have the new symbol.  Please also include the result of

  $ cd /home/dema1701/projects/mesa/mesa
  $ nm -D x86_64-linux-gnu/libEGL.so | grep _eglFilterConfigArray

in the bug report.  Thanks.


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.