rugged will not be linked correctly when built in a path containing a whitespace, problem with pkg-config?
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 25/100
- Issue 类型
- 缺陷
- 描述清晰度
- 需要澄清
- 活跃度
- 停滞
- 领域
- build-system
调研方向
复现过程会运行 ext/rugged/extconf.rb,并构建 vendor/libgit2 下 vendored 的 libgit2;首先跟踪该入口点如何将路径传递给 pkg-config 和 CMake。从包含空格的目录中复现构建,并将其与手动的 pkg-config 命令进行比较。如果从此类路径构建时能够成功完成链接,或者已识别出可执行的项目变更并记录依赖项行为,则视为完成。
由索引模型根据 Issue 内容生成。
描述
Rugged will not be linked correctly when you build it in a path containing a whitespace, you will get undefined symbol errors.
git submodule update --init
Submodule 'vendor/libgit2' (https://github.com/libgit2/libgit2.git) registered for path 'vendor/libgit2'
Cloning into '/home/wiebelt/Projects/spa tie/rugged/vendor/libgit2'...
Submodule path 'vendor/libgit2': checked out '838a2f2918b6d9fad8768d2498575ff5d75c35f0'
mkdir -p tmp/x86_64-linux/rugged/2.5.3
cd tmp/x86_64-linux/rugged/2.5.3
/usr/bin/ruby -I. ../../../../ext/rugged/extconf.rb
checking for gmake... yes
checking for cmake... yes
checking for pkg-config... yes
-- cmake .. -DBUILD_CLAR=OFF -DTHREADSAFE=ON -DBUILD_SHARED_LIBS=OFF -DCMAKE_C_FLAGS=-fPIC -DCMAKE_BUILD_TYPE=RelWithDebInfo
-- /usr/bin/gmake
Package /home/wiebelt/Projects/spa was not found in the pkg-config search path.
Perhaps you should add the directory containing `/home/wiebelt/Projects/spa.pc'
to the PKG_CONFIG_PATH environment variable
Package '/home/wiebelt/Projects/spa', required by 'virtual:world', not found
Package 'tie/rugged/ext/rugged/../../vendor/libgit2/build/libgit2.pc', required by 'virtual:world', not found
checking for -lgit2... yes
checking for git2.h... yes
creating Makefile
cd -
cd tmp/x86_64-linux/rugged/2.5.3
/usr/bin/gmake
gcc -I. -I/usr/include -I/usr/include/ruby/backward -I/usr/include -I../../../../ext/rugged -DHAVE_GIT2_H "-I/home/wiebelt/Projects/spa tie/rugged/ext/rugged/../../vendor/libgit2/include" -fPIC -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fPIC -g -Wall -Wno-comment -m64 -o rugged.o -c ../../../../ext/rugged/rugged.c
... and it will compile just fine ...
When i run pkg-config by hand it seems like it does not handle quotes (single or double), using a backslash to escape the whitespace doesn't work either.
pkg-config --libs --static "/var/lib/jenkins/bui ld/rugged/ext/rugged/../../vendor/libgit2/build/libgit2.pc"
Package /var/lib/jenkins/bui was not found in the pkg-config search path.
Perhaps you should add the directory containing `/var/lib/jenkins/bui.pc'
to the PKG_CONFIG_PATH environment variable
No package '/var/lib/jenkins/bui' found
Failed to open 'ld/rugged/ext/rugged/../../vendor/libgit2/build/libgit2.pc': No such file or directory
No package 'ld/rugged/ext/rugged/../../vendor/libgit2/build/libgit2.pc' found
So it seems like it's a bug in pkg-config but i dont know enough of that tool to know for sure, is it being used correctly? Could someone help file a bug report there?
- 主要语言
- C
- 星标
- 2.3k
- 派生
- 293
- PR 合并指标
- 30 天内没有已合并 PR
贡献指南
这个仓库没有索引到贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
libgit2/rugged 的其他 Issue
-
难度 4/5 3-5 天 新手友好度 35/100
-
难度 4/5 3-5 天 新手友好度 48/100
-
难度 4/5 3-5 天 新手友好度 35/100
-
难度 4/5 3-5 天 新手友好度 35/100
-
难度 3/5 1-2 天 新手友好度 48/100
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 84/100
corazawaf/coraza-nginx#140 ·
-
难度 2/5 1-3 小时 新手友好度 75/100
BasedHardware/omi#15662 · 1 条评论 ·
-
难度 2/5 1-3 小时 新手友好度 84/100
-
bug
难度 2/5 1-3 小时 新手友好度 68/100
-
level/task module/gcp type/bug
难度 2/5 1-3 小时 新手友好度 85/100