lhb-jr/eudev — pull request #1 by lhb-jr (2014-03-22 01:26:54+00:00)
Title: Rundir

This patch improves upon a previous patch that removes the hard-coding of '/run/udev' throughout the code. As a bonus, it also remedies the ucred undeclared warnings that riddle the compilation. It does this by adding an autoconf file containing global variables for Makefiles (Makefile-globals.am) which is included by each sub-packages own Makefile.am. Neither autoconf nor 'make' ever see it. Using this mechanism, a '-DUDEV_RUN_DIR=/var/run/udev' can be added to AM_CPPFLAGS (...along with -D_GNU_SOURCE which solves the ucred problem). This mechanism creates an easy way to add global variables to Makefiles without going through each subpackage, is more maintainable and thus less liable to be buggy.

A '--with-rundir=....' option is also added to the configure script, so that the user may change the default (which I chose to be '/var/run/udev' , which is consistent with Linux Filesystem standard.