Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error when i try to make the package #3

Open
GoogleCodeExporter opened this issue Jun 19, 2015 · 15 comments
Open

Error when i try to make the package #3

GoogleCodeExporter opened this issue Jun 19, 2015 · 15 comments

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1. unrar the package
2. try to make
3. error

What is the expected output? What do you see instead?
ns27731:/pdf2image# make
cd goo; make
make[1]: entrant dans le répertoire « /pdf2image/goo »
g++ -I/usr/local/include/freetype2 -I/usr/local/include -g -O2 -DHAVE_CONFIG_H 
-I.. -I. -c gfile.cc
In file included from gfile.cc:33:
gfile.h:131: error: ISO C++ forbids declaration of 'DIR' with no type
gfile.h:131: error: expected ';' before '*' token
gfile.cc: In constructor 'GDir::GDir(char*, GBool)':
gfile.cc:644: error: 'dir' was not declared in this scope
gfile.cc:644: error: 'opendir' was not declared in this scope
gfile.cc: In destructor 'GDir::~GDir()':
gfile.cc:661: error: 'dir' was not declared in this scope
gfile.cc:662: error: 'closedir' was not declared in this scope
gfile.cc: In member function 'GDirEntry* GDir::getNextEntry()':
gfile.cc:698: error: 'dir' was not declared in this scope
gfile.cc:699: error: 'readdir' was not declared in this scope
gfile.cc:700: error: invalid use of incomplete type 'struct direct'
gfile.cc:696: error: forward declaration of 'struct direct'
gfile.cc:704: error: invalid use of incomplete type 'struct direct'
gfile.cc:696: error: forward declaration of 'struct direct'
gfile.cc: In member function 'void GDir::rewind()':
gfile.cc:725: error: 'dir' was not declared in this scope
gfile.cc:726: error: 'rewinddir' was not declared in this scope
make[1]: *** [gfile.o] Erreur 1
make[1]: quittant le répertoire « /pdf2image/goo »
make: *** [all] Erreur 2
ns27731:/pdf2image#


What version of the product are you using? On what operating system?
pdf2image-0.49.tar.gz // ubuntu x86

Please provide any additional information below.
i already install ghostscript and freetype. and i have swftools installed on my 
machine (and working)

Original issue reported on code.google.com by vincent....@gmail.com on 21 Apr 2011 at 8:55

@GoogleCodeExporter
Copy link
Author

I'm having the same problem on my install of CentOS 5

Original comment by wasted.d...@gmail.com on 29 Apr 2011 at 7:04

@GoogleCodeExporter
Copy link
Author

UPDATE:  I resolved the issue for myself.  There's something not working quite 
right with the preprocessor directives in goo/gfile.h.  I think they're trying 
to figure out what operating system we're using and including the appropriate 
directory library.  I think it just never included one for me.  I added the 
line:

#include <sys/dir.h>

To just override all that and include it for me.  Everything compiled and I'm 
rocking now.

Original comment by wasted.d...@gmail.com on 29 Apr 2011 at 7:44

@GoogleCodeExporter
Copy link
Author

ok.

let's rock

i try this monday and i give you some advice.

thanks for comments :)

Original comment by vincent....@gmail.com on 30 Apr 2011 at 1:02

@GoogleCodeExporter
Copy link
Author

Hello I'm Vincent's co worker, we managed to fix it adding this line instead of 
yours :
#include </usr/include/sys/dir.h>

By the way we were working on Debian GNU/Linux 4.0

Looks like sys/dir.h location depends on the OS.
Anyway we managed to compile then make install !

I hope this might help some other.

Thanks for the tip ;)


Original comment by antonin....@gmail.com on 2 May 2011 at 12:18

@GoogleCodeExporter
Copy link
Author

I'm having the same problem on Ubuntu 10.04 and not able to resolve it.

Original comment by sushil.k...@gmail.com on 7 Jun 2011 at 12:44

@GoogleCodeExporter
Copy link
Author

[root@localhost pff2image]# make
cd goo; make
make[1]: Entering directory `/root/pff2image/goo'
g++ -I/usr/local/include/freetype2 -I/usr/local/include -g -O2 -DHAVE_CONFIG_H 
-I.. -I. -c GHash.cc
g++ -I/usr/local/include/freetype2 -I/usr/local/include -g -O2 -DHAVE_CONFIG_H 
-I.. -I. -c GList.cc
g++ -I/usr/local/include/freetype2 -I/usr/local/include -g -O2 -DHAVE_CONFIG_H 
-I.. -I. -c GString.cc
g++ -I/usr/local/include/freetype2 -I/usr/local/include -g -O2 -DHAVE_CONFIG_H 
-I.. -I. -c gmem.cc
g++ -I/usr/local/include/freetype2 -I/usr/local/include -g -O2 -DHAVE_CONFIG_H 
-I.. -I. -c gmempp.cc
g++ -I/usr/local/include/freetype2 -I/usr/local/include -g -O2 -DHAVE_CONFIG_H 
-I.. -I. -c gfile.cc
g++ -I/usr/local/include/freetype2 -I/usr/local/include -g -O2 -DHAVE_CONFIG_H 
-I.. -I. -c FixedPoint.cc
gcc -g -O2 -DHAVE_CONFIG_H -I.. -I.   -c -o parseargs.o parseargs.c
rm -f libGoo.a
ar rc libGoo.a GHash.o GList.o GString.o gmem.o gmempp.o gfile.o FixedPoint.o 
parseargs.o
ranlib libGoo.a
make[1]: Leaving directory `/root/pff2image/goo'
cd fofi; make
make[1]: Entering directory `/root/pff2image/fofi'
g++ -I/usr/local/include/freetype2 -I/usr/local/include -g -O2 -DHAVE_CONFIG_H 
-I.. -I./../goo -I. -c FoFiBase.cc
g++ -I/usr/local/include/freetype2 -I/usr/local/include -g -O2 -DHAVE_CONFIG_H 
-I.. -I./../goo -I. -c FoFiEncodings.cc
g++ -I/usr/local/include/freetype2 -I/usr/local/include -g -O2 -DHAVE_CONFIG_H 
-I.. -I./../goo -I. -c FoFiTrueType.cc
g++ -I/usr/local/include/freetype2 -I/usr/local/include -g -O2 -DHAVE_CONFIG_H 
-I.. -I./../goo -I. -c FoFiType1.cc
g++ -I/usr/local/include/freetype2 -I/usr/local/include -g -O2 -DHAVE_CONFIG_H 
-I.. -I./../goo -I. -c FoFiType1C.cc
rm -f libfofi.a
ar rc libfofi.a FoFiBase.o FoFiEncodings.o FoFiTrueType.o FoFiType1.o 
FoFiType1C.o
ranlib libfofi.a
make[1]: Leaving directory `/root/pff2image/fofi'
cd splash; make
make[1]: Entering directory `/root/pff2image/splash'
g++ -I/usr/local/include/freetype2 -I/usr/local/include -DHAVE_CONFIG_H -I.. 
-I./../goo -I./../fofi -I.   -c Splash.cc
g++ -I/usr/local/include/freetype2 -I/usr/local/include -DHAVE_CONFIG_H -I.. 
-I./../goo -I./../fofi -I.   -c SplashBitmap.cc
g++ -I/usr/local/include/freetype2 -I/usr/local/include -DHAVE_CONFIG_H -I.. 
-I./../goo -I./../fofi -I.   -c SplashClip.cc
g++ -I/usr/local/include/freetype2 -I/usr/local/include -DHAVE_CONFIG_H -I.. 
-I./../goo -I./../fofi -I.   -c SplashFTFont.cc
In file included from SplashFTFont.cc:15:
/usr/include/ft2build.h:56:38: error: freetype/config/ftheader.h: No such file 
or directory
SplashFTFont.cc:16:10: error: #include expects "FILENAME" or <FILENAME>
SplashFTFont.cc:17:10: error: #include expects "FILENAME" or <FILENAME>
SplashFTFont.cc:18:10: error: #include expects "FILENAME" or <FILENAME>
In file included from SplashFTFont.cc:23:
SplashFTFontEngine.h:19:10: error: #include expects "FILENAME" or <FILENAME>
In file included from SplashFTFont.cc:24:
SplashFTFontFile.h:19:10: error: #include expects "FILENAME" or <FILENAME>
In file included from SplashFTFont.cc:25:
SplashFTFont.h:19:10: error: #include expects "FILENAME" or <FILENAME>
SplashFTFontEngine.h:53: error: âFT_Libraryâ has not been declared
SplashFTFontEngine.h:56: error: âFT_Libraryâ does not name a type
SplashFTFontFile.h:58: error: âFT_Faceâ has not been declared
SplashFTFontFile.h:63: error: âFT_Faceâ does not name a type
SplashFTFont.h:50: error: âFT_Sizeâ does not name a type
SplashFTFont.h:51: error: âFT_Matrixâ does not name a type
SplashFTFont.h:52: error: âFT_Matrixâ does not name a type
SplashFTFont.cc:29: error: expected â,â or â...â before â*â token
SplashFTFont.cc:29: error: ISO C++ forbids declaration of âFT_Vectorâ with no 
type
SplashFTFont.cc:30: error: expected â,â or â...â before â*â token
SplashFTFont.cc:30: error: ISO C++ forbids declaration of âFT_Vectorâ with no 
type
SplashFTFont.cc:31: error: expected â,â or â...â before â*â token
SplashFTFont.cc:32: error: ISO C++ forbids declaration of âFT_Vectorâ with no 
type
SplashFTFont.cc:33: error: expected â,â or â...â before â*â token
SplashFTFont.cc:34: error: ISO C++ forbids declaration of âFT_Vectorâ with no 
type
SplashFTFont.cc: In constructor âSplashFTFont::SplashFTFont(SplashFTFontFile*, 
SplashCoord*, SplashCoord*)â:
SplashFTFont.cc:44: error: âFT_Faceâ was not declared in this scope
SplashFTFont.cc:44: error: expected `;' before âfaceâ
SplashFTFont.cc:48: error: âfaceâ was not declared in this scope
SplashFTFont.cc:48: error: âclass SplashFTFontFileâ has no member named 
âfaceâ
SplashFTFont.cc:49: error: âsizeObjâ was not declared in this scope
SplashFTFont.cc:49: error: âFT_New_Sizeâ was not declared in this scope
SplashFTFont.cc:52: error: âsizeObjâ was not declared in this scope
SplashFTFont.cc:54: error: âFT_Set_Pixel_Sizesâ was not declared in this scope
SplashFTFont.cc:135: error: âmatrixâ was not declared in this scope
SplashFTFont.cc:135: error: âFT_Fixedâ was not declared in this scope
SplashFTFont.cc:139: error: âtextMatrixâ was not declared in this scope
SplashFTFont.cc: In member function âvirtual GBool 
SplashFTFont::makeGlyph(int, int, int, SplashGlyphBitmap*)â:
SplashFTFont.cc:157: error: âFT_Vectorâ was not declared in this scope
SplashFTFont.cc:157: error: expected `;' before âoffsetâ
SplashFTFont.cc:158: error: âFT_GlyphSlotâ was not declared in this scope
SplashFTFont.cc:158: error: expected `;' before âslotâ
SplashFTFont.cc:159: error: âFT_UIntâ was not declared in this scope
SplashFTFont.cc:159: error: expected `;' before âgidâ
SplashFTFont.cc:166: error: âclass SplashFTFontFileâ has no member named 
âfaceâ
SplashFTFont.cc:166: error: âsizeObjâ was not declared in this scope
SplashFTFont.cc:167: error: âoffsetâ was not declared in this scope
SplashFTFont.cc:167: error: âFT_Posâ was not declared in this scope
SplashFTFont.cc:167: error: expected primary-expression before âintâ
SplashFTFont.cc:169: error: âclass SplashFTFontFileâ has no member named 
âfaceâ
SplashFTFont.cc:169: error: âmatrixâ was not declared in this scope
SplashFTFont.cc:169: error: âFT_Set_Transformâ was not declared in this scope
SplashFTFont.cc:170: error: âslotâ was not declared in this scope
SplashFTFont.cc:170: error: âclass SplashFTFontFileâ has no member named 
âfaceâ
SplashFTFont.cc:173: error: âgidâ was not declared in this scope
SplashFTFont.cc:173: error: expected `;' before âffâ
SplashFTFont.cc:175: error: âgidâ was not declared in this scope
SplashFTFont.cc:175: error: expected `;' before âcâ
SplashFTFont.cc:177: error: âgidâ was not declared in this scope
SplashFTFont.cc:193: error: âclass SplashFTFontFileâ has no member named 
âfaceâ
SplashFTFont.cc:193: error: âgidâ was not declared in this scope
SplashFTFont.cc:194: error: âFT_LOAD_NO_HINTINGâ was not declared in this 
scope
SplashFTFont.cc:194: error: âFT_LOAD_NO_BITMAPâ was not declared in this scope
SplashFTFont.cc:195: error: âFT_LOAD_DEFAULTâ was not declared in this scope
SplashFTFont.cc:195: error: âFT_Load_Glyphâ was not declared in this scope
SplashFTFont.cc:199: error: âft_render_mode_normalâ was not declared in this 
scope
SplashFTFont.cc:200: error: âft_render_mode_monoâ was not declared in this 
scope
SplashFTFont.cc:200: error: âFT_Render_Glyphâ was not declared in this scope
SplashFTFont.cc:219: error: âmemcpyâ was not declared in this scope
SplashFTFont.cc: In member function âvirtual SplashPath* 
SplashFTFont::getGlyphPath(int)â:
SplashFTFont.cc:232: error: âFT_Outline_Funcsâ does not name a type
SplashFTFont.cc:248: error: âFT_GlyphSlotâ was not declared in this scope
SplashFTFont.cc:248: error: expected `;' before âslotâ
SplashFTFont.cc:249: error: âFT_UIntâ was not declared in this scope
SplashFTFont.cc:249: error: expected `;' before âgidâ
SplashFTFont.cc:250: error: âFT_Glyphâ was not declared in this scope
SplashFTFont.cc:250: error: expected `;' before âglyphâ
SplashFTFont.cc:253: error: âclass SplashFTFontFileâ has no member named 
âfaceâ
SplashFTFont.cc:253: error: âsizeObjâ was not declared in this scope
SplashFTFont.cc:254: error: âclass SplashFTFontFileâ has no member named 
âfaceâ
SplashFTFont.cc:254: error: âtextMatrixâ was not declared in this scope
SplashFTFont.cc:254: error: âFT_Set_Transformâ was not declared in this scope
SplashFTFont.cc:255: error: âslotâ was not declared in this scope
SplashFTFont.cc:255: error: âclass SplashFTFontFileâ has no member named 
âfaceâ
SplashFTFont.cc:257: error: âgidâ was not declared in this scope
SplashFTFont.cc:259: error: âgidâ was not declared in this scope
SplashFTFont.cc:259: error: expected `;' before âcâ
SplashFTFont.cc:261: error: âgidâ was not declared in this scope
SplashFTFont.cc:265: error: âclass SplashFTFontFileâ has no member named 
âfaceâ
SplashFTFont.cc:265: error: âgidâ was not declared in this scope
SplashFTFont.cc:265: error: âFT_LOAD_NO_BITMAPâ was not declared in this scope
SplashFTFont.cc:265: error: âFT_Load_Glyphâ was not declared in this scope
SplashFTFont.cc:268: error: âglyphâ was not declared in this scope
SplashFTFont.cc:268: error: âFT_Get_Glyphâ was not declared in this scope
SplashFTFont.cc:274: error: âFT_OutlineGlyphâ was not declared in this scope
SplashFTFont.cc:274: error: expected `)' before âglyphâ
SplashFTFont.cc:279: error: âglyphâ was not declared in this scope
SplashFTFont.cc:279: error: âFT_Done_Glyphâ was not declared in this scope
SplashFTFont.cc: At global scope:
SplashFTFont.cc:283: error: expected â,â or â...â before â*â token
SplashFTFont.cc:283: error: ISO C++ forbids declaration of âFT_Vectorâ with 
no type
SplashFTFont.cc: In function âint glyphPathMoveTo(int)â:
SplashFTFont.cc:284: error: âpathâ was not declared in this scope
SplashFTFont.cc:290: error: âptâ was not declared in this scope
SplashFTFont.cc: At global scope:
SplashFTFont.cc:295: error: expected â,â or â...â before â*â token
SplashFTFont.cc:295: error: ISO C++ forbids declaration of âFT_Vectorâ with 
no type
SplashFTFont.cc: In function âint glyphPathLineTo(int)â:
SplashFTFont.cc:296: error: âpathâ was not declared in this scope
SplashFTFont.cc:298: error: âptâ was not declared in this scope
SplashFTFont.cc: At global scope:
SplashFTFont.cc:304: error: expected â,â or â...â before â*â token
SplashFTFont.cc:305: error: ISO C++ forbids declaration of âFT_Vectorâ with 
no type
SplashFTFont.cc: In function âint glyphPathConicTo(int)â:
SplashFTFont.cc:306: error: âpathâ was not declared in this scope
SplashFTFont.cc:312: error: âctrlâ was not declared in this scope
SplashFTFont.cc:314: error: âptâ was not declared in this scope
SplashFTFont.cc: At global scope:
SplashFTFont.cc:343: error: expected â,â or â...â before â*â token
SplashFTFont.cc:344: error: ISO C++ forbids declaration of âFT_Vectorâ with 
no type
SplashFTFont.cc: In function âint glyphPathCubicTo(int)â:
SplashFTFont.cc:345: error: âpathâ was not declared in this scope
SplashFTFont.cc:347: error: âctrl1â was not declared in this scope
SplashFTFont.cc:349: error: âctrl2â was not declared in this scope
SplashFTFont.cc:351: error: âptâ was not declared in this scope
make[1]: *** [SplashFTFont.o] Error 1
make[1]: Leaving directory `/root/pff2image/splash'
make: *** [all] Error 2
pls, help me

Original comment by nguyenho...@gmail.com on 15 Nov 2011 at 4:29

@GoogleCodeExporter
Copy link
Author

my ghostscript 

GPL Ghostscript 8.70 (2009-07-31)
Copyright (C) 2009 Artifex Software, Inc.  All rights reserved.

Original comment by nguyenho...@gmail.com on 24 Nov 2011 at 4:16

@GoogleCodeExporter
Copy link
Author

resolved it :
cp freetype.win32/include/freetype /pdf2image
make 
make install

Original comment by nguyenho...@gmail.com on 24 Nov 2011 at 9:58

@GoogleCodeExporter
Copy link
Author

I copied the freetype dir into pdf2image folder. changed the makefile to 
include them. it worked with splash. but now i'm stuck at xpdf. I'm using the 
same path. any idea where to find library for -lfreetype?

Using mac Lion 10.7.2 and installed freetype with macports

~/Downloads/pdf2image-0.51 Fri Dec 30 18:31:32>make
cd goo; make
make[1]: Nothing to be done for `all'.
cd fofi; make
make[1]: Nothing to be done for `all'.
cd splash; make
make[1]: Nothing to be done for `all'.
cd xpdf; make
g++ -I~/Downloads/pdf2image-0.51/freetype2 -I/opt/local/include -DHAVE_CONFIG_H 
-I.. -I./../goo -I./../fofi -I./../splash -I.            -o pdftops Annot.o 
Array.o BuiltinFont.o BuiltinFontTables.o Catalog.o CharCodeToUnicode.o CMap.o 
Decrypt.o Dict.o Error.o FontEncodingTables.o Function.o Gfx.o GfxFont.o 
GfxState.o GlobalParams.o JArithmeticDecoder.o JBIG2Stream.o JPXStream.o 
Lexer.o Link.o NameToCharCode.o Outline.o Object.o OutputDev.o Page.o Parser.o 
PDFDoc.o PDFDocEncoding.o PreScanOutputDev.o PSOutputDev.o PSTokenizer.o 
SecurityHandler.o SplashOutputDev.o Stream.o UnicodeMap.o XpdfPluginAPI.o 
XRef.o pdftops.o \
        -L../goo -lGoo -L../splash -lsplash -lfreetype -lGoo -L../fofi -lfofi -L../goo -lGoo -lm
ld: library not found for -lfreetype
collect2: ld returned 1 exit status
make[1]: *** [pdftops] Error 1
make: *** [all] Error 2

Original comment by roy.wong...@gmail.com on 30 Dec 2011 at 10:34

@GoogleCodeExporter
Copy link
Author

update: same error using centos 5.6 final.

Original comment by roy.wong...@gmail.com on 3 Jan 2012 at 8:09

@GoogleCodeExporter
Copy link
Author

Try using the latest ./configure script if this still has not been resolved

Original comment by pdf2im...@devaldi.com on 9 Jan 2012 at 1:08

  • Changed state: Accepted

@GoogleCodeExporter
Copy link
Author

Still having the error below with the ./configure

cd goo; make
make[1]: Entering directory `/root/Downloads/pdf2image0.52/goo'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/root/Downloads/pdf2image0.52/goo'
cd fofi; make
make[1]: Entering directory `/root/Downloads/pdf2image0.52/fofi'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/root/Downloads/pdf2image0.52/fofi'
cd splash; make
make[1]: Entering directory `/root/Downloads/pdf2image0.52/splash'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/root/Downloads/pdf2image0.52/splash'
cd xpdf; make
make[1]: Entering directory `/root/Downloads/pdf2image0.52/xpdf'
g++ -I/usr/local/include/freetype2 -I/usr/local/include -g -O2 -DHAVE_CONFIG_H 
-I.. -I./../goo -I./../fofi -I./../splash -I.  -o pdftops Annot.o Array.o 
BuiltinFont.o BuiltinFontTables.o Catalog.o CharCodeToUnicode.o CMap.o 
Decrypt.o Dict.o Error.o FontEncodingTables.o Function.o Gfx.o GfxFont.o 
GfxState.o GlobalParams.o JArithmeticDecoder.o JBIG2Stream.o JPXStream.o 
Lexer.o Link.o NameToCharCode.o Outline.o Object.o OutputDev.o Page.o Parser.o 
PDFDoc.o PDFDocEncoding.o PreScanOutputDev.o PSOutputDev.o PSTokenizer.o 
SecurityHandler.o SplashOutputDev.o Stream.o UnicodeMap.o XpdfPluginAPI.o 
XRef.o pdftops.o \
        -L../goo -lGoo -L../splash -lsplash -lfreetype -lGoo -L../fofi -lfofi -L../goo -lGoo -lm
/usr/bin/ld: cannot find -lfreetype
collect2: ld returned 1 exit status
make[1]: *** [pdftops] Error 1
make[1]: Leaving directory `/root/Downloads/pdf2image0.52/xpdf'
make: *** [all] Error 2

Original comment by roy.wong...@gmail.com on 9 Jan 2012 at 4:13

@GoogleCodeExporter
Copy link
Author

[deleted comment]

@GoogleCodeExporter
Copy link
Author

Hi, just tried 0.53 source on both Mac Lion and Centos 5.6 and both have the 
same errors. Pls help.

ld: library not found for -lfreetype
collect2: ld returned 1 exit status
make[1]: *** [pdftops] Error 1
make: *** [all] Error 2
~/Downloads/pdf2image-0.53-source Mon Jan 16 13:20:35>sudo make install
Password:
mkdir -p /usr/local/bin
/usr/bin/install -c xpdf/pdftops /usr/local/bin/pdftops
install: xpdf/pdftops: No such file or directory
make: *** [install] Error 71

Original comment by roy.wong...@gmail.com on 16 Jan 2012 at 5:31

@GoogleCodeExporter
Copy link
Author

Hi. same problem occurs on Xubuntu x64 for both 0.52 and 0.53 versions:

ld: library not found for -lfreetype
collect2: ld returned 1 exit status
make[1]: *** [pdftops] Error 1
make: *** [all] Error 2

Original comment by Nevil.N...@gmail.com on 2 Feb 2012 at 8:21

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant