2018-02-08 Bitlbee on Windows with Cygwin

Installing Bitlbee on Windows with Cygwin... I had to install the development packages of libglib2, gnutls and libgcrpyt using Cygwin:

$ ./configure --msn=0 --jabber=0 --oscar=0 --twitter=0
BitlBee configure
Architecture: CYGWIN_NT-6.1

Configuration done:
  Debugging disabled.
  AddressSanitizer (ASAN) disabled.
  Building non-PIE executable
  Binary stripping disabled.
  Off-the-Record (OTR) Messaging disabled.
  systemd disabled.
  Using event handler: glib
  Using SSL library: gnutls
  Building without IM-protocol support. We wish you a lot of fun...

I like how there is an extra comment if you disable all the protocols. All I want is the Mastodon plugin!

make install
make install-dev

No problems, so far.

For the Mastodon plugin, some more stuff was required. I already had autoconf installed but libtool and automake was missing. Notice how I had to set the environment variable. PKG_CONFIG_PATH. When I made install-dev above, I saw the output install -p -m 0644 bitlbee.pc /usr/local/lib/pkgconfig so I assumed everything had been installed correctly. I don’t know why this is considered to be a non-standard location but here we are.

PKG_CONFIG_PATH=/usr/local/lib/pkgconfig/ ./configure

Sadly, linking still fails.

libtool:   error: can't build x86_64-unknown-cygwin shared library unless -no-undefined is specified

The solution to that is to add a line in src/Makefile. In this fragment, the line with $(BITLBEE_LIBS) is new.

mastodon_la_LDFLAGS = \
	-module \
	-avoid-version \

Now you should be able to build it:

make install
libtool --finish /usr/local/lib/bitlbee/

And you can start it:

mkdir /usr/local/etc/bitlbee
touch /usr/local/etc/bitlbee/bitlbee.conf
mkdir /var/lib/bitlbee
/usr/local/sbin/bitlbee -nD

But notice the warning:

Warning: Can't find function `init_plugin_info' in `/usr/local/lib/bitlbee/mastodon.dll'

This does not bode well.

But you can connect using your favorite IRC client!

Help works!

help mastodon

And thus:

register *secret*
account add mastodon @kensanata
account mastodon set base_url https://octodon.social/api/v1
account mastodon on

I’m getting a message with the URL from mastodon_oauth, get the token from the website, and I’m online!

Don’t forget to save your bitlbee account and your Mastodon account:





The same goes for bitlbee-discord:

PKG_CONFIG_PATH=/usr/local/lib/pkgconfig/ ./configure

Fix src/Makefile:

discord_la_LDFLAGS = \
	-module \
	-avoid-version \

And continue:

make install
libtool --finish /usr/local/lib/bitlbee/

Start bitlbee. Verify that plugins in the &bitlbee channel shows discord.

Don’t forget how much work it is to set up channels:

  1. chat list discord
  2. chat add discord !1 #mydiscordchannel
  3. chan #mydiscordchannel set auto_join true
  4. /join #mydiscordchannel

Repeat steps 2-4 for every channel you want to join.

– Alex Schroeder 2018-03-19 09:36 UTC

I dropped all my Discord stuff, though.

– Alex Schroeder 2018-05-22 14:17 UTC

I’m always surprised to find things still work.

This still works!

– Alex Schroeder 2018-10-31 14:54 UTC

Please make sure you contribute only your own work, or work licensed under the GNU Free Documentation License. Note: in order to facilitate peer review and fight vandalism, we will store your IP number for a number of days. See Privacy Policy for more information. See Info for text formatting rules. You can edit the comment page if you need to fix typos. You can subscribe to new comments by email without leaving a comment.

To save this page you must answer this question:

Please say HELLO.