libgraphqlparser
                                
                                 libgraphqlparser copied to clipboard
                                
                                    libgraphqlparser copied to clipboard
                            
                            
                            
                        Getting undefined reference error when trying to compile dump_json_ast.cpp
I built the libgraphqlparser from source . All the required files (AstNode.h, GraphQLParser.h and c/GraphQLAstToJSON.h) are generated and present in the same directory. When I'm trying to compile dump_json_ast.cpp, I'm facing the following error:
/tmp/cchrLFw4.o: In function main: dump_json_ast.cpp:(.text+0x63): undefined reference to facebook::graphql::parseFile(_IO_FILE*, char const**) dump_json_ast.cpp:(.text+0xe9): undefined reference to graphql_ast_to_json collect2: error: ld returned 1 exit status
I verified and all the required files are already built and present. I'm not sure why the compiler is not able to link the reference. Use Case : I just need to have a sample graphql query parsed and print the corresponding json.