summaryrefslogtreecommitdiff
path: root/x11-plugins/gkrellsun/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2022-05-12 16:42:50 +0300
committerV3n3RiX <venerix@koprulu.sector>2022-05-12 16:42:50 +0300
commit752d6256e5204b958b0ef7905675a940b5e9172f (patch)
tree330d16e6362a49cbed8875a777fe641a43376cd3 /x11-plugins/gkrellsun/files
parent0c100b7dd2b30e75b799d806df4ef899fd98e1ea (diff)
gentoo resync : 12.05.2022
Diffstat (limited to 'x11-plugins/gkrellsun/files')
-rw-r--r--x11-plugins/gkrellsun/files/gkrellsun-1.0.0-r5-makefile-fixes.patch56
1 files changed, 56 insertions, 0 deletions
diff --git a/x11-plugins/gkrellsun/files/gkrellsun-1.0.0-r5-makefile-fixes.patch b/x11-plugins/gkrellsun/files/gkrellsun-1.0.0-r5-makefile-fixes.patch
new file mode 100644
index 000000000000..186933030860
--- /dev/null
+++ b/x11-plugins/gkrellsun/files/gkrellsun-1.0.0-r5-makefile-fixes.patch
@@ -0,0 +1,56 @@
+Don't call gcc directly, remove -O2 -Wall flags, respect user's pkg-config
+--- a/src20/Makefile
++++ b/src20/Makefile
+@@ -1,8 +1,8 @@
+ PACKAGE ?= gkrellsun
+
+-GTK_CONFIG ?=pkg-config gtk+-2.0
+-GTK_INCLUDE ?= `pkg-config gtk+-2.0 --cflags`
+-GTK_LIB ?= `pkg-config gtk+-2.0 --libs`
++PKG_CONFIG ?= pkg-config
++GTK_INCLUDE ?= $(shell ${PKG_CONFIG} gtk+-2.0 --cflags)
++GTK_LIB ?= $(shell ${PKG_CONFIG} gtk+-2.0 --libs)
+
+ INSTALL ?= install
+
+@@ -11,7 +11,7 @@ INSTALLDIR ?= $(DESTDIR)$(PREFIX)
+ PLUGINDIR ?= $(INSTALLDIR)/lib/gkrellm2/plugins
+ LOCALEDIR ?= $(INSTALLDIR)/share/locale
+
+-FLAGS = -O2 -Wall -fPIC $(GTK_INCLUDE)
++FLAGS = -fPIC $(GTK_INCLUDE)
+ #FLAGS = -g -Wall -fPIC $(GTK_INCLUDE)
+ LIBS = $(GTK_LIB)
+ LFLAGS = -shared
+@@ -25,7 +25,7 @@ endif
+ FLAGS += -DPACKAGE="\"$(PACKAGE)\""
+ export PACKAGE LOCALEDIR
+
+-CC = gcc $(CFLAGS) $(FLAGS)
++CC = $(CC)
+
+ OBJS = gkrellsun.o CalcEphem.o Moon.o MoonRise.o
+
+@@ -37,10 +37,10 @@ all: gkrellsun.so
+
+ gkrellsun.so: $(OBJS)
+ (cd po && ${MAKE})
+- $(CC) $(OBJS) -o gkrellsun.so $(LFLAGS) $(LIBS)
++ $(CC) $(CFLAGS) $(FLAGS) $(OBJS) -o gkrellsun.so $(LFLAGS) $(LIBS)
+
+ suninfo: suninfo.o CalcEphem.o Moon.o MoonRise.o
+- $(CC) $^ -o suninfo -lm $(LIBS)
++ $(CC) $(CFLAGS) $(FLAGS) $^ -o suninfo -lm $(LIBS)
+
+ clean:
+ rm -f *.o core *.so* *.bak *~
+@@ -49,7 +49,8 @@ gkrellsun.o: gkrellsun.c $(IMAGES)
+
+ $(OBJS): CalcEphem.h Moon.h MoonRise.h
+
+-#%.o: %.c
++%.o: %.c
++ $(CC) $(CFLAGS) $(FLAGS) -c -o $@ $<
+
+ install: gkrellsun.so
+ (cd po && ${MAKE} install )