Php

pecl-ssh2-0.11 Freebsd 升級到 php 5.3.2 後編譯錯誤

  • June 4, 2010

嗨,我整天都在尋找答案,但找不到任何東西可以解決我的問題。

我還遇到了關於 serverfault 上的這個埠的問題,我剛剛回答了這個問題,希望能對其他人有所幫助。

但是我的問題是這個。

在 /usr/ports/security/pecl-ssh2 中執行“make”時

我收到這個錯誤

===> 為 pecl-ssh2-0.11 建構
/bin/sh /usr/ports/security/pecl-ssh2/work/ssh2-0.11/libtool --mode=compile cc -I. -I/usr/ports/security/pecl-ssh2/work/ssh2-0.11 -DPHP_ATOM_INC -I/usr/ports/security/pecl-ssh2/work/ssh2-0.11/include -I/usr/ports/security/pecl -ssh2/work/ssh2-0.11/main -I/usr/ports/security/pecl-ssh2/work/ssh2-0.11 -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date /lib -I/usr/local/include -I/usr/local/include -DHAVE_CONFIG_H -O2 -pipe -fno-strict-aliasing -c /usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2 .c -o ssh2.lo
抄送-I。-I/usr/ports/security/pecl-ssh2/work/ssh2-0.11 -DPHP_ATOM_INC -I/usr/ports/security/pecl-ssh2/work/ssh2-0.11/include -I/usr/ports/security/pecl -ssh2/work/ssh2-0.11/main -I/usr/ports/security/pecl-ssh2/work/ssh2-0.11 -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date /lib -I/usr/local/include -I/usr/local/include -DHAVE_CONFIG_H -O2 -pipe -fno-strict-aliasing -c /usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2 .c -fPIC -DPIC -o .libs/ssh2.o
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:在函式“zif_ssh2_methods_negotiated”中:
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:502:警告:傳遞'add_assoc_string_ex'的參數4會丟棄指針目標類型的限定符
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:503:警告:傳遞'add_assoc_string_ex'的參數4會丟棄指針目標類型的限定符
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:507:警告:傳遞'add_assoc_string_ex'的參數4會丟棄指針目標類型的限定符
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:508:警告:傳遞'add_assoc_string_ex'的參數4會丟棄指針目標類型的限定符
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:509:警告:傳遞'add_assoc_string_ex'的參數4會丟棄指針目標類型的限定符
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:510:警告:傳遞'add_assoc_string_ex'的參數4會丟棄指針目標類型的限定符
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:515:警告:傳遞'add_assoc_string_ex'的參數4會丟棄指針目標類型的限定符
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:516:警告:傳遞'add_assoc_string_ex'的參數4會丟棄指針目標類型的限定符
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:517:警告:傳遞'add_assoc_string_ex'的參數4會丟棄指針目標類型的限定符
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:518:警告:傳遞'add_assoc_string_ex'的參數4會丟棄指針目標類型的限定符
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:在函式'zif_ssh2_poll'中:
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:891:錯誤:“zval”沒有名為“is_ref”的成員
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:891:錯誤:“zval”沒有名為“refcount”的成員
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:901:錯誤:“zval”沒有名為“is_ref”的成員
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:902:錯誤:“zval”沒有名為“refcount”的成員
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:在函式'zif_ssh2_publickey_add'中:
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:1011:錯誤:“zval”沒有名為“is_ref”的成員
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:1012:錯誤:“zval”沒有名為“refcount”的成員
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:1044:警告:傳遞'_efree'的參數1會丟棄指針目標類型的限定符
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:在函式'zif_ssh2_publickey_list'中:
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:1103:警告:傳遞'add_assoc_stringl_ex'的參數4會丟棄指針目標類型的限定符
/usr/ports/security/pecl-ssh2/work/ssh2-0.11/ssh2.c:1104:警告:傳遞'add_assoc_stringl_ex'的參數4會丟棄指針目標類型的限定符
*** 錯誤程式碼 1

在 /usr/ports/security/pecl-ssh2/work/ssh2-0.11 中停止。
*** 錯誤程式碼 1

在 /usr/ports/security/pecl-ssh2 中停止。

從 php 5.2.12 升級到週末在 freebsd 上發布的 php 5.3.2 後,我試圖重新編譯這個埠。

我已經沒有想法和精力了,所以如果有人對這可能是什麼有任何想法,我將不勝感激。

pecl-ssh 在 PHP 5.3 上不起作用,根據這個:

http://pecl.php.net/bugs/bug.php?id=16727

我的建議:安裝phpseclib,一個純 PHP SSH 實現

所以不確定問題出在 pecl-ssh2 軟體包還是 FreeBSD 埠上,因為我設法通過 pecl install 安裝了該軟體包。

這些是我遵循的指示

http://bugssite.org/blog/2009/08/02/php-5-3-0-ssh-2-0-11-how-to-get-it-working/2/

所以它確實適用於 php 5.3.2 但是我不能使用 FreeBSD 埠系統

引用自:https://serverfault.com/questions/131660