← Back to team overview

kicad-developers team mailing list archive

Re: Problem compiling 5.1, maybe from commit 2975e859500

 

On 9/14/21 10:05 AM, Steven A. Falco wrote:
> Thanks, Jeff.  It looks like "make clean" does the right thing - it
> removes "include/page_layout_reader_lexer.h", among others.
> 
> I was used to just blowing away the build directory to clean up, but now
> I know that that is not sufficient for KiCAD, because it writes
> generated files into its source area.

In master, the generated files are written to the build directory.  This
only applies to the 5.1 branch.

> 
> And of course there is always "git clean -fdx" when you really want a
> pristine tree. :-)
> 
>     Steve
> 
> On 9/14/21 09:52, Jeff Young wrote:
>> This normally happens when you’re building both 5.1 and 5.99 in a
>> single tree.  I have to delete them a lot as I do that.
>>
>> But I haven’t a clue how it’s /supposed/ to be.  When I have a working
>> build (even if it’s clunky), I tend to be very hesitant to change
>> /anything/. ;)
>>
>>> On 14 Sep 2021, at 14:27, Steven A. Falco <stevenfalco@xxxxxxxxx
>>> <mailto:stevenfalco@xxxxxxxxx>> wrote:
>>>
>>> It looks like the problem is that the definition of T_kicad_wks
>>> appears in a generated file: include/page_layout_reader_lexer.h
>>>
>>> However, while I do "out of tree" builds, page_layout_reader_lexer.h
>>> is not created in the build directory, but rather it is created in
>>> the source directory.
>>>
>>> So when I deleted my build directory to force a clean build,
>>> page_layout_reader_lexer.h was not deleted / re-created, hence the
>>> new definition was not found.
>>>
>>> Is the intention to have page_layout_reader_lexer.h be created in the
>>> source directory or in the build directory?
>>>
>>> Steve
>>>
>>> On 9/13/21 17:17, Steven A. Falco wrote:
>>>> I'm getting the following error compiling the 5.1 branch:
>>>> /home/sfalco/src/kicad/kicad5/gitlab/code/kicad-5.1/common/page_layout/page_layout_reader.cpp:
>>>> In member function ‘void
>>>> PAGE_LAYOUT_READER_PARSER::Parse(WORKSHEET_LAYOUT*)’:
>>>> /home/sfalco/src/kicad/kicad5/gitlab/code/kicad-5.1/common/page_layout/page_layout_reader.cpp:131:22:
>>>> error: ‘T_kicad_wks’ was not declared in this scope
>>>>   131 |         if( token == T_kicad_wks || token == T_drawing_sheet )
>>>>       |                      ^~~~~~~~~~~
>>>> /home/sfalco/src/kicad/kicad5/gitlab/code/kicad-5.1/common/page_layout/page_layout_reader.cpp:131:46:
>>>> error: ‘T_drawing_sheet’ was not declared in this scope
>>>>   131 |         if( token == T_kicad_wks || token == T_drawing_sheet )
>>>>       |                                              ^~~~~~~~~~~~~~~
>>>> This appears to be due to commit 2975e859500, which added this code:
>>>> +        if( token == T_kicad_wks || token == T_drawing_sheet )
>>>> +        {
>>>> +            THROW_PARSE_ERROR( _( "KiCad was unable to open this
>>>> file because it was created with "
>>>> +                                  "a more recent version than the
>>>> one you are running.\n\n"
>>>> +                                  "To open it you will need to
>>>> upgrade KiCad to 5.99 or later." ),
>>>> +                               CurSource(), CurLine(),
>>>> CurLineNumber(), CurOffset() );
>>>> +        }
>>>> +
>>>>     Steve
>>>
>>>
>>> _______________________________________________
>>> Mailing list: https://launchpad.net/~kicad-developers
>>> <https://launchpad.net/~kicad-developers>
>>> Post to     : kicad-developers@xxxxxxxxxxxxxxxxxxx
>>> <mailto:kicad-developers@xxxxxxxxxxxxxxxxxxx>
>>> Unsubscribe : https://launchpad.net/~kicad-developers
>>> <https://launchpad.net/~kicad-developers>
>>> More help   : https://help.launchpad.net/ListHelp
>>> <https://help.launchpad.net/ListHelp>
>>
> 
> 
> _______________________________________________
> Mailing list: https://launchpad.net/~kicad-developers
> Post to     : kicad-developers@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~kicad-developers
> More help   : https://help.launchpad.net/ListHelp


Follow ups

References