openwrt / packages

Community maintained packages for OpenWrt. Documentation for submitting pull requests is in CONTRIBUTING.md
GNU General Public License v2.0
3.94k stars 3.46k forks source link

Package libmosquittopp is missing dependencies for the following libraries: libmosquitto.so.1 #7794

Open stintel opened 5 years ago

stintel commented 5 years ago

Maintainer: @karlp Environment: OpenWrt master

Description: Trying to build an image with libmosquittopp included and keep running into this issue:

Package libmosquittopp is missing dependencies for the following libraries:
libmosquitto.so.1

This problem has been occurring me for quite some time, we've talked about it in IRC before but never found a fix. This happens after make dirclean. I usually work around it with this hack:

diff --git a/include/package-ipkg.mk b/include/package-ipkg.mk
index c374faa647..49feb97d4d 100644
--- a/include/package-ipkg.mk
+++ b/include/package-ipkg.mk
@@ -75,7 +75,7 @@ ifneq ($(PKG_NAME),toolchain)
                if [ -f "$(PKG_INFO_DIR)/$(1).missing" ]; then \
                        echo "Package $(1) is missing dependencies for the following libraries:" >&2; \
                        cat "$(PKG_INFO_DIR)/$(1).missing" >&2; \
-                       false; \
+                       true; \
                fi; \
        )
   endef

Mosquitto related symbols in config:

$ grep -i mosquitto .config
# CONFIG_PACKAGE_libmosquitto-nossl is not set
CONFIG_PACKAGE_libmosquitto-ssl=y
CONFIG_PACKAGE_libmosquittopp=y
# CONFIG_PACKAGE_mosquitto-client-nossl is not set
# CONFIG_PACKAGE_mosquitto-client-ssl is not set
CONFIG_PACKAGE_mosquitto-nossl=y
# CONFIG_PACKAGE_mosquitto-ssl is not set
neheb commented 5 years ago

@stintel try https://github.com/openwrt/packages/pull/7772

Maybe the libmosquitto depends needs a +.

Or it's not being installed properly.

karlp commented 5 years ago

It can't be a + depends, because you can't autoselect the virtual package. I'll be back to work tomorrow and will be looking at this.

karlp commented 5 years ago

@stintel do you reallllly have mosquitto without ssl, but libmosquitto with ssl? I mean, I guess that should work, but was that the goal?

karlp commented 5 years ago

I can confirm the issue if you have mosquitto-ssl + libmosquitto-nossl, but it works if you have mosquitto-ssl+libmosquitto-ssl or mosquitto-nossl + libmosquitto-nossl.

I can only presume this is a build system problem with dependency tracking. I'm not sure what I can do about it really, and while it should be a legal build combination, it's not really a very useful build combination IMO?

stintel commented 5 years ago

Using libmosquitto-ssl for vallumd, which connects to a public MQTT broker with SSL, and running mosquitto-nossl internally, used by Domoticz and some sensor devices. I don't need SSL for that, and I usually select only what I need.

I can do mosquitto-ssl+libmosquitto-ssl as workaround for now, but would be nice if this can be fixed eventually.

karlp commented 5 years ago

Well, it's a build issue, not a mosquitto issue, so there's nothing else I can do about it right now. We could try making -ssl and -nossl variants for libmosquittopp too maybe? might help?

dreirund commented 2 years ago

Well, it's a build issue, not a mosquitto issue, so there's nothing else I can do about it right now.

Where should it be reported then?