[PATCH] PAM Support for Busybox Login

Bernhard Fischer rep.nop at aon.at
Sun Oct 1 11:54:11 UTC 2006


On Sun, Oct 01, 2006 at 12:00:02PM +0200, Denis Vlasenko wrote:
>On Friday 29 September 2006 23:26, Thaddeus Ternes wrote:
>> Previously, a patch for Busybox login was shared on the list that
>> added PAM support to 1.0.0.  That patch no longer applies to 1.2.1, so
>> I did some work to fix it up, as well as make it a bit easier to build
>> (thanks for the help on that, Jason).
>> 
>> Here's the original patch:
>> http://www.busybox.net/lists/busybox/2004-December/013257.html
>> 
>> And attached is my swing at it (should patch cleanly against 1.2.1).
>> 
>> All comments appreciated.

>-cmd_link           = $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $(LDFLAGS) \
>+cmd_link           = $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $(LDFLAGS) $(EXTRA_LDFLAGS) \
>                        $(PROG_CFLAGS) $(PROG_LDFLAGS) $(CFLAGS_COMBINE) \
>                        -o $@ $(LD_START_GROUP)  \
>                        $(APPLETS_DEFINE) $(APPLET_SRC) \
>                        $(BUSYBOX_DEFINE) $(BUSYBOX_SRC) $(libraries-y) \
>-                       $(LDBUSYBOX) $(LIBRARIES) \
>+                       $(LDBUSYBOX) $(LIBRARIES) $(EXTRA_LIBS) \
>                        $(LD_END_GROUP)

This doesn't sound correct.
Looks like you should rather say
 ifeq ($(strip $(CONFIG_SELINUX)),y)
     LIBRARIES += -lselinux -lsepol
 endif
+
+ifeq ($(strip $(CONFIG_PAM)),y)
+    LIBRARIES += -lpam
+endif

Maybe the PWDLOOKUP shouldn't be emitted that often but be kept out of
line to add less to the size.

>Generally I like it.

seconded.
>
>Maybe will add CONFIG_DESKTOP to make such options
>visible only for fat "desktop replacement"-class bbox.
>So that embedded people will not feel like
>bbox is going to be horribly bloated now.

I'd say that CONFIG_PAM falls under the same category as LFS and
LOCALE support, so i would rather put it into the 'Build Options'
submenu than creating a separate CONFIG_DESKTOP. Just a thought.



More information about the busybox mailing list