TritonDataCenter / pkgsrc

NetBSD/pkgsrc fork for our binary package repositories
https://pkgsrc.smartos.org/
132 stars 51 forks source link

mosquitto not found in trunk #302

Open bahamas10 opened 3 years ago

bahamas10 commented 3 years ago
$ pkgin search mosquitto
No results found for mosquitto

I can compile it manually with:

curl -o mosquitto.tar.gz https://mosquitto.org/files/source/mosquitto-2.0.10.tar.gz
mkdir src
tar -xf mosquitto.tar.gz -C src --strip-components=1
cd src/

I then edited config.mk to set WITH_CJSON=no as it failed to compile with it enabled (and i don't personally need it). After, I ran:

prefix=/opt/local make
prefix=/opt/local make install

and it installed.

mosquitto works:

$ mosquitto -h
mosquitto version 2.0.10

pub and sub kinda work:

$ mosquitto_pub --help
ld.so.1: mosquitto_pub: fatal: ../lib/libmosquitto.so.1: open failed: No such file or directory
Killed
$ cd /opt/local/bin/
$ mosquitto_pub --help
mosquitto_pub is a simple mqtt client that will publish a message on a single topic and exit.
mosquitto_pub version 2.0.10 running on libmosquitto 2.0.10.

I want to say this was a known issue and there was some sort of patch for this? I'm not certain though. I spoke with @papertigers and he said to ping @sjorge on this.

papertigers commented 3 years ago

Hmm it looks like its in 2020Q4: https://pkgsrc.joyent.com/packages/SmartOS/2020Q4/x86_64/All/mosquitto-1.6.12nb1.tgz

My first guess is that it failed in the trunk bulk build. Not sure if those logs are published anywhere.

sjorge commented 3 years ago

Yeah 2020Q4 had it! I guess something new broke :( My zone using it is still on 2020Q4.

jperkin commented 3 years ago

Yeh it doesn't detect broken epoll correctly: https://us-east.manta.joyent.com/pkgsrc/public/reports/trunk/x86_64/20210422.1237/mosquitto-2.0.10/build.log

The latest trunk build report is here for other failures: https://us-east.manta.joyent.com/pkgsrc/public/reports/trunk/x86_64/20210422.1237/meta/report.html

bahamas10 commented 3 years ago

Forgive my ignorance here, but do trunk built packages need to work on a system with a broken epoll header? I did some digging into mosquitto and found that epoll support is relatively new, and can be disabled by setting:

WITH_EPOLL:=no

In the config.mk file at the root of the source tree - I'm not sure of any performance penalties or the like that comes with that config option.