Skip to content
This repository has been archived by the owner on Mar 26, 2024. It is now read-only.

compilation error on Arch Linux #5

Closed
zeptometer opened this issue Nov 18, 2013 · 2 comments
Closed

compilation error on Arch Linux #5

zeptometer opened this issue Nov 18, 2013 · 2 comments

Comments

@zeptometer
Copy link
Contributor

$ make
cd src; \
  yacc -d parse.y; \
  flex scan.l
gcc -Wall -g -DDEBUG=1 -O0 -shared src/*.c -o lib/libpicrin.so -I./include -I./extlib -lm
In file included from scan.l:6:0:
y.tab.h:113:21: warning: ‘struct parser_control’ declared inside parameter list [enabled by default]
y.tab.h:113:21: warning: its scope is only this definition or declaration, which is probably not what you want [enabled by default]
/usr/bin/ld: /tmp/ccVEtfJs.o: relocation R_X86_64_32 against `.rodata' can not be used when making a shared object; recompile with -fPIC
/tmp/ccVEtfJs.o: could not read symbols: Bad value
collect2: error: ld returned 1 exit status
Makefile:24: recipe for target 'build-lib' failed
make: *** [build-lib] Error 
@nyuichi
Copy link
Member

nyuichi commented Nov 18, 2013

@zeptometer could you attach y.tab.h?

@zeptometer
Copy link
Contributor Author

/* A Bison parser, made by GNU Bison 3.0.1.  */

/* Bison interface for Yacc-like parsers in C

   Copyright (C) 1984, 1989-1990, 2000-2013 Free Software Foundation, Inc.

   This program is free software: you can redistribute it and/or modify
   it under the terms of the GNU General Public License as published by
   the Free Software Foundation, either version 3 of the License, or
   (at your option) any later version.

   This program is distributed in the hope that it will be useful,
   but WITHOUT ANY WARRANTY; without even the implied warranty of
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
   GNU General Public License for more details.

   You should have received a copy of the GNU General Public License
   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */

/* As a special exception, you may create a larger work that contains
   part or all of the Bison parser skeleton and distribute that work
   under terms of your choice, so long as that work isn't itself a
   parser generator using the skeleton or a modified version thereof
   as a parser skeleton.  Alternatively, if you modify or redistribute
   the parser skeleton itself, you may (at your option) remove this
   special exception, which will cause the skeleton and the resulting
   Bison output files to be licensed under the GNU General Public
   License without this special exception.

   This special exception was added by the Free Software Foundation in
   version 2.2 of Bison.  */

#ifndef YY_YY_Y_TAB_H_INCLUDED
# define YY_YY_Y_TAB_H_INCLUDED
/* Debug traces.  */
#ifndef YYDEBUG
# define YYDEBUG 0
#endif
#if YYDEBUG
extern int yydebug;
#endif

/* Token type.  */
#ifndef YYTOKENTYPE
# define YYTOKENTYPE
  enum yytokentype
  {
    tDATUM_COMMENT = 258,
    tLPAREN = 259,
    tRPAREN = 260,
    tLBRACKET = 261,
    tRBRACKET = 262,
    tDOT = 263,
    tVPAREN = 264,
    tQUOTE = 265,
    tQUASIQUOTE = 266,
    tUNQUOTE = 267,
    tUNQUOTE_SPLICING = 268,
    tINT = 269,
    tBOOLEAN = 270,
    tFLOAT = 271,
    tSYMBOL = 272,
    tSTRING = 273,
    tCHAR = 274,
    tBYTEVECTOR = 275
  };
#endif
/* Tokens.  */
#define tDATUM_COMMENT 258
#define tLPAREN 259
#define tRPAREN 260
#define tLBRACKET 261
#define tRBRACKET 262
#define tDOT 263
#define tVPAREN 264
#define tQUOTE 265
#define tQUASIQUOTE 266
#define tUNQUOTE 267
#define tUNQUOTE_SPLICING 268
#define tINT 269
#define tBOOLEAN 270
#define tFLOAT 271
#define tSYMBOL 272
#define tSTRING 273
#define tCHAR 274
#define tBYTEVECTOR 275

/* Value type.  */
#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
typedef union YYSTYPE YYSTYPE;
union YYSTYPE
{
#line 143 "parse.y" /* yacc.c:1909  */

  int i;
  double f;
  char *cstr;
  char c;
  struct {
    char *dat;
    int len, capa;
  } blob;
  pic_value datum;

#line 106 "y.tab.h" /* yacc.c:1909  */
};
# define YYSTYPE_IS_TRIVIAL 1
# define YYSTYPE_IS_DECLARED 1
#endif



int yyparse (struct parser_control *p);

#endif /* !YY_YY_Y_TAB_H_INCLUDED  */

nyuichi added a commit that referenced this issue Nov 18, 2013
This reverts commit a3ac65a.
nyuichi added a commit that referenced this issue Nov 18, 2013
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants