/[baselayout]/trunk/src/Makefile
Gentoo

Diff of /trunk/src/Makefile

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 2802 Revision 2804
7 7
8check_gcc=$(shell if $(CC) $(1) -S -o /dev/null -xc /dev/null >/dev/null 2>&1; \ 8check_gcc=$(shell if $(CC) $(1) -S -o /dev/null -xc /dev/null >/dev/null 2>&1; \
9 then echo "$(1)"; else echo "$(2)"; fi) 9 then echo "$(1)"; else echo "$(2)"; fi)
10 10
11# Loads of nice flags to ensure our code is good 11# Loads of nice flags to ensure our code is good
12CFLAGS += -pedantic -std=c99 \ 12override CFLAGS += -pedantic -std=c99 \
13 -Wall -Wunused -Wimplicit -Wshadow -Wformat=2 \ 13 -Wall -Wunused -Wimplicit -Wshadow -Wformat=2 \
14 -Wmissing-declarations -Wno-missing-prototypes -Wwrite-strings \ 14 -Wmissing-declarations -Wno-missing-prototypes -Wwrite-strings \
15 -Wbad-function-cast -Wnested-externs -Wcomment -Winline \ 15 -Wbad-function-cast -Wnested-externs -Wcomment -Winline \
16 -Wchar-subscripts -Wcast-align -Wno-format-nonliteral \ 16 -Wchar-subscripts -Wcast-align -Wno-format-nonliteral \
17 $(call check_gcc, -Wdeclaration-after-statement) \ 17 $(call check_gcc, -Wdeclaration-after-statement) \
97override LDFLAGS += -Wl,-rpath . 97override LDFLAGS += -Wl,-rpath .
98endif 98endif
99 99
100all: $(TARGET) 100all: $(TARGET)
101 101
102$(LIBEINFOOBJS): CFLAGS += -fPIC 102$(LIBEINFOOBJS): override CFLAGS += -fPIC
103$(LIBEINFOSO): LDLIBS = 103$(LIBEINFOSO): LDLIBS =
104$(LIBEINFOSO): $(LIBEINFOOBJS) 104$(LIBEINFOSO): $(LIBEINFOOBJS)
105 $(CC) -fPIC -shared -Wl,-soname,$(LIBEINFOSO) -o $(LIBEINFOSO) $(LIBEINFOOBJS) 105 $(CC) -fPIC -shared -Wl,-soname,$(LIBEINFOSO) -o $(LIBEINFOSO) $(LIBEINFOOBJS)
106 ln -sf $(LIBEINFOSO) libeinfo.so 106 ln -sf $(LIBEINFOSO) libeinfo.so
107 107
108$(LIBRCOBJS): CFLAGS += -fPIC 108$(LIBRCOBJS): override CFLAGS += -fPIC
109$(LIBRCSO): $(LIBRCOBJS) 109$(LIBRCSO): $(LIBRCOBJS)
110 $(CC) -fPIC -shared -Wl,-soname,$(LIBRCSO) -o $(LIBRCSO) $(LDLIBS_LIBRC) $(LIBRCOBJS) 110 $(CC) -fPIC -shared -Wl,-soname,$(LIBRCSO) -o $(LIBRCSO) $(LDLIBS_LIBRC) $(LIBRCOBJS)
111 ln -sf $(LIBRCSO) librc.so 111 ln -sf $(LIBRCSO) librc.so
112 112
113rc: CPPFLAGS += $(CPPFLAGS_SSD) 113rc: override CPPFLAGS += $(CPPFLAGS_SSD)
114rc: LDLIBS += $(LDLIBS_RC) $(LDLIBS_RS) $(LDLIBS_SSD) 114rc: override LDLIBS += $(LDLIBS_RC) $(LDLIBS_RS) $(LDLIBS_SSD)
115rc: $(LIBEINFOSO) $(LIBRCSO) $(RCOBJS) rc.o 115rc: $(LIBEINFOSO) $(LIBRCSO) $(RCOBJS) rc.o
116 116
117links: rc 117links: rc
118 for x in $(BINLINKS) $(SBINLINKS) $(RCLINKS) $(RCPRIVLINKS); do ln -sf rc $$x; done 118 for x in $(BINLINKS) $(SBINLINKS) $(RCLINKS) $(RCPRIVLINKS); do ln -sf rc $$x; done
119 119

Legend:
Removed from v.2802  
changed lines
  Added in v.2804

  ViewVC Help
Powered by ViewVC 1.1.20