Mathias Hasselmann

Postings by Mathias on March 27, 2008

#ifndef LIBRARY_IS_GPL

There are libraries, which are licensed under GPL, instead of LGPL. This puts people under the risk of accidentely violating the copyright of that library, by using the GPL library from some LGPL library for instance. Well, also could be that doing that changes the license of your LGPL library to GPL or whatever. Don't really want to think about the horrible implications of accidently using a GPL library from some LGPL library.

Half jokingly (I assume) Matthew suggested a solution for that problem:

#ifndef LIBRARY_IS_GPL
#error "Library is released under the terms of the GNU General Public License. Define LIBRARY_IS_GPL to acknowledge this license."
#endif

I really like this idea.

GTK+ Binding Usage

Misread a statement from Mikael Hallendal on gtk-devel-list today.

He wrote:

For example the C# bindings are not on the GNOME bindings page, even
though it is one of the most used and high quality bindings for GTK+.

I read:

it is the most used and high quality bindings for GTK+

Wanted to counter proof this statement he never did, so I ran this tiny script on apt's package list:

for b in libgtk2.0 python-gtk libgtk2.0-cil libgtk2-perl libgtk2-ruby
do
  c=$(expr 0 $(grep -c "^Depends:.*\\<$b" \
      /var/lib/apt/lists/*archive.ubuntu.com_ubuntu_dists* |\
      sed 's/.*:/+ /'))
  printf '%-15s %5d\n' $b: $c
done
Gutsy Hardy
libgtk2.0: 1535 1530
python-gtk: 208 221
libgtkmm-2: 85 89
libgtk2.0-cil: 54 54
libgtk2-perl: 42 45
libgtk-(java|jni|cni): 24 22
libgtk2-ruby: 17 18
liblablgtk2-ocaml: 15 15
libgtkada-2: 7 7
libghc6-gtk-dev: 10 5

Nothing surprising it seems.

Update: Readers pointed out that I missed the widely used gtkmm bindings. Added them and some less frequently used bindings. Added emphasis.