You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@brpc.apache.org by "highkic (via GitHub)" <gi...@apache.org> on 2023/07/04 06:37:53 UTC

[I] config_brpc.sh 从LIBS_IN中寻找protoc报错找不到 (brpc)

highkic opened a new issue, #2300:
URL: https://github.com/apache/brpc/issues/2300

   **Describe the bug (描述bug)**
   config_brpc.sh 中从LIBS_IN中寻找protoc, 是不是不太对呀,正常protoc不会再/usr/bin或者/usr/local/bin中么
   find_bin() {
       TARGET_BIN=$(find -L ${LIBS_IN} -type f -name "$1" 2>/dev/null | head -n1)
       if [ ! -z "$TARGET_BIN" ]; then
           $ECHO $TARGET_BIN
       else
           which "$1" 2>/dev/null
       fi
   }
   find_bin_or_die() {
       TARGET_BIN=$(find_bin "$1")
       if [ ! -z "$TARGET_BIN" ]; then
           $ECHO $TARGET_BIN
       else
           >&2 $ECHO "Fail to find $1"
           exit 1
       fi
   }
   
   **To Reproduce (复现方法)**
   执行 config_brpc.sh
   报错Fail to find protoc
   
   **Expected behavior (期望行为)**
   /usr/bin中有protoc,不应该报错Fail to find protoc
   
   **Versions (各种版本)**
   OS: linux 
   Compiler: gcc 7.3.1
   brpc: 1.4.0
   protobuf: 3.6.1
   
   **Additional context/screenshots (更多上下文/截图)**
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


Re: [I] config_brpc.sh 从LIBS_IN中寻找protoc报错找不到 (brpc)

Posted by "wasphin (via GitHub)" <gi...@apache.org>.
wasphin commented on issue #2300:
URL: https://github.com/apache/brpc/issues/2300#issuecomment-1619686426

   优先使用 LIBS_IN 下的的 protoc,如果没有的话会找系统中的`which protoc`,这里要确认下 `which protoc` 是不是存在。


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


Re: [I] config_brpc.sh 从LIBS_IN中寻找protoc报错找不到 (brpc)

Posted by "highkic (via GitHub)" <gi...@apache.org>.
highkic closed issue #2300: config_brpc.sh 从LIBS_IN中寻找protoc报错找不到
URL: https://github.com/apache/brpc/issues/2300


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


Re: [I] config_brpc.sh 从LIBS_IN中寻找protoc报错找不到 (brpc)

Posted by "highkic (via GitHub)" <gi...@apache.org>.
highkic commented on issue #2300:
URL: https://github.com/apache/brpc/issues/2300#issuecomment-1619738102

   如你所说,我check了下镜像里没有which工具,所以报了问题,get


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org