使用dpkg创建debain源包时出错
将dpkg-source -b
输入到终端以创建debian源包时,我收到以下错误:
dpkg-source:错误:第9行的ResolutionX_1.0-0 / debian / control中的语法错误: 第一个块缺少源字段
这是什么意思?
我的debian控制文件包含:
包装:ResolutionX 版本:1.0-0 科:基地 优先级:可选 建筑:全部 构建 - 取决于:debhelper(> = 9) 维护者:Bilal Bernardot 描述:ResolutionX 一个简单的工具,使您无需图形驱动程序即可获得所需的分辨率。
Package: ResolutionX Version: 1.0-0 Section: base Priority: optional Architecture: all Build-Depends: debhelper (>= 9) Maintainer: Bilal Bernardot Description: ResolutionX A simple tool to enable you to have your desired resolution without requiring graphics drivers.
这段是源代码和二进制包的字段。 第一段应描述源包 。 在这里,这意味着第一行有Source:
而不是Package:
. 您只能为源包指定Build-Depends
,为二进制包指定Architecture
。 Version
源自debian/changelog
,并未在debian/control
指定。
我不知道debian/control
的其余部分是什么样的,但就此而言,我认为你应该分开第一段:
Source: resolutionx Version: 1.0-0 Section: base Priority: optional Build-Depends: debhelper (>= 9) Maintainer: Bilal Bernardot Package: resolutionx Section: base Priority: optional Architecture: all Description: ResolutionX A simple tool to enable you to have your desired resolution
另请注意,包名称中不应包含大写字母。 实际上,提交给Debian或Ubuntu存储库的包不能在其名称中包含大写字母。