小编sea*_*ean的帖子

如何解决配置猜测构建类型失败?

当我配置(在cygwin环境下)时,发生错误,消息如下:

$ ./configure
.................
checking build system type... /bin/sh: ./config.guess: No such file or directory
configure: error: cannot guess build type; you must specify one
Run Code Online (Sandbox Code Playgroud)

怎么解决?谢谢!!

cygwin configure

33
推荐指数
3
解决办法
4万
查看次数

如何在cmake的函数中设置全局变量?

我正在写一个CMakeLists.txt来生成文件并编译生成的文件.我创建了一个函数来将一些文件路径字符串添加到全局列表变量.

我的CMakeLists.txt:

set(source_list "nothing")
function(test file_path)
    list(APPEND source_list ${file_path})
endfunction(test)
test(abc.txt)
test(def.txt)
message("At last, the source_list is:\"${source_list}\"")
Run Code Online (Sandbox Code Playgroud)

cmake输出:

At last, the source_list is:"nothing"
Run Code Online (Sandbox Code Playgroud)

有人建议使用宏而不是函数,但我确实需要使用局部变量,所以我需要使用函数而不是宏.

如何在函数test()中正确设置全局变量source_list?cmake不能以简单和正常的方式做到吗?

cmake

14
推荐指数
4
解决办法
2万
查看次数

为什么ulimit不能成功限制驻留内存以及如何?

我启动一个新的bash shell,并执行:

ulimit -m 102400
ulimit -a
"
core file size          (blocks, -c) 0
data seg size           (kbytes, -d) unlimited
scheduling priority             (-e) 20
file size               (blocks, -f) unlimited
pending signals                 (-i) 16382
max locked memory       (kbytes, -l) 64
max memory size         (kbytes, -m) 102400
open files                      (-n) 1024
pipe size            (512 bytes, -p) 8
POSIX message queues     (bytes, -q) 819200
real-time priority              (-r) 0
stack size              (kbytes, -s) 8192
cpu time               (seconds, -t) unlimited
max user processes              (-u) unlimited …
Run Code Online (Sandbox Code Playgroud)

linux shell administration ulimit

11
推荐指数
2
解决办法
2万
查看次数

如何设置QFileDialog来设置最初选择的文件?

我的意思是当对话框弹出时,根据文件管理器的一些文件处于选中状态.QFileDialog有办法做到这一点吗?

user-interface qt

2
推荐指数
1
解决办法
915
查看次数

标签 统计

administration ×1

cmake ×1

configure ×1

cygwin ×1

linux ×1

qt ×1

shell ×1

ulimit ×1

user-interface ×1