File: cross.patch

package info (click to toggle)
audtty 0.1.12-6
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 596 kB
  • sloc: ansic: 1,560; sh: 193; makefile: 57
file content (45 lines) | stat: -rw-r--r-- 1,427 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
Author: Helmut Grohne <helmut@subdivi.de>
Last-Update: 2020-02-21
Bug-Debian: https://bugs.debian.org/951751
Description: Use autotools properly

--- a/Makefile.in
+++ b/Makefile.in
@@ -7,9 +7,11 @@ mandir=${DESTDIR}/usr/share/man/man1
 sysconfdir=${DESTDIR}/@sysconfdir@
 
 
+CC=@CC@
 AUDACIOUS_CFLAGS=@AUDACIOUS_CFLAGS@ -I/usr/include/dbus-1.0
-GLIB_CFLAGS=`pkg-config --cflags glib-2.0`
-LDADD=-ldbus-glib-1 -lncursesw -laudclient -lgobject-2.0 `pkg-config --libs glib-2.0 `
+GLIB_CFLAGS=@GLIB_CFLAGS@
+GLIB_LIBS=@GLIB_LIBS@
+LDADD=-ldbus-glib-1 -lncursesw -laudclient -lgobject-2.0 $(GLIB_LIBS)
 
 SOURCES=main.c curses_printf.c playlist.c playlist_jump.c playlist_addurl.c settings.c connect.c browse.c playlist_create.c
 BINS=$(SOURCES:.c=.o)
@@ -19,10 +21,10 @@ build: audtty
 all: audtty
 
 audtty: ${BINS}
-	cc -g -O2 -g2 -Wall -Werror ${LDFLAGS} -o audtty $(BINS) $(LDADD)
+	$(CC) -g -O2 -g2 -Wall -Werror ${LDFLAGS} -o audtty $(BINS) $(LDADD)
 
 .c.o:
-	cc -g -Wall ${AUDACIOUS_CFLAGS} ${GLIB_CFLAGS} ${CFLAGS} -o $@ -c $<
+	$(CC) -g -Wall ${AUDACIOUS_CFLAGS} ${GLIB_CFLAGS} ${CFLAGS} -o $@ -c $<
 
 install: audtty
 	mkdir -p ${bindir}
--- a/configure.ac
+++ b/configure.ac
@@ -22,6 +22,8 @@ PKG_CHECK_MODULES(AUDACIOUS, [audclient
 	[],
 	[AC_MSG_ERROR([Can't find Audacious development files.])])
 
+PKG_CHECK_MODULES([GLIB],[glib-2.0])
+
 # Checks for header files.
 AC_HEADER_STDC
 AC_CHECK_HEADERS([stdlib.h])