首页 > 其他 > 详细

bash 转换为C代码

时间:2019-05-19 16:14:20      阅读:129      评论:0      收藏:0      [点我收藏+]

bash 转换为C代码,并编译为可执行文件

[root@localhost ~]# wget http://www.datsi.fi.upm.es/~frosal/sources/shc-3.8.9.tgz
[root@localhost ~]# tar xvfz shc-3.8.9.tgz
[root@localhost ~]# cd shc-3.8.9

[root@localhost shc-3.8.9]# gcc -c shc.c
[root@localhost shc-3.8.9]# gcc -o shc shc.o
[root@localhost shc-3.8.9]# cp -a shc /bin/

[root@localhost ~]# shc -r -T -f wang.sh
[root@localhost ~]# gcc -c wang.sh.x.c
[root@localhost ~]# gcc -o wang wang.sh.x.o


将python代码转换为C代码

[root@localhost ~]# yum install -y epel-release
[root@localhost ~]# yum install -y python-pip
[root@localhost ~]# yum install -y python-dev*
[root@localhost ~]# pip install cython

[root@localhost ~]# vim lyshark.py

[root@localhost ~]# cython lyshark.py --embed
[root@localhost ~]# gcc python-config --cflags python-config --ldflags lyshark.c -o lyshark

bash 转换为C代码

原文:https://www.cnblogs.com/LyShark/p/10889555.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!