HomePhabricator

Allow XHPAST to be built without flex and bison

Description

Allow XHPAST to be built without flex and bison

Summary:
Fixes T9289. This is a bit hacky, but feels like a reasonable workaround. Basically, add SKIP_PARSER and SKIP_SCANNER flags to the Makefile. If these flags are present then the Makefile effectively behaves like this:

%.lex.hpp %.lex.cpp: %.l
    touch $*.lex.hpp $*.lex.cpp

%.yacc.hpp %.yacc.cpp: %.y
    touch $*.yacc.hpp $*.yacc.cpp

If users are compiling XHPAST with libphutil/scripts/build_xhpast.php (which is the recommendation method) then there should be no difference here because this script will pass SKIP_PARSER=1 SKIP_LEXER=1.

Test Plan: Played around with make and confirmed that the flags behaved as expected.

Reviewers: epriestley, Blessed Reviewers

Reviewed By: epriestley, Blessed Reviewers

Subscribers: avivey, tycho.tatitscheff, Korvin

Maniphest Tasks: T9289

Differential Revision: https://secure.phabricator.com/D14376

Details

Provenance
joshuaspenceAuthored on
industryPushed on Nov 2 2015, 8:52 AM
Reviewer
Blessed Reviewers
Differential Revision
D14376: Allow XHPAST to be built without flex and bison
Parents
rPHU59f5a8d2bb82: Add scroll wrapper for big tables
Branches
Unknown
Tags
Unknown
Tasks
T9289: Unable to build XHPAST
Build Status
Buildable 8523
Build 9831: Run Core Tests