summaryrefslogtreecommitdiff
path: root/net/nakenchat/files/patch-configure
blob: f535a1d18f107c363bee0ea392d4bca9a23b9927 (plain) (blame)
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
--- ./configure.orig	2011-01-31 13:09:57.000000000 +0000
+++ ./configure	2014-02-27 22:09:07.000000000 +0000
@@ -2,11 +2,11 @@
 
 # Based on FFMPEG's configure (http://ffmpeg.sourceforge.net/)
 
-PREFIX=/usr/local
-CC=gcc
+PREFIX=${PREFIX:=/usr/local}
+CC=${CC:=gcc}
 COMPILER_PREFIX=
 FLAGS=""
-CFLAGS="-Wall"
+CFLAGS="${CFLAGS}"
 LDFLAGS=""
 LANGUAGE="english"
 CONFIG_USER_CHAN_LIST="-DUSER_LIST_CHAN"
@@ -151,7 +151,7 @@
   case "$option" in
   --help) show_help
   ;;
-  --cflags=*) CFLAGS="${CFLAGS} $optval"
+  --cflags=*) CFLAGS="$optval"
   ;;
   --compiler-prefix=*) COMPILER_PREFIX="$optval"
   ;;
@@ -218,12 +218,9 @@
 
 done
 
-if test_compiler "gcc"
+if ! test_compiler $CC
 then
   CC="gcc"
-elif test_compiler "cc"
-then
-  CC="cc"
 fi
 
 if test_lib "-lpthread"; then LDFLAGS="${LDFLAGS} -lpthread"; fi