]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blame_incremental - lfs/glibc
Added ability to change syslog to async logging.
[people/pmueller/ipfire-2.x.git] / lfs / glibc
... / ...
CommitLineData
1###############################################################################
2# #
3# IPFire.org - A linux based firewall #
4# Copyright (C) 2007 Michael Tremer & Christian Schmidt #
5# #
6# This program is free software: you can redistribute it and/or modify #
7# it under the terms of the GNU General Public License as published by #
8# the Free Software Foundation, either version 3 of the License, or #
9# (at your option) any later version. #
10# #
11# This program is distributed in the hope that it will be useful, #
12# but WITHOUT ANY WARRANTY; without even the implied warranty of #
13# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
14# GNU General Public License for more details. #
15# #
16# You should have received a copy of the GNU General Public License #
17# along with this program. If not, see <http://www.gnu.org/licenses/>. #
18# #
19###############################################################################
20
21###############################################################################
22# Definitions
23###############################################################################
24
25include Config
26
27VER = 2.3.6
28
29THISAPP = glibc-$(VER)
30DL_FILE = $(THISAPP).tar.bz2
31DL_FROM = $(URL_IPFIRE)
32DIR_APP = $(DIR_SRC)/$(THISAPP)
33CFLAGS =
34CXXFLAGS =
35
36# Normal build or /tools build.
37#
38ifeq "$(ROOT)" ""
39 TARGET = $(DIR_INFO)/$(THISAPP)
40 EXTRA_CONFIG = --prefix=/usr \
41 --disable-profile --enable-add-ons \
42 --enable-kernel=2.6.0 --libexecdir=/usr/lib/glibc
43 EXTRA_MAKE =
44 EXTRA_INSTALL =
45else
46 TARGET = $(DIR_INFO)/$(THISAPP)-tools
47 EXTRA_CONFIG = --prefix=/tools \
48 --disable-profile --enable-add-ons \
49 --enable-kernel=2.6.0 --with-binutils=/tools/bin \
50 --without-gd --with-headers=/tools/include \
51 --without-selinux
52 EXTRA_MAKE =
53 EXTRA_INSTALL =
54endif
55
56###############################################################################
57# Top-level Rules
58###############################################################################
59
60objects = $(DL_FILE) \
61 glibc-libidn-$(VER).tar.bz2
62
63$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
64glibc-libidn-$(VER).tar.bz2 = $(DL_FROM)/glibc-libidn-$(VER).tar.bz2
65
66$(DL_FILE)_MD5 = bfdce99f82d6dbcb64b7f11c05d6bc96
67glibc-libidn-$(VER).tar.bz2_MD5 = 49dbe06ce830fc73874d6b38bdc5b4db
68
69install : $(TARGET)
70
71check : $(patsubst %,$(DIR_CHK)/%,$(objects))
72
73download :$(patsubst %,$(DIR_DL)/%,$(objects))
74
75md5 : $(subst %,%_MD5,$(objects))
76
77###############################################################################
78# Downloading, checking, md5sum
79###############################################################################
80
81$(patsubst %,$(DIR_CHK)/%,$(objects)) :
82 @$(CHECK)
83
84$(patsubst %,$(DIR_DL)/%,$(objects)) :
85 @$(LOAD)
86
87$(subst %,%_MD5,$(objects)) :
88 @$(MD5)
89
90###############################################################################
91# Installation Details
92###############################################################################
93
94$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
95 @$(PREBUILD)
96 @rm -rf $(DIR_APP) $(DIR_SRC)/glibc-build && cd $(DIR_SRC) && tar jxf $(DIR_DL)/$(DL_FILE)
97 @mkdir $(DIR_SRC)/glibc-build
98ifeq "$(ROOT)" ""
99 cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/$(THISAPP)-linux_types-1.patch
100 cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/$(THISAPP)-inotify-1.patch
101 # This locale causes a loop on bash login - exclude it
102 cd $(DIR_APP) && sed -i '/vi_VN.TCVN/d' localedata/SUPPORTED
103 cd $(DIR_APP) && sed -i 's|libs -o|libs -L/usr/lib -Wl,-dynamic-linker=/lib/ld-linux.so.2 -o|' \
104 scripts/test-installation.pl
105endif
106 cd $(DIR_SRC)/glibc-build && $(DIR_APP)/configure $(EXTRA_CONFIG)
107
108ifeq "$(ROOT)" ""
109 touch /etc/ld.so.conf
110 cd $(DIR_SRC)/glibc-build && make $(MAKETUNING) $(EXTRA_MAKE)
111 cd $(DIR_SRC)/glibc-build && make $(EXTRA_INSTALL) install
112 cp -v $(DIR_APP)/sysdeps/unix/sysv/linux/inotify.h /usr/include/sys
113else
114 -mkdir /tools/etc
115 touch /tools/etc/ld.so.conf
116 cd $(DIR_SRC)/glibc-build && make $(MAKETUNING) $(EXTRA_MAKE)
117 cd $(DIR_SRC)/glibc-build && make $(EXTRA_INSTALL) install
118endif
119
120 # Creating the locales
121ifeq "$(ROOT)" ""
122 mkdir -p /usr/lib/locale
123 cd $(DIR_SRC)/glibc-build && localedef -i en_US -f ISO-8859-1 en_US
124 cd $(DIR_SRC)/glibc-build && localedef -i en_US -f UTF-8 en_US.utf8
125 cp -f /usr/share/zoneinfo/GMT /etc/localtime
126endif
127 @rm -rf $(DIR_APP) $(DIR_SRC)/glibc-build
128 @$(POSTBUILD)