问题描述
我正在尝试从fedora机器上的源代码构建pdftk.我解压缩了pdftk jar并尝试执行
I am trying to build pdftk from source on fedora machine. I have unzip pdftk jar and trying to execute
make -f Makefile.Redhat
但是我的控制台出现以下错误.
But i am getting following error on my console.
gcjh-4.7.2 -force --classpath="/usr/share/java/libgcj-4.7.2.jar:/home/tw1/pdftk-1.45-dist/java:." org/bouncycastle/asn1/ASN1ObjectParser
/bin/sh: gcjh-4.7.2: command not found
make[1]: [org/bouncycastle/asn1/ASN1ObjectParser.h] Error 127 (ignored)
gcj-4.7.2 -Wall -Wextra -O2 --encoding=UTF-8 --classpath="/usr/share/java/libgcj-4.7.2.jar:/home/tw1/pdftk-1.45-dist/java:." -C org/bouncycastle/asn1/IndefiniteLengthInputStream.java
/bin/sh: gcj-4.7.2: command not found
make[1]: [org/bouncycastle/asn1/IndefiniteLengthInputStream.class] Error 127 (ignored)
gcjh-4.7.2 -force --classpath="/usr/share/java/libgcj-4.7.2.jar:/home/tw1/pdftk-1.45-dist/java:." org/bouncycastle/asn1/IndefiniteLengthInputStream
/bin/sh: gcjh-4.7.2: command not found
make[1]: [org/bouncycastle/asn1/IndefiniteLengthInputStream.h] Error 127 (ignored)
fastjar-4.7.2 -cf java_lib.jar com/lowagie/*/*/*/*.class com/lowagie/*/*/*.class com/lowagie/*/*.class org/bouncycastle/*/*.class org/bouncycastle/*/*/*.class com/lowagie/text/pdf/fonts/Helvetica-Oblique.afm com/lowagie/text/pdf/fonts/Courier.afm com/lowagie/text/pdf/fonts/Helvetica-BoldOblique.afm com/lowagie/text/pdf/fonts/Courier-Bold.afm com/lowagie/text/pdf/fonts/Times-Roman.afm com/lowagie/text/pdf/fonts/Times-Bold.afm com/lowagie/text/pdf/fonts/Courier-Oblique.afm com/lowagie/text/pdf/fonts/Symbol.afm com/lowagie/text/pdf/fonts/Courier-BoldOblique.afm com/lowagie/text/pdf/fonts/Helvetica.afm com/lowagie/text/pdf/fonts/Helvetica-Bold.afm com/lowagie/text/pdf/fonts/Times-Italic.afm com/lowagie/text/pdf/fonts/ZapfDingbats.afm com/lowagie/text/pdf/fonts/Times-BoldItalic.afm
/bin/sh: fastjar-4.7.2: command not found
make[1]: [java_lib.o] Error 127 (ignored)
gcj-4.7.2 -Wall -Wextra -O2 --encoding=UTF-8 --classpath="/usr/share/java/libgcj-4.7.2.jar:/home/tw1/pdftk-1.45-dist/java:." -c java_lib.jar
/bin/sh: gcj-4.7.2: command not found
make[1]: [java_lib.o] Error 127 (ignored)
make[1]: Leaving directory `/home/tw1/pdftk-1.45-dist/java'
make: *** No rule to make target `../java/java_lib.o', needed by `pdftk.o'. Stop.
从输出中我可以推断出它无法找到gcjh,gcj路径.我无法找出应该在Makefile中指定的路径.
From the output i can infer that it is not able to find gcjh,gcj path. I am not able to find out what path should be given into the Makefile.
TOOLPATH=
export VERSUFF=
其他信息
-
gcc --version
gcc --version
gcc(GCC)4.7.2 20120921(红帽4.7.2-2)版权所有(C)2012自由软件基金会,Inc.这是免费软件;请参阅复制条件的来源.没有保修单;甚至不是出于适销性或针对特定目的的适用性.
gcc (GCC) 4.7.2 20120921 (Red Hat 4.7.2-2)Copyright (C) 2012 Free Software Foundation, Inc.This is free software; see the source for copying conditions. There is NOwarranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
找到gcjh-4.7.2 |少
locate gcjh-4.7.2 | less
没事
找到gcj-4.7.2 |少
locate gcj-4.7.2 | less
/usr/lib64/gcj-4.7.2 /usr/lib64/gcj-4.7.2/classmap.db /usr/lib64/gcj-4.7.2/classmap.db.d /usr/lib64/gcj-4.7.2/libgjsmalsa.so /usr/lib64/gcj-4.7.2/libgtkpeer.so /usr/lib64/gcj-4.7.2/libjavamath.so /usr/lib64/gcj-4.7.2/libjawt.so /usr/lib64/gcj-4.7.2/libjvm.so /usr/share/java/libgcj-4.7.2.jar
/usr/lib64/gcj-4.7.2 /usr/lib64/gcj-4.7.2/classmap.db /usr/lib64/gcj-4.7.2/classmap.db.d /usr/lib64/gcj-4.7.2/libgjsmalsa.so /usr/lib64/gcj-4.7.2/libgtkpeer.so /usr/lib64/gcj-4.7.2/libjavamath.so /usr/lib64/gcj-4.7.2/libjawt.so /usr/lib64/gcj-4.7.2/libjvm.so /usr/share/java/libgcj-4.7.2.jar
推荐答案
您是否真的安装了gcc-java
软件包?那就是提供gcj
和gcjh
可执行文件的内容(尽管不是gcj-4.7.2
或gcjh-4.7.2
).
Do you actually have the gcc-java
package installed? That is what provides the gcj
and gcjh
executables (though not gcj-4.7.2
or gcjh-4.7.2
).
这篇关于无法在Fedora机器上从源代码构建pdftk的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!