[Pommed-commits] [SCM] pommed - hotkeys handler for Apple laptops branch, master, updated. 1.35-4-ged3c5e2

Julien BLACHE jb at jblache.org
Fri Dec 24 19:54:14 UTC 2010


The following commit has been merged in the master branch:
commit ed3c5e2f282565c3069b7982604ff2aa2541756c
Author: Julien BLACHE <jb at jblache.org>
Date:   Fri Dec 24 20:52:50 2010 +0100

    Use LDLIBS instead of adding libraries to LDFLAGS
    
    Issue reported by Matthias Klose <doko at ubuntu.com>.

diff --git a/ChangeLog b/ChangeLog
index a7ecf3f..ea32c5e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -4,6 +4,7 @@ ChangeLog for pommed
 version 1.36:
 	- pommed: probe for applesmc through /sys/class/hwmon.
 	- pommed: add support for the MacBook7,1 (April 2010).
+	- all: use LDLIBS instead of adding libraries to LDFLAGS.
 
 version 1.35:
 	- pommed: fix crash if no fnmode sysfs node found.
diff --git a/gpomme/Makefile b/gpomme/Makefile
index 42c51dd..0874b48 100644
--- a/gpomme/Makefile
+++ b/gpomme/Makefile
@@ -15,7 +15,7 @@ CONFUSE_LIBS = $(shell pkg-config libconfuse --libs)
 INOTIFY_CFLAGS = $(shell test -e /usr/include/sys/inotify.h || echo -DNO_SYS_INOTIFY_H)
 
 CFLAGS = -g -O2 -Wall $(DBUS_CFLAGS) $(DBUSGLIB_CFLAGS) $(GTK_CFLAGS) $(CONFUSE_CFLAGS) $(INOTIFY_CFLAGS)
-LDFLAGS = -lpthread -lX11 $(DBUS_LIBS) $(DBUSGLIB_LIBS) $(GTK_LIBS) $(CONFUSE_LIBS)
+LDLIBS = -lpthread -lX11 $(DBUS_LIBS) $(DBUSGLIB_LIBS) $(GTK_LIBS) $(CONFUSE_LIBS)
 
 SOURCES = gpomme.c theme.c conffile.c \
 		../client-common/dbus-client.c \
@@ -29,7 +29,7 @@ all: gpomme mo
 
 mo: $(MOFILES)
 
-gpomme: $(OBJS) $(LIBS)
+gpomme: $(OBJS)
 
 gpomme.o: gpomme.c gpomme.h theme.h ../client-common/dbus-client.h ../client-common/video-client.h
 
diff --git a/pommed/Makefile b/pommed/Makefile
index b99636f..5f3cbf9 100644
--- a/pommed/Makefile
+++ b/pommed/Makefile
@@ -20,7 +20,9 @@ TIMERFD_CFLAGS = $(shell test -e /usr/include/sys/timerfd.h || echo -DNO_SYS_TIM
 
 CFLAGS = -g -O2 -Wall $(DBUS_CFLAGS) $(ALSA_CFLAGS) $(AUDIOFILE_CFLAGS) $(CONFUSE_CFLAGS) $(INOTIFY_CFLAGS) $(TIMERFD_CFLAGS)
 
-LDFLAGS = -pthread -lrt $(DBUS_LIBS) $(ALSA_LIBS) $(AUDIOFILE_LIBS) $(CONFUSE_LIBS)
+LDLIBS = -pthread -lrt $(DBUS_LIBS) $(ALSA_LIBS) $(AUDIOFILE_LIBS) $(CONFUSE_LIBS)
+
+LIB_OBJS =
 
 ifneq (, $(findstring ppc, $(ARCH)))
 OFLIB ?=
@@ -37,9 +39,9 @@ OF_OBJS = $(OF_SOURCES:%.c=%.o)
 
 ifneq ($(OFLIB),)
 CFLAGS += -Ipmac
-LIBS = pmac/ofapi/oflib.a
+LIB_OBJS += pmac/ofapi/oflib.a
 else
-LDFLAGS += -lofapi
+LDLIBS += -lofapi
 endif
 
 else
@@ -51,12 +53,14 @@ ifeq ($(LIBPCI_SHARED), true)
 	LIBPCI_LIBS = $(shell pkg-config libpci --libs)
 
 	CFLAGS += $(LIBPCI_CFLAGS)
-	LDFLAGS += $(LIBPCI_LIBS)
+	LDLIBS += $(LIBPCI_LIBS)
 else
-	LIBS = /usr/lib/libpci.a
-	LDFLAGS += -lz	
+	LIB_OBJS += /usr/lib/libpci.a
+	LDLIBS += -lz
 endif
 
+LDLIBS += $(LIB_OBJS)
+
 SOURCES = pommed.c cd_eject.c evdev.c conffile.c audio.c \
 		evloop.c dbus.c power.c beep.c video.c \
 		sysfs_backlight.c \
@@ -68,7 +72,7 @@ endif
 OBJS = $(SOURCES:%.c=%.o)
 
 
-pommed: $(OBJS) $(LIBS)
+pommed: $(OBJS) $(LIB_OBJS)
 
 pommed.o: pommed.c pommed.h evloop.h kbd_backlight.h lcd_backlight.h cd_eject.h evdev.h conffile.h audio.h dbus.h beep.h
 
diff --git a/wmpomme/Makefile b/wmpomme/Makefile
index 4139cc0..cc7a438 100644
--- a/wmpomme/Makefile
+++ b/wmpomme/Makefile
@@ -6,7 +6,7 @@ DBUS_LIBS = $(shell pkg-config dbus-1 --libs)
 TIMERFD_CFLAGS = $(shell test -e /usr/include/sys/timerfd.h || echo -DNO_SYS_TIMERFD_H)
 
 CFLAGS = -g -O2 -Wall $(DBUS_CFLAGS) $(TIMERFD_CFLAGS)
-LDFLAGS = -lrt -lXpm -lXext -lX11 $(DBUS_LIBS)
+LDLIBS = -lrt -lXpm -lXext -lX11 $(DBUS_LIBS)
 
 SOURCES = wmgeneral.c wmpomme.c \
 	../client-common/dbus-client.c \

-- 
pommed - hotkeys handler for Apple laptops



More information about the Pommed-commits mailing list