编译器shell脚本 [英] Compilers for shell scripts

查看:192
本文介绍了编译器shell脚本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你知道,如果有编制的bash脚本的任何工具?

Do you know if there's any tool for compiling bash scripts?

如果该工具仅仅是一个转换器(例如,一些bash脚本转换为C程序),没关系,只要翻译结果可以被编译。

It doesn't matter if that tool is just a translator (for example, something that converts a bash script to a C program), as long as the translated result can be compiled.

我在寻找类似 SHC (这只是一个例子 - - 我知道,SHC不作为编译器的工作)。是否还有其他类似的工具?

I'm looking for something like shc (it's just an example -- I know that shc doesn't work as a compiler). Are there any other similar tools?

推荐答案

一个谷歌搜索带来了 CCsh ,但是它将把你每机背50 $牌照。

A Google search brings up CCsh, but it will set you back $50 per machine for a license.

文档说CCsh编译Bourne shell的(不是bash ...)脚本C code和它知道如何复制的避免需要 50奇数标准命令的功能叉他们。

The documentation says that CCsh compiles Bourne Shell (not bash ...) scripts to C code and that it understands how to replicate the functionality of 50 odd standard commands avoiding the need to fork them.

但CCsh不是开源的,所以如果它不这样做你所需要的(或期望),你将不能够查看源$ C ​​$ C找出原因。

But CCsh is not open source, so if it doesn't do what you need (or expect) you won't be able to look at the source code to figure out why.

这篇关于编译器shell脚本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆