1

Linux 2.6.31.8 armv5tel を実行するBuffalo LinkStation Pro Duo (ロックを解除した後) でGCC 4.7.2 をコンパイルしようとしています。

残念ながら、makeかなりのエラーをスローします。

gcc -c  -DIN_GCC_FRONTEND -g -fkeep-inline-functions -DIN_GCC   -W -Wall -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wmissing-formIn file included from ../../gcc-4.7.2/gcc/tree.h:32,
                 from ../../gcc-4.7.2/gcc/c-lang.c:27:
../../gcc-4.7.2/gcc/real.h:53: error: 'SIZEOF_LONG' undeclared here (not in a function)
In file included from ../../gcc-4.7.2/gcc/tree.h:32,
                 from ../../gcc-4.7.2/gcc/c-lang.c:27:
../../gcc-4.7.2/gcc/real.h:87:5: error: division by zero in #if
../../gcc-4.7.2/gcc/real.h:87:5: error: division by zero in #if
../../gcc-4.7.2/gcc/real.h:90:6: error: division by zero in #if

read の 53 行目real.hunsigned long sig[SIGSZ];ここで、SIGSZ40 行目で次のように定義されていますが、
#define SIGSZ (SIGNIFICAND_BITS / HOST_BITS_PER_LONG)
87行目では 72 行目から次のよう#if REAL_WIDTH == 1に定義されています。REAL_WIDTH
#define REAL_WIDTH \
(REAL_VALUE_TYPE_SIZE/HOST_BITS_PER_WIDE_INT \
+ (REAL_VALUE_TYPE_SIZE%HOST_BITS_PER_WIDE_INT ? 1 : 0)) /* round up */

これはHOST_BITS_PER_*ゼロに要約されるようです。パラメータを使用してこれらを手動で定義する必要がありconfigureますか? または、この問題を解決するにはどうすればよいですか?


アップデート

config.log次のエラーが含まれています。

conftest.c:10:19: error: ppl_c.h: No such file or directory
conftest.c: In function 'main':
conftest.c:16: error: 'choke' undeclared (first use in this function)
conftest.c:16: error: (Each undeclared identifier is reported only once
conftest.c:16: error: for each function it appears in.)
conftest.c:16: error: expected ';' before 'me'
configure:5708: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAME ""
| #define PACKAGE_VERSION ""
| #define PACKAGE_STRING ""
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL ""
| #define LT_OBJDIR ".libs/"
| /* end confdefs.h.  */
| #include "ppl_c.h"
| int
| main ()
| {
|.
|     #if PPL_VERSION_MAJOR != 0 || PPL_VERSION_MINOR < 11
|     choke me
|     #endif
|.
|   ;
|   r

この投稿に続いて、 pplをインストールするのを忘れたようです、今試してみます

4

2 に答える 2

1

SIZEOF_LONGファイル内で#definedである必要があります。次のようなものを含める必要があります。configureauto-host.hauto-host.h

/* The size of `long', as computed by sizeof. */
#ifndef USED_FOR_TARGET
#define SIZEOF_LONG 8
#endif

上記が存在しない場合(そしてあなたの場合は実際にそうであるように見えます)、config.logエラーをチェックしてください。文字列周辺のエラーを検索しますchecking size of long

于 2012-12-13T13:53:51.720 に答える
1
  • chillの回答のおかげで、私config.logは発見するためにチェックしました(不思議なことに、Makefileを作成して成功エラーコードを返すことを
    conftest.c:10:19: error: ppl_c.h: No such file or directory
    妨げませんでした)。configureその上で最初のグーグルヒットはこの投稿であり、私がppl依存関係を提供しなかったことを示しています。
  • ppl-1.0のコンパイルが私を迎えてくれたので、代わりに1.1スナップショットを使用することを提案するこの投稿
    checked_float.inlines.hh:1012: error: 'frexpl' was not declared in this scope
    につながりました。
  • さて、gccmakeは私に別の「役立つ」エラーを提供しました:
    gcc/../libcpp/include/line-map.h:66: error: 'CHAR_BIT'
    それはコロンで終わるためであることが判明しました(私はすでにその投稿で言及されたエラーを経験しましたが、他の変数をチェックすることも考えていませんでした)C_INCLUDE_PATH checking LIBRARY_PATH variable... contains current directory

コンパイルはまだ実行中ですが、これまでのところエラーはありません...

于 2012-12-14T08:03:44.433 に答える