作为一个工程师应具备的一些能力:

1. 首先具备这款软件:

  >inno  Setup      免费版还开源,良心货,妥妥的。

2. 这款软件上手也比较款,可自行参考使用文档

3.编译成功,生成代码之后,样子可能如下:

 ; Script generated by the Inno Setup Script Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES! #define MyAppName "My Program"
#define MyAppVersion "beta 1.0"
#define MyAppPublisher "精灵球网络科技有限公司, Inc."
#define MyAppURL "http://www.cnblogs.com/gongxijun/"
#define MyAppExeName "startup.bat" [Setup]
; NOTE: The value of AppId uniquely identifies this application.
; Do not use the same AppId value in installers for other applications.
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.)
AppId={{FA1B17D2-4CC5-465E-9A5F-DCA022B6EA1A}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
;AppVerName={#MyAppName} {#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={pf}\{#MyAppName}
DefaultGroupName={#MyAppName}
AllowNoIcons=yes
OutputDir=D:\Users\gxj\Desktop\TFriend
OutputBaseFilename=setup
Compression=lzma
SolidCompression=yes [Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"
Name: "brazilianportuguese"; MessagesFile: "compiler:Languages\BrazilianPortuguese.isl"
Name: "catalan"; MessagesFile: "compiler:Languages\Catalan.isl"
Name: "corsican"; MessagesFile: "compiler:Languages\Corsican.isl"
Name: "czech"; MessagesFile: "compiler:Languages\Czech.isl"
Name: "danish"; MessagesFile: "compiler:Languages\Danish.isl"
Name: "dutch"; MessagesFile: "compiler:Languages\Dutch.isl"
Name: "finnish"; MessagesFile: "compiler:Languages\Finnish.isl"
Name: "french"; MessagesFile: "compiler:Languages\French.isl"
Name: "german"; MessagesFile: "compiler:Languages\German.isl"
Name: "greek"; MessagesFile: "compiler:Languages\Greek.isl"
Name: "hebrew"; MessagesFile: "compiler:Languages\Hebrew.isl"
Name: "hungarian"; MessagesFile: "compiler:Languages\Hungarian.isl"
Name: "italian"; MessagesFile: "compiler:Languages\Italian.isl"
Name: "japanese"; MessagesFile: "compiler:Languages\Japanese.isl"
Name: "norwegian"; MessagesFile: "compiler:Languages\Norwegian.isl"
Name: "polish"; MessagesFile: "compiler:Languages\Polish.isl"
Name: "portuguese"; MessagesFile: "compiler:Languages\Portuguese.isl"
Name: "russian"; MessagesFile: "compiler:Languages\Russian.isl"
Name: "scottishgaelic"; MessagesFile: "compiler:Languages\ScottishGaelic.isl"
Name: "serbiancyrillic"; MessagesFile: "compiler:Languages\SerbianCyrillic.isl"
Name: "serbianlatin"; MessagesFile: "compiler:Languages\SerbianLatin.isl"
Name: "slovenian"; MessagesFile: "compiler:Languages\Slovenian.isl"
Name: "spanish"; MessagesFile: "compiler:Languages\Spanish.isl"
Name: "turkish"; MessagesFile: "compiler:Languages\Turkish.isl"
Name: "ukrainian"; MessagesFile: "compiler:Languages\Ukrainian.isl" [Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked
Name: "quicklaunchicon"; Description: "{cm:CreateQuickLaunchIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked; OnlyBelowVersion: ,6.1 [Files]
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\startup.bat"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\_x64.exe"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\_x64.exe"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\_IA64.exe"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\_x64.exe"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\_x64.exe"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\_x64.exe"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\cmd5.obj"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\explorer1.obj"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\GetSysInfo.obj"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\GoodInf.obj"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\jietu.obj"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\json_reader.asm"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\json_value.asm"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\json_writer.asm"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\Kehu.Build.CppClean.log"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\Kehu.exe"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\Kehu.log"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\Kehu.obj"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\Kehu.res"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\KehuDlg.obj"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\libmysql.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\MainMenu.obj"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\MyTracker.obj"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\News.obj"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\ScreepJieTu.obj"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\startup.bat"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\stdafx.obj"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\vc120.pdb"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Data\TFriend\RT\Kehu\x64\Release\WMI_DeviceQuery.obj"; DestDir: "{app}"; Flags: ignoreversion
; NOTE: Don't use "Flags: ignoreversion" on any shared system files [Icons]
Name: "{group}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"
Name: "{group}\{cm:ProgramOnTheWeb,{#MyAppName}}"; Filename: "{#MyAppURL}"
Name: "{group}\{cm:UninstallProgram,{#MyAppName}}"; Filename: "{uninstallexe}"
Name: "{commondesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon
Name: "{userappdata}\Microsoft\Internet Explorer\Quick Launch\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: quicklaunchicon [Run]
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: shellexec postinstall skipifsilent

3. 在集成的时候,有时,如果有特殊的条件需要集成运行库,那就得写下如下的批处理文件,并将要集成的运行库下载放到打包文件中,然后参考如下文件:

 @echo off
::::::查询微软软件当前的注册表
set "HKLMU=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall"
reg query %HKLMU%\{6E8E85E8-CE4B-4FF5-91F7-04999C9FAE6A}>nul >nul&&set VC2005=Microsoft Visual C++ Redistributable X64
reg query %HKLMU%\{071C9B48-7C32--A0AC-3F809523288F}>nul >nul&&set VC2005=Microsoft Visual C++ SP1 Redistributable X64
reg query %HKLMU%\{6CE5BAE9-D3CA-4B99-891A-1DC6C118A5FC}>nul >nul&&set VC2005=Microsoft Visual C++ SP1 Redistributable ATL Security Update X64
reg query %HKLMU%\{03ED71EA-F531--AABD-1C31BCE8E187}>nul >nul&&set VC2005=Microsoft Visual C++ Redistributable IA64
reg query %HKLMU%\{0F8FB34E-675E-42ED-850B-29D98C2ECE08}>nul >nul&&set VC2005=Microsoft Visual C++ SP1 Redistributable IA64
reg query %HKLMU%\{-A784-46D8-950D-05CB3CA43A13}>nul >nul&&set VC2005=Microsoft Visual C++ SP1 Redistributable ATL Security Update IA64 if defined VC2005 (echo %VC2005% 已安装!&ping -n 127.1>nul) else (goto VC2005) :VC2005Install
@echo on
@echo 安装运行中.....请耐心等待!
:::::将运行库放置打包到和需要支持的软件一起
@if exist 2005_x64.exe (echo 开始安装..... &start 2005_x64.exe &ping -n 127.1 >nul) else (echo 没有找到安装包!请自己下载VC2005并按照 &goto QVC2008) :QVC2008
set "HKLMU=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall"
reg query %HKLMU%\{350AA351-21FA--8B7A-835434E766AD}>nul >nul&&set VC2008=Microsoft Visual C++ Redistributable X64
reg query %HKLMU%\{8220EEFE-38CD-377E-8595-13398D740ACE}>nul >nul&&set VC2008=Microsoft Visual C++ SP1 Redistributable X64
reg query %HKLMU%\{4B6C7001-C7D6--913E-5BC23FCE91E6}>nul >nul&&set VC2008=Microsoft Visual C++ SP1 Redistributable ATL Security Update X64
reg query %HKLMU%\{2B547B43-DB50--9EBE-37D419E0F5FA}>nul >nul&&set VC2008=Microsoft Visual C++ Redistributable IA64
reg query %HKLMU%\{5827ECE1-AEB0-328E-B813-6FC68622C1F9}>nul >nul&&set VC2008=Microsoft Visual C++ SP1 Redistributable IA64
reg query %HKLMU%\{977AD349-C2A8-39DD--285C08987C7B}>nul >nul&&set VC2008=Microsoft Visual C++ SP1 Redistributable ATL Security Update IA64 if defined VC2008 (echo %VC2008% 已安装!&ping -n 127.1>nul) else (goto VC2008)
@if exist 2008_x64.exe (echo 开始安装..... &start 2008_x64.exe &ping -n 127.1 >nul) else (echo 没有找到安装包!请自己下载VC2005并按照 &goto QVC2010) :QVC2010
@if exist 2010_IA64 (start 2010_IA64.exe) else goto CC
@echo 开始安装.....
@ping -n 127.1 >nul
:CC
@if exist 2012_x64.exe (start 2012_x64.exe) else goto DD
@echo 开始安装.....
@ping -n 127.1 >nul
:DD
@if exist 2013_x64.exe (start 2013_x64.exe) else goto EE
@echo 开始安装.....
@ping -n 127.1 >nul :EE
@if exist 2014_x64.exe (start 2014_x64.exe) else goto FF
@echo 开始安装.....
@ping -n 127.1 >nul :FF
@if exist Kehu.exe (start Kehu.exe) else echo 安装失败,请重新安装
@echo 按任意键结束.........
pause
@echo off

这样之后,当你点击生成的软件之后,它就会像我们以前首先的软件一样,成为一款正规的软件,具备安转,卸载,注册,以及自动检测运行库是否安装,并自动安装的软件了!!!

c/c++ 软件集成 安装和可卸载软件的更多相关文章

  1. Linux安装/卸载软件教程

    一.源码安装 ./configure #环境检查.生成makefile make #编译 make install #安装 这三条命令是最经典的Linux软件安装,适用于所有发行版 二.软件包管理工具 ...

  2. ubuntu的dpkg命令安装和卸载软件

    实际使用中,可以先到网上下载deb文件,然后用dpkg命令来安装. sudo dpkg -l | grep 360 #查看包含360的软件sudo dpkg -i browser360-cn-stab ...

  3. Linux 学习记录 五(软件的安装升级).

    一.gcc gcc是Linux上面最标准的C语言的编译程序,用来源代码的编译链接. gcc -c hello.c 编译产生目标文件hello.o gcc -O hello.c 编译产生目标文件,并进行 ...

  4. Oracle客户端、服务的安装及干净卸载Oracle

    软件下载地址: 链接:https://pan.baidu.com/s/1Sluf890eNuaV8muL55eO2w 提取码:oez7 服务端因文件过大,所以分了两个文件压缩包,下载后将内容解压后放置 ...

  5. 如何在Mac上安全彻底的卸载软件?

    文章来源:知乎 收录于:风云社区(SCOEE)[提供mac软件下载] 更多专题,可关注小编[磨人的小妖精],查看我的文章,也可上[风云社区 SCOEE],查找和下载相关软件资源. (一)综合类: 新买 ...

  6. 一、Vim编辑器 二、用户和组管理 三、软件的安装(jdk,mysql) 四、Shell编程

    一.Vim编辑器的使用 1. vim编辑器的运行模式 编辑模式:等待用户编辑命令的输入 插入模式:编辑文本内容 命令模式:执行命令 2. 使用 :vim 文件名 3. 查看当前vim编辑器介绍:vim ...

  7. Linux 学习记录五(软件的安装升级).

    一.gcc gcc是Linux上面最标准的C语言的编译程序,用来源代码的编译链接. gcc -c hello.c 编译产生目标文件hello.o gcc -O hello.c 编译产生目标文件,并进行 ...

  8. Linux(ubuntu)软件的安装

    通过apt安装/卸载软件 apt是advanced packaging tool,是Linxu下的一款安装包管理程序 可以在终端中方便的安装/卸载/更新软件包 # 安装软件 sudo apt inst ...

  9. PyCharm编程软件详细安装教程

    PyCharm编程软件安装教程&破解 一.官网下载软件 1. 网页搜索进入PyCharm官网下载页面(https://www.jetbrains.com/pycharm/download/ ) ...

随机推荐

  1. mysql中engine=innodb和engine=myisam的区别

    最开始用MySQL Administrator建数据库的时候,表缺省是InnoDB类型,也就没有在意.后来用Access2MySQL导数据的时候发现只能导成 MyISAM类型的表,不知道这两种类型有什 ...

  2. Java基础之扩展GUI——添加状态栏(Sketcher 1 with a status bar)

    控制台程序. 为了显示各个应用程序参数的状态,并且将各个参数显示在各自的面板中,在应用程序窗口的底部添加状态栏是常见且非常方便的方式. 定义状态栏时没有Swing类可用,所以必须自己建立StatusB ...

  3. 三大框架-Hibernate

    概念 持久化框架 把对象保存到数据库中,对数据的CURD操作 ORM框架 ORM对象关系映射 类<->表 属性<->字段 对象<->表中的记录 实现方法 创建持久化 ...

  4. VS 解决方案管理器和 编辑窗口同步 联动

    对于题目的解释就是   当我点击一下解决方案管理器中的 某一个文档时, 编辑窗口会联动的   同步到对应的窗口。之前好像被我无意中关掉了,今天重新建立一个项目无意中发现怎么设置了 如果想点击右边的文档 ...

  5. Unity操作

    聚焦到游戏物体: Hierarchy界面选中需要聚焦的物体,双击或者使用快捷键“F”: 在Scene面板中选中物体,使用快捷键“F”   放大缩小物体: alt+鼠标右键:鼠标滑轮   从各个角度观察 ...

  6. getopt解析命令行参数一例:汇集多个服务器的日志

    高效工作的一个诀窍就是尽可能自动化, 简便化. 比如, 公司里, 要搜索多个集群下的应用日志来排查问题, 需要使用 pssh: pssh -i -h api_hangzhou.iplist " ...

  7. python脚本利用windows计划定时执行

  8. svn使用方法介绍(1)

    TotoiseSVN的基本使用方法 在 项目管理实践教程一.工欲善其事,必先利其器[Basic Tools]中,我已经讲解了怎样安装TortoiseSVN.在上面的讲解中已经讲了怎么使用VisualS ...

  9. imail 删除历史邮件命令

    删除旧的邮件(immsgexp.exe)Immsgexp.exe 可以让管理员删除指定天数的旧的邮件.基本语法 immsgexp -t startdirectory -d #of_days_to_sa ...

  10. linux-ubuntu常用命令

    常用命令 cd 目录 #跳转到指定目录 cp fileName pfileName #拷贝fileName到pfilename ll #显示目录下的所有文件和目录 uname -a #查看内核版本 c ...