Include:Newapkbuild: Difference between revisions
Prabuanand (talk | contribs) (rephrased sentence and added cmd format) |
Prabuanand (talk | contribs) (added comment not to make changes in transluded pages without checking target pages) |
||
Line 1: | Line 1: | ||
<!---This source page is transcluded in multiple pages. Please check all target pages before adding content here. Sometimes adding content in the target page may be more appropriate. Never change a transcluded page as REDIRECT as the target page will start transcluding the entire REDIRECT page --> | |||
The <code>newapkbuild</code> tool, which is installed as part of the {{Pkg|abuild}} package, can generate a new APKBUILD template to use as a starting point. The [https://git.alpinelinux.org/abuild/tree/newapkbuild.1.scd manual page] (available via <code>man newapkbuild</code>) describes all options for <code>newapkbuild</code>. | The <code>newapkbuild</code> tool, which is installed as part of the {{Pkg|abuild}} package, can generate a new APKBUILD template to use as a starting point. The [https://git.alpinelinux.org/abuild/tree/newapkbuild.1.scd manual page] (available via <code>man newapkbuild</code>) describes all options for <code>newapkbuild</code>. | ||
Latest revision as of 09:02, 26 February 2025
The newapkbuild
tool, which is installed as part of the abuild package, can generate a new APKBUILD template to use as a starting point. The manual page (available via man newapkbuild
) describes all options for newapkbuild
.
If you doubt to which repository your package belongs to you can safely use testing. Building package in your aports/testing directory is not mandatory but this way the package is already at the right place.
The following command will create a directory with the given package name, place an example/template APKBUILD file in the directory, and fill some variables if those are provided.
newapkbuild packagename
If you are creating a daemon package which needs initd scripts you can add the -c option as follows:
newapkbuild -c packagename
This will copy the sample initd and confd files to the build directory. A third file sample.install file will be copied as well (we will discuss this later on).