Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

packaging: add native debian package #15

Merged
merged 1 commit into from
Jun 10, 2024
Merged

Conversation

cjp256
Copy link
Collaborator

@cjp256 cjp256 commented Apr 12, 2024

For development purposes, add native debian packaging.

  • Add build-deb.sh to /scripts/

  • Add debian package metadata to /packaging/debian

  • Add a starter manpage to /doc in markdown format, using pandoc to convert to manpage.

  • Add github workflow to validate debs.

  • Move azure-nvme-id.spec to /packaging/azurelinux. It may work for other RPM distros too, but will revisit structure upon validating Fedora, etc.

@cjp256 cjp256 force-pushed the native-deb branch 9 times, most recently from d968b30 to 324ea74 Compare April 12, 2024 19:12
Copy link
Collaborator

@nmeyerhans nmeyerhans left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good over all, just a few relatively minor suggestions.

CMakeLists.txt Outdated Show resolved Hide resolved
.github/workflows/debs.yml Outdated Show resolved Hide resolved
scripts/build-deb.sh Outdated Show resolved Hide resolved
packaging/debian/changelog Outdated Show resolved Hide resolved
@cjp256 cjp256 force-pushed the native-deb branch 3 times, most recently from 393c9ca to 03c291e Compare May 1, 2024 18:36
@cjp256 cjp256 requested a review from nmeyerhans May 1, 2024 18:38
@cjp256 cjp256 force-pushed the native-deb branch 4 times, most recently from 2154369 to d60d0e8 Compare May 2, 2024 14:37
Copy link
Collaborator

@nmeyerhans nmeyerhans left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lintian detects the following warnings from groff on sid:

W: azure-nvme-utils: groff-message troff:<standard input>:50: warning: cannot select font 'C' [usr/share/man/man1/azure-nvme-id.1.gz:2]
W: azure-nvme-utils: groff-message troff:<standard input>:5: warning: cannot select font 'CB' [usr/share/man/man1/azure-nvme-id.1.gz:1]
W: azure-nvme-utils: groff-message troff:<standard input>:60: warning: cannot select font 'C' [usr/share/man/man1/azure-nvme-id.1.gz:3]
W: azure-nvme-utils: groff-message troff:<standard input>:72: warning: cannot select font 'C' [usr/share/man/man1/azure-nvme-id.1.gz:4]

This appears to be a pandoc issue and may be fixed upstream. I'm not sure if this can be worked around in the input file or not, but it's probably worth a try. You can see the warnings yourself with

$ man -l obj-x86_64-linux-gnu/doc/azure-nvme-id.1  > /dev/null
troff:<standard input>:5: warning: cannot select font 'CB'
troff:<standard input>:50: warning: cannot select font 'C'
troff:<standard input>:60: warning: cannot select font 'C'
troff:<standard input>:72: warning: cannot select font 'C'

packaging/debian/control Outdated Show resolved Hide resolved
scripts/build-deb.sh Show resolved Hide resolved
.gitignore Outdated Show resolved Hide resolved
cjp256 added a commit to cjp256/azure-vm-utils that referenced this pull request Jun 6, 2024
As pointed out by Noah in Azure#15, Debian packaging lints issues in the
generated manpage due to formatting emitted by older versions of pandoc:
jgm/pandoc#9020

While changes in recent versions of pandoc have improved the output,
let's just take the generated output from pandoc 3.2 as a starting point
and maintain it manually for the time being.  This reduces friction for
packaging and gives us flexibility if we wanted to do something in the
manpage that pandoc doesn't support.

Signed-off-by: Chris Patterson <[email protected]>
cjp256 added a commit to cjp256/azure-vm-utils that referenced this pull request Jun 6, 2024
As pointed out by Noah in Azure#15, Debian packaging lints issues in the
generated manpage due to formatting emitted by older versions of pandoc:
jgm/pandoc#9020

While changes in recent versions of pandoc have improved the output,
let's just take the generated output from pandoc 3.2 as a starting point
and maintain it manually for the time being.  This reduces friction for
packaging and gives us flexibility if we wanted to do something in the
manpage that pandoc doesn't support.

Allow manpages to be generated at build-time with -DGENERATE_MANPAGES=1.

Signed-off-by: Chris Patterson <[email protected]>
cjp256 added a commit to cjp256/azure-vm-utils that referenced this pull request Jun 6, 2024
As pointed out by Noah in Azure#15, Debian packaging lints issues in the
generated manpage due to formatting emitted by older versions of pandoc:
jgm/pandoc#9020

While changes in recent versions of pandoc have improved the output,
let's just take the generated output from pandoc 3.2 as a starting point
and maintain it manually for the time being.  This reduces friction for
packaging and gives us flexibility if we wanted to do something in the
manpage that pandoc doesn't support.

Allow manpages to be generated at build-time with -DGENERATE_MANPAGES=1
which will make it easy to sync.

Signed-off-by: Chris Patterson <[email protected]>
cjp256 added a commit to cjp256/azure-vm-utils that referenced this pull request Jun 6, 2024
As pointed out by Noah in Azure#15, Debian packaging lints issues in the
generated manpage due to formatting emitted by older versions of pandoc:
jgm/pandoc#9020

While changes in recent versions of pandoc have improved the output,
let's just take the generated output from pandoc 3.2 as a starting point
and maintain it manually for the time being.  This reduces friction for
packaging and gives us flexibility if we wanted to do something in the
manpage that pandoc doesn't support.

Allow manpages to be generated at build-time with -DGENERATE_MANPAGES=1
which will make it easy to sync.

Signed-off-by: Chris Patterson <[email protected]>
cjp256 added a commit to cjp256/azure-vm-utils that referenced this pull request Jun 6, 2024
As pointed out by Noah in Azure#15, Debian packaging lints issues in the
generated manpage due to formatting emitted by older versions of pandoc:
jgm/pandoc#9020

While changes in recent versions of pandoc have improved the output,
let's just take the generated output from pandoc 3.2 as a starting point
and maintain it manually for the time being.  This reduces friction for
packaging and gives us flexibility if we wanted to do something in the
manpage that pandoc doesn't support.

Allow manpages to be generated at build-time with -DGENERATE_MANPAGES=1
which will make it easy to sync.

Signed-off-by: Chris Patterson <[email protected]>
cjp256 added a commit to cjp256/azure-vm-utils that referenced this pull request Jun 6, 2024
As pointed out by Noah in Azure#15, Debian packaging lints issues in the
generated manpage due to formatting emitted by older versions of pandoc:
jgm/pandoc#9020

While changes in recent versions of pandoc have improved the output,
let's just take the generated output from pandoc 3.2 as a starting point
and maintain it manually for the time being.  This reduces friction for
packaging and gives us flexibility if we wanted to do something in the
manpage that pandoc doesn't support.

Allow manpages to be generated at build-time with -DGENERATE_MANPAGES=1
which will make it easy to sync.

Signed-off-by: Chris Patterson <[email protected]>
cjp256 added a commit to cjp256/azure-vm-utils that referenced this pull request Jun 6, 2024
As pointed out by Noah in Azure#15, Debian packaging lints issues in the
generated manpage due to formatting emitted by older versions of pandoc:
jgm/pandoc#9020

While changes in recent versions of pandoc have improved the output,
let's just take the generated output from pandoc 3.2 as a starting point
and maintain it manually for the time being.  This reduces friction for
packaging and gives us flexibility if we wanted to do something in the
manpage that pandoc doesn't support.

Allow manpages to be generated at build-time with -DGENERATE_MANPAGES=1
which will make it easy to sync.

Signed-off-by: Chris Patterson <[email protected]>
cjp256 added a commit to cjp256/azure-vm-utils that referenced this pull request Jun 6, 2024
As pointed out by Noah in Azure#15, Debian packaging lints issues in the
generated manpage due to formatting emitted by older versions of pandoc:
jgm/pandoc#9020

While changes in recent versions of pandoc have improved the output,
let's just take the generated output from pandoc 3.2 as a starting point
and maintain it manually for the time being.  This reduces friction for
packaging and gives us flexibility if we wanted to do something in the
manpage that pandoc doesn't support.

Allow manpages to be generated at build-time with -DGENERATE_MANPAGES=1
which will make it easy to sync.

Signed-off-by: Chris Patterson <[email protected]>
cjp256 added a commit to cjp256/azure-vm-utils that referenced this pull request Jun 6, 2024
As pointed out by Noah in Azure#15, Debian packaging lints issues in the
generated manpage due to formatting emitted by older versions of pandoc:
jgm/pandoc#9020

While changes in recent versions of pandoc have improved the output,
let's just take the generated output from pandoc 3.2 as a starting point
and maintain it manually for the time being.  This reduces friction for
packaging and gives us flexibility if we wanted to do something in the
manpage that pandoc doesn't support.

Allow manpages to be generated at build-time with -DGENERATE_MANPAGES=1
which will make it easy to sync.

Signed-off-by: Chris Patterson <[email protected]>
cjp256 added a commit to cjp256/azure-vm-utils that referenced this pull request Jun 6, 2024
As pointed out by Noah in Azure#15, Debian packaging lints issues in the
generated manpage due to formatting emitted by older versions of pandoc:
jgm/pandoc#9020

While changes in recent versions of pandoc have improved the output,
let's just take the generated output from pandoc 3.2 as a starting point
and maintain it manually for the time being.  This reduces friction for
packaging and gives us flexibility if we wanted to do something in the
manpage that pandoc doesn't support.

Allow manpages to be generated at build-time with -DGENERATE_MANPAGES=1
which will make it easy to sync.

Signed-off-by: Chris Patterson <[email protected]>
@cjp256
Copy link
Collaborator Author

cjp256 commented Jun 6, 2024

lintian detects the following warnings from groff on sid:

W: azure-nvme-utils: groff-message troff:<standard input>:50: warning: cannot select font 'C' [usr/share/man/man1/azure-nvme-id.1.gz:2]
W: azure-nvme-utils: groff-message troff:<standard input>:5: warning: cannot select font 'CB' [usr/share/man/man1/azure-nvme-id.1.gz:1]
W: azure-nvme-utils: groff-message troff:<standard input>:60: warning: cannot select font 'C' [usr/share/man/man1/azure-nvme-id.1.gz:3]
W: azure-nvme-utils: groff-message troff:<standard input>:72: warning: cannot select font 'C' [usr/share/man/man1/azure-nvme-id.1.gz:4]

This appears to be a pandoc issue and may be fixed upstream. I'm not sure if this can be worked around in the input file or not, but it's probably worth a try. You can see the warnings yourself with

$ man -l obj-x86_64-linux-gnu/doc/azure-nvme-id.1  > /dev/null
troff:<standard input>:5: warning: cannot select font 'CB'
troff:<standard input>:50: warning: cannot select font 'C'
troff:<standard input>:60: warning: cannot select font 'C'
troff:<standard input>:72: warning: cannot select font 'C'

Addressing with #27

Copy link
Collaborator

@nmeyerhans nmeyerhans left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any reason not to squash cc097bc ("fix description in debian/control") into 49e60b6 ("packaging: add native debian package")?

packaging/debian/control Outdated Show resolved Hide resolved
For development purposes, add native debian packaging.

- Add debian package metadata to /packaging/debian

- Add build-deb.sh to /scripts/ to build the debs

- Add github workflow to validate debs

Signed-off-by: Chris Patterson <[email protected]>
@cjp256
Copy link
Collaborator Author

cjp256 commented Jun 10, 2024

Any reason not to squash cc097bc ("fix description in debian/control") into 49e60b6 ("packaging: add native debian package")?

Squashed. Sometimes I try to be github-review-friendly and squash on merge. :)

@cjp256 cjp256 merged commit ce52d7f into Azure:main Jun 10, 2024
5 checks passed
@cjp256 cjp256 deleted the native-deb branch June 10, 2024 13:16
cjp256 added a commit to cjp256/azure-vm-utils that referenced this pull request Jun 10, 2024
As pointed out by Noah in Azure#15, Debian packaging lints issues in the
generated manpage due to formatting emitted by older versions of pandoc:
jgm/pandoc#9020

While changes in recent versions of pandoc have improved the output,
let's just take the generated output from pandoc 3.2 as a starting point
and maintain it manually for the time being.  This reduces friction for
packaging and gives us flexibility if we wanted to do something in the
manpage that pandoc doesn't support.

Allow manpages to be generated at build-time with -DGENERATE_MANPAGES=1
which will make it easy to sync.

Signed-off-by: Chris Patterson <[email protected]>
cjp256 added a commit that referenced this pull request Jun 10, 2024
As pointed out by Noah in #15, Debian packaging lints issues in the
generated manpage due to formatting emitted by older versions of pandoc:
jgm/pandoc#9020

While changes in recent versions of pandoc have improved the output,
let's just take the generated output from pandoc 3.2 as a starting point
and maintain it manually for the time being.  This reduces friction for
packaging and gives us flexibility if we wanted to do something in the
manpage that pandoc doesn't support.

Allow manpages to be generated at build-time with -DGENERATE_MANPAGES=1
which will make it easy to sync.

Signed-off-by: Chris Patterson <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants