On 10/2/19 12:41 PM, Mauro Carvalho Chehab wrote:
> Em Wed, 2 Oct 2019 11:49:20 +0200
> Hans Verkuil <[email protected]> escreveu:
>
>> On 10/2/19 11:36 AM, Mauro Carvalho Chehab wrote:
>>> Em Wed, 2 Oct 2019 10:25:02 +0200
>>> Hans Verkuil <[email protected]> escreveu:
>>>
>>>> Hi Mauro,
>>>>
>>>> On 10/2/19 10:16 AM, Jenkins Builder Robot wrote:
>>>>> See
>>>>> <https://builder.linuxtv.org/job/v4l-utils/43/display/redirect?page=changes>
>>>>>
>>>>> Changes:
>>>>>
>>>>> [hverkuil-cisco] keytable: add new generated keymaps
>>>>>
>>>>> [hverkuil-cisco] msg2ctl.pl: add newline after log_msg
>>>>>
>>>>> [hverkuil-cisco] cec-follower: drop the hardcoded UI commands list
>>>>>
>>>>> [hverkuil-cisco] cec-ctl/cec-log: use new CEC_OP_UI_CMD defines
>>>>
>>>> You need to remove utils/cec-follower/cec-log.h.
>>>>
>>>> This file was generated but the generated file is now called cec-log-gen.h.
>>>> A new cec-log.h was also added to utils/common as a companion to
>>>> cec-log.cpp.
>>>>
>>>> Unfortunately, the old cec-log.h clashes with the new cec-log.h. And since
>>>> the old cec-log.h was generated and so is not part of the git repo it is
>>>> not removed as part of a 'git pull'.
>>>>
>>>> Anyway, just remove utils/cec-follower/cec-log.h and it compiles again.
>>>
>>> I manually removed the file at the builder and at the slave machines and
>>> asked for a new build. The build now succeeded.
>>>
>>> That's said, we should really avoid disruptive changes like that, fixing
>>> the building system for it to do the right thing, as users of the v4l-utils
>>> will also face the same issue if they update their git trees.
>>>
>>> At any time, a clean git update with something similar to:
>>>
>>> git remote update
>>> git fetch origin
>>> git reset --hard origin/master
>>> ./bootstrap.sh
>>> ./configure
>>> make
>>>
>>> should work.
>>>
>>> Regards,
>>> Mauro
>>>
>>
>> Yes, I discovered it too late. That said, I'm not sure what to do about
>> it since the old generated file is not under the control of git.
>>
>> A 'make distclean' before the 'git fetch' would remove it, but after the
>> update it is just an orphaned file.
>>
>> I've actually added a 'make distclean' in my daily build scripts.
>
> That's a very bad idea. The builds should check and pinpoint to
> regressions at the building system too.
>
> If I understand the problem, you're saying that now cec-log.h depends on
> the generated cec-log-gen.h, right?
>
> If so, this could be easily fixable by adding an explicit dependency
> rule to the Makefile.am, like:
>
> cec-log.h: cec-log-gen.h
No, cec-log.h has nothing to do with cec-log-gen.h.
utils/cec-follower/cec-log.h was a generated file, and badly named.
So this was renamed to cec-log-gen.h.
In addition, a new header utils/common/cec-log.h was added containing
prototypes for utils/common/cec-log.cpp.
So after a git pull you end up with two cec-log.h headers:
utils/common/cec-log.h and the orphaned utils/cec-follower/cec-log.h.
Unfortunately, the orphaned cec-log.h is included instead of the one
in utils/common.
I'm looking at reorganizing the way this works so perhaps this issue
will go away soon.
Regards,
Hans