Solaris下如何自己定制二进制安装包

 11.2  Solaris下如何自己定制二进制 安装包

A: deepin <deepin@nsfocus.com> & scz <scz@nsfocus.com>

[root@ /tmp/tools]> mkdir srcroot
[root@ /tmp/tools]> cp -p /usr/ccs/bin/as srcroot  <-- 复制那些数据源到该目录下
[root@ /tmp/tools]> cp -p /usr/ccs/bin/make srcroot
[root@ /tmp/tools]> cp -p /usr/ccs/lib/cpp srcroot
[root@ /tmp/tools]> ls -lR srcroot
-rwxr-xr-x   1 bin      bin       342072 1999   1月 12 as*
-rwxr-xr-x   1 bin      bin        91344 1998   4月 27 cpp*
-rwxr-xr-x   1 bin      bin       273196 1998   4月 23 make*
[root@ /tmp/tools]> cd srcroot
[root@ /tmp/tools/srcroot]> find . -print | pkgproto > ../prototype
[root@ /tmp/tools/srcroot]> cd ..
[root@ /tmp/tools]> more prototype
f none cpp 0755 bin bin
f none as 0755 bin bin
f none make 0755 bin bin
[root@ /tmp/tools]> vi prototype  <-- 在头部增加如下行
i pkginfo=./pkginfo
[root@ /tmp/tools]> vi pkginfo
PKG="Scz"
NAME="Scz Package Cool Tools"
VERSION="2000-01-09 14:53"
CATEGORY="application"
PSTAMP="小四"
CLASSES="none"
ARCH=" Solaris 2.7 For SPARC"
VENDOR="NSFocus"
BASEDIR="/tmp/tools/opt/"
EMAIL="scz@nsfocus.com"
[root@ /tmp/tools]> pkgmk -o -f ./prototype -b /tmp/tools/srcroot
[root@ /tmp/tools]> pkgtrans -s /var/spool/pkg /tmp/tools/SczPkg Scz
[root@ /tmp/tools]> rm -rf /var/spool/pkg/Scz
[root@ /tmp/tools]> pkgadd -d SczPkg
[root@ /tmp/tools]> ls -lR opt
-rwxr-xr-x   1 bin      bin       342072 1999   1月 12 as*
-rwxr-xr-x   1 bin      bin        91344 1998   4月 27 cpp*
-rwxr-xr-x   1 bin      bin       273196 1998   4月 23 make*
[root@ /tmp/tools]> pkginfo -l Scz
[root@ /tmp/tools]> pkgrm Scz
[root@ /tmp/tools]> rm SczPkg
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值