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

Add package MQTTSuite, a lightweight MQTT Integration System #23591

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

VolkerChristian
Copy link

@TomJo2000
Copy link
Member

By the way, it is completely permissible to add a package and its dependencies in a single PR with separate commits (for future reference)

Copy link
Member

@TomJo2000 TomJo2000 left a comment

Choose a reason for hiding this comment

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

Thank you for your contribution.
I've left you a couple suggestions.

I also can't help but notice that this seems to be a new personal project of yours.
We have a "package request checklist", an abridged version of which I'll go through below.
But tl;dr, we usually prefer packaging established packages with a history of frequent development, and existing packages.

  • The project is actively developed.

  • The project has existing packages and is "well known".

  • Licensed under an open source license.

  • Not available through a language package manager: pip, npm, cpan, cargo, etc.

  • Not taking up too much disk space (< 100MiB per architecture, exceptions can be made)

  • Not duplicating the functionality of existing packages.

  • Not serving hacking, malware, phishing, spamming, spying, ddos functionality.

  • I certify that I have read Termux Packaging Policy and understand that my request will be denied if it is found lacking.

These requirements aren't absolute.
But are what we generally take into account for adding packages to the main repository.
You may want to consider submitting this package (and its dependencies) to the TUR instead.
Which has less strict criteria for packages.

You are of course welcome to keep this PR open to work out any build issues.

@@ -0,0 +1,10 @@
TERMUX_PKG_HOMEPAGE=https://github.com/SNodeC/mqttsuite
TERMUX_PKG_DESCRIPTION="MQTTSuite: A lightweight MQTT Integration System"
TERMUX_PKG_LICENSE="MIT OR LGPL-3.0-or-later"
Copy link
Member

Choose a reason for hiding this comment

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

Multiple licenses should be delimited with a comma.

Suggested change
TERMUX_PKG_LICENSE="MIT OR LGPL-3.0-or-later"
TERMUX_PKG_LICENSE="MIT, LGPL-3.0-or-later"

For example see ipfs:

TERMUX_PKG_LICENSE="MIT, Apache-2.0"

TERMUX_PKG_HOMEPAGE=https://github.com/SNodeC/mqttsuite
TERMUX_PKG_DESCRIPTION="MQTTSuite: A lightweight MQTT Integration System"
TERMUX_PKG_LICENSE="MIT OR LGPL-3.0-or-later"
TERMUX_PKG_LICENSE_FILE="LICENSE"
Copy link
Member

@TomJo2000 TomJo2000 Mar 3, 2025

Choose a reason for hiding this comment

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

Suggested change
TERMUX_PKG_LICENSE_FILE="LICENSE"

The license file only needs to be specified if the build system is unable to find it in the "common license files" list.

local COMMON_LICENSE_FILES=( # search list for licenses with copyright information
'COPYING' 'Copyright.txt'
'copyright' 'Copyright' 'COPYRIGHT'
'licence' 'Licence' 'LICENCE' # spelled with 'C'
'license' 'License' 'LICENSE' # spelled with 'S'
'license.txt' 'License.txt'
'LICENSE.txt' 'LICENSE.TXT'
'license.md' 'LICENSE.md'
)

TERMUX_PKG_LICENSE_FILE="LICENSE"
TERMUX_PKG_MAINTAINER="VolkerChristian"
TERMUX_PKG_VERSION=1.0
TERMUX_PKG_SRCURL="git+https://github.com/SNodeC/mqttsuite.git"
Copy link
Member

@TomJo2000 TomJo2000 Mar 3, 2025

Choose a reason for hiding this comment

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

We usually prefer building from release tarballs.

Suggested change
TERMUX_PKG_SRCURL="git+https://github.com/SNodeC/mqttsuite.git"
TERMUX_PKG_SRCURL="https://github.com/SNodeC/mqttsuite/archive/refs/tags/v${TERMUX_PKG_VERSION}.tar.gz"

This also allows us to verify the release tarball via the TERMUX_PKG_SHA256 checksum.

TERMUX_PKG_MAINTAINER="VolkerChristian"
TERMUX_PKG_VERSION=1.0
TERMUX_PKG_SRCURL="git+https://github.com/SNodeC/mqttsuite.git"
TERMUX_PKG_DEPENDS="fmt,snode.c"
Copy link
Member

Choose a reason for hiding this comment

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

Dependency lists usually include a space between entries for readability,
though this isn't strictly required.

Suggested change
TERMUX_PKG_DEPENDS="fmt,snode.c"
TERMUX_PKG_DEPENDS="fmt, snode.c"

TERMUX_PKG_VERSION=1.0
TERMUX_PKG_SRCURL="git+https://github.com/SNodeC/mqttsuite.git"
TERMUX_PKG_DEPENDS="fmt,snode.c"
TERMUX_PKG_FORCE_CMAKE=true
Copy link
Member

@TomJo2000 TomJo2000 Mar 3, 2025

Choose a reason for hiding this comment

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

Specifying TERMUX_PKG_FORCE_CMAKE is rarely necessary.

@VolkerChristian
Copy link
Author

Thank you for the hints! I will prepare pull requests for TUR.

@TomJo2000
Copy link
Member

Since you are a first time contributor a maintainer will need to approve your CI builds, I apologize for any delays caused by this.

You may want to consider using our build container locally for build testing.
E.g.

./scripts/run-docker.sh ./build-package.sh -I -f -a all mqttsuite
  • -I instructs the build system to download dependencies from the Termux repos when possible instead of building them locally
  • -f forces rebuilds of the specified packages even if they have already been built locally.
  • -a all specifies that the packages should be built for all 4 architectures supported on Termux. (aarch64,arm,i686 and x86_64)

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