source: freewrt/package/aiccu/patches/001-crosscompile.patch@ f724867

freewrt_1_0 freewrt_2_0
Last change on this file since f724867 was f724867, checked in by Waldemar Brodkorb <wbx@…>, 19 years ago

add portability patch, we always build for linux, do not use uname to figure out host/target system

git-svn-id: svn://www.freewrt.org/trunk/freewrt@158 afb5a338-a214-0410-bd46-81f09a774fd1

  • Property mode set to 100644
File size: 1.7 KB
  • unix-console/Makefile

    diff -Nur aiccu/unix-console/Makefile aiccu-freewrt/unix-console/Makefile
    old new  
    2222CFLAGS  += -D AICCU_CONSOLE
    2323
    2424# Linux
    25 ifeq ($(shell uname | grep -c "Linux"),1)
    2625CFLAGS  += -D AICCU_TYPE="\"linux\""
    2726CWARNS  += -Wpadded -Wpacked
    2827SRCS    += ../common/aiccu_linux.c
    2928OBJS    += ../common/aiccu_linux.o
    3029LDFLAGS = -lpthread
    31 endif
    3230
    33 # FreeBSD 4
    34 ifeq ($(shell uname | grep -c "FreeBSD"),1)
    35 # FreeBSD 4.x
    36 ifeq ($(shell uname -r | cut -c 1),4)
    37 CFLAGS  += -D AICCU_TYPE="\"freebsd4\""
    38 SRCS    += ../common/aiccu_freebsd4.c
    39 OBJS    += ../common/aiccu_freebsd4.o
    40 CFLAGS  += -pthread
    41 endif
    42 
    43 # FreeBSD 5.x
    44 ifeq ($(shell uname -r | cut -c 1),5)
    45 CFLAGS  += -D AICCU_TYPE="\"kame\""
    46 SRCS    += ../common/aiccu_kame.c
    47 OBJS    += ../common/aiccu_kame.o
    48 CFLAGS  += -pthread
    49 endif
    50 endif
    51 
    52 # NetBSD
    53 ifeq ($(shell uname | grep -c "NetBSD"),1)
    54 CFLAGS  += -D AICCU_TYPE="\"kame\""
    55 SRCS    += ../common/aiccu_kame.c
    56 OBJS    += ../common/aiccu_kame.o
    57 CFLAGS  += -pthread
    58 endif
    59 
    60 # OpenBSD
    61 ifeq ($(shell uname | grep -c "OpenBSD"),1)
    62 # 2.7-2.9
    63 ifeq ($(shell uname -r | cut -c 1),2)
    64 CFLAGS  += -D AICCU_TYPE="\"openbsd2\""
    65 SRCS   += ../common/aiccu_openbsd2.c
    66 OBJS   += ../common/aiccu_openbsd2.o
    67 endif
    68 # 3.x
    69 ifeq ($(shell uname -r | cut -c 1),3)
    70 CFLAGS  += -D AICCU_TYPE="\"openbsd\""
    71 SRCS   += ../common/aiccu_openbsd.c
    72 OBJS   += ../common/aiccu_openbsd.o
    73 endif
    74  CFLAGS += -pthread
    75 endif
    76 
    77 # Darwin
    78 ifeq ($(shell uname | grep -c "Darwin"),1)
    79 CFLAGS  += -D AICCU_TYPE="\"darwin\""
    80 SRCS    += ../common/aiccu_darwin.c
    81 OBJS    += ../common/aiccu_darwin.o
    82 CFLAGS  += -DDARWIN
    83 endif
    8431
    8532all: aiccu
    8633
Note: See TracBrowser for help on using the repository browser.