Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions ex26.md
Original file line number Diff line number Diff line change
Expand Up @@ -388,7 +388,7 @@ error:

## Shell 函数

`devkpg`的一个关键设计是,使用类似于`curl`、`tar`和`git`的外部工具来完成大部分的工作。我们可以找到在程序内部完成这些工作的库,但是如果我们只是需要这些程序的基本功能,这样就毫无意义。在Unix运行其它命令并不丢人。
`devpkg`的一个关键设计是,使用类似于`curl`、`tar`和`git`的外部工具来完成大部分的工作。我们可以找到在程序内部完成这些工作的库,但是如果我们只是需要这些程序的基本功能,这样就毫无意义。在Unix运行其它命令并不丢人。

为了完成这些,我打算使用`apr_thread_proc.h`函数来运行程序,但是我也希望创建一个简单的类“模板”系统。我会使用`struct Shell`,它持有所有运行程序所需的信息,但是在参数中有一些“空位”,我可以将它们替换成实际值。

Expand Down Expand Up @@ -704,7 +704,7 @@ int Command_fetch(apr_pool_t *p, const char *url, int fetch_only)
rc = Shell_exec(TAR_SH, "FILE", TAR_BZ2_SRC, NULL);
check(rc == 0, "Failed to untar %s", TAR_BZ2_SRC);
} else {
sentinel("Don't now how to handle %s", url);
sentinel("Don't know how to handle %s", url);
}

// indicates that an install needs to actually run
Expand Down
2 changes: 1 addition & 1 deletion ex28.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ $
## Makefile


我要讲到的第一件事情就是Makefile,因为你可以从中了解其它东西的情况。这个练习的Makeile比之前更加详细,所以我会在你输入它之后做详细的分解。
我要讲到的第一件事情就是Makefile,因为你可以从中了解其它东西的情况。这个练习的Makefile比之前更加详细,所以我会在你输入它之后做详细的分解。

```make
CFLAGS=-g -O2 -Wall -Wextra -Isrc -rdynamic -DNDEBUG $(OPTFLAGS)
Expand Down
2 changes: 1 addition & 1 deletion ex6.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
你应该掌握了一个简单的C程序的结构,所以让我们执行下一步简单的操作,声明不同类型的变量。

```c
include <stdio.h>
#include <stdio.h>

int main(int argc, char *argv[])
{
Expand Down