Bug 92985

Summary: Mac OS X build error "ar: no archive members specified"
Product: Mesa Reporter: Vinson Lee <vlee>
Component: Mesa coreAssignee: mesa-dev
Status: RESOLVED FIXED QA Contact: mesa-dev
Severity: normal    
Priority: medium CC: emil.l.velikov, krh, martin.peres, stu_dby
Version: gitKeywords: bisected, regression
Hardware: x86-64 (AMD64)   
OS: Mac OS X (All)   
Whiteboard:
i915 platform: i915 features:

Description Vinson Lee 2015-11-18 07:53:28 UTC
mesa: dd05ffebfcb5d2e7ca44def1907aa2fbadd5e19d (master 11.1.0-devel)

Build failure on Mac OS X.


Making all in loader
/bin/sh ../../libtool  --tag=CC   --mode=link gcc  -g -O2 -Wall -std=c99 -Werror=implicit-function-declaration -Werror=missing-prototypes -fno-strict-aliasing -fno-math-errno -fno-trapping-math -fno-builtin-memcmp -Qunused-arguments    -o libloader_dri3_helper.la    
libtool: link: ar cru .libs/libloader_dri3_helper.a 
ar: no archive members specified
usage:  ar -d [-TLsv] archive file ...
	ar -m [-TLsv] archive file ...
	ar -m [-abiTLsv] position archive file ...
	ar -p [-TLsv] archive [file ...]
	ar -q [-cTLsv] archive file ...
	ar -r [-cuTLsv] archive file ...
	ar -r [-abciuTLsv] position archive file ...
	ar -t [-TLsv] archive [file ...]
	ar -x [-ouTLsv] archive [file ...]


Build error introduced with commit 6bd9ba7d07490059024d16ba32fafa1c5bb239ee "loader: Add dri3 helper".

commit 6bd9ba7d07490059024d16ba32fafa1c5bb239ee
Author: Boyan Ding <boyan.j.ding@gmail.com>
Date:   Tue Jul 21 23:43:54 2015 +0800

    loader: Add dri3 helper

    v2: From Martin Peres
     - Try to fit in the 80-col limit as much as possible

    v3: From Martin Peres
     - introduce loader_dri3_helper.la to avoid dragging the xcb dep everywhere (Kristian & Emil)
     - get rid of the width, height, dri_screen and is_different_gpu vfuncs (Kristian)
     - replace the create/destroy functions with init/fini for dri3 drawables
     - prefix static functions with dri3_ and exported ones with loader_dri3 (Emil)
     - keep the function definition consistent (Emil)

    Signed-off-by: Boyan Ding <boyan.j.ding@gmail.com>
    Signed-off-by: Martin Peres <martin.peres@linux.intel.com>
    Reviewed-by: Kristian Høgsberg <krh@bitplanet.net>
    Reviewed-by: Emil Velikov <emil.velikov@collabora.co.uk>
Comment 1 Emil Velikov 2015-11-18 13:59:59 UTC
I'm assuming that this fails as said ar expects to create a non empty archive. 
Thus moving the noinst_LTLIBRARIES += libloader_dri3_helper.la into the if HAVE_DRI3 section should fix things.

Seems that we're also missing the XCB_DRI3_CFLAGS in the src/loader/Makefile.am
Comment 2 Martin Peres 2015-11-18 14:20:31 UTC
(In reply to Emil Velikov from comment #1)
> I'm assuming that this fails as said ar expects to create a non empty
> archive. 
> Thus moving the noinst_LTLIBRARIES += libloader_dri3_helper.la into the if
> HAVE_DRI3 section should fix things.
> 
> Seems that we're also missing the XCB_DRI3_CFLAGS in the
> src/loader/Makefile.am

Pretty sure I tested that creating an empty libloader_dri3_helper.la was no problem on Linux. It may be on Mac OS.

In any case, I will add it to my list of stuff to do tomorrow, after figuring out why kwin fails when using EGL (spent some time on it today, the EGLConfig is empty(??)) and fixed the export of the symbols (unless Emil wants to do it first).
Comment 3 Emil Velikov 2015-11-18 15:10:14 UTC
(In reply to Martin Peres from comment #2)
> (In reply to Emil Velikov from comment #1)
> > I'm assuming that this fails as said ar expects to create a non empty
> > archive. 
> > Thus moving the noinst_LTLIBRARIES += libloader_dri3_helper.la into the if
> > HAVE_DRI3 section should fix things.
> > 
> > Seems that we're also missing the XCB_DRI3_CFLAGS in the
> > src/loader/Makefile.am
> 
> Pretty sure I tested that creating an empty libloader_dri3_helper.la was no
> problem on Linux. It may be on Mac OS.
> 
Same here - things work fine on my Linux boxes, and from the log this is the only thing which comes to mind.

> In any case, I will add it to my list of stuff to do tomorrow, after
> figuring out why kwin fails when using EGL (spent some time on it today, the
> EGLConfig is empty(??)) and fixed the export of the symbols (unless Emil
> wants to do it first).
Mind sending the symbols fixes to the ML - I'll take a look at adding a test to `make check' to prevent this from happening in the future. Alongside it I'll look at this bug as well.
Comment 4 Emil Velikov 2015-11-20 10:48:17 UTC
This bug should be fixed with

commit 7157085140a502a182ff0e23d30bd8e421212c42
Author: Emil Velikov <emil.velikov@collabora.com>
Date:   Thu Nov 19 15:36:03 2015 +0000

    automake: loader: don't create an empty dri3 helper


The other issues mentioned in comment 3 have been fixed with patches prior to the above referenced one.
Comment 5 Emil Velikov 2015-11-20 11:24:59 UTC
Got the wrong status - this issue should be resolved/fixed.

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.