summaryrefslogtreecommitdiffstats
path: root/rules/e2fsprogs.make
blob: 0199f5072e8590309e423170de0e76ed536a82ed (plain)
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
# -*-makefile-*-
#
# Copyright (C) 2002-2008 by Pengutronix e.K., Hildesheim, Germany
#               2009 by Marc Kleine-Budde <mkl@pengutronix.de>
#
# See CREDITS for details about who has contributed to this project.
#
# For further information about the PTXdist project and license conditions
# see the README file.
#

#
# We provide this package
#
PACKAGES-$(PTXCONF_E2FSPROGS) += e2fsprogs

#
# Paths and names
#
E2FSPROGS_VERSION	:= 1.41.12
E2FSPROGS		:= e2fsprogs-$(E2FSPROGS_VERSION)
E2FSPROGS_SUFFIX	:= tar.gz
E2FSPROGS_URL		:= $(PTXCONF_SETUP_SFMIRROR)/e2fsprogs/$(E2FSPROGS).$(E2FSPROGS_SUFFIX)
E2FSPROGS_SOURCE	:= $(SRCDIR)/$(E2FSPROGS).$(E2FSPROGS_SUFFIX)
E2FSPROGS_DIR		:= $(BUILDDIR)/$(E2FSPROGS)

# ----------------------------------------------------------------------------
# Get
# ----------------------------------------------------------------------------

$(E2FSPROGS_SOURCE):
	@$(call targetinfo)
	@$(call get, E2FSPROGS)

# ----------------------------------------------------------------------------
# Prepare
# ----------------------------------------------------------------------------

E2FSPROGS_PATH	:= PATH=$(CROSS_PATH)
E2FSPROGS_ENV 	:= $(CROSS_ENV)

#
# autoconf
#
E2FSPROGS_AUTOCONF := \
	$(CROSS_AUTOCONF_USR) \
	--disable-symlink-install \
	--disable-symlink-build \
	--disable-verbose-makecmds \
	--enable-htree \
	--enable-elf-shlibs \
	--disable-bsd-shlibs \
	--disable-profile \
	--disable-checker \
	--disable-jbd-debug \
	--disable-blkid-debug \
	--disable-testio-debug \
	--disable-libuuid \
	--disable-libblkid \
	--disable-debugfs \
	--disable-e2initrd-helper \
	--disable-tls \
	--disable-nls \
	--disable-rpath \
	--without-diet-libc

ifdef PTXCONF_E2FSPROGS_COMPRESSION
E2FSPROGS_AUTOCONF += --enable-compression
else
E2FSPROGS_AUTOCONF += --disable-compression
endif

ifdef PTXCONF_E2FSPROGS_IMAGER
E2FSPROGS_AUTOCONF += --enable-imager
else
E2FSPROGS_AUTOCONF += --disable-imager
endif

ifdef PTXCONF_E2FSPROGS_RESIZER
E2FSPROGS_AUTOCONF += --enable-resizer
else
E2FSPROGS_AUTOCONF += --disable-resizer
endif

ifdef PTXCONF_E2FSPROGS_INSTALL_E2FSCK
E2FSPROGS_AUTOCONF += --enable-fsck
else
E2FSPROGS_AUTOCONF += --disable-fsck
endif

ifdef PTXCONF_E2FSPROGS_INSTALL_UUIDD
E2FSPROGS_AUTOCONF += --enable-uuidd
else
E2FSPROGS_AUTOCONF += --disable-uuidd
endif

E2FSPROGS_INSTALL_OPT := install install-libs

# ----------------------------------------------------------------------------
# Target-Install
# ----------------------------------------------------------------------------

$(STATEDIR)/e2fsprogs.targetinstall:
	@$(call targetinfo)

	@$(call install_init, e2fsprogs)
	@$(call install_fixup,e2fsprogs,PACKAGE,e2fsprogs)
	@$(call install_fixup,e2fsprogs,PRIORITY,optional)
	@$(call install_fixup,e2fsprogs,VERSION,$(E2FSPROGS_VERSION))
	@$(call install_fixup,e2fsprogs,SECTION,base)
	@$(call install_fixup,e2fsprogs,AUTHOR,"Robert Schwebel <r.schwebel@pengutronix.de>")
	@$(call install_fixup,e2fsprogs,DEPENDS,)
	@$(call install_fixup,e2fsprogs,DESCRIPTION,missing)

#	#
#	# libraries
#	#

ifdef PTXCONF_E2FSPROGS_LIBCOM_ERR
	@$(call install_copy, e2fsprogs, 0, 0, 0644, -, \
		/usr/lib/libcom_err.so.2.1)
	@$(call install_link, e2fsprogs, libcom_err.so.2.1, /usr/lib/libcom_err.so.2)
	@$(call install_link, e2fsprogs, libcom_err.so.2.1, /usr/lib/libcom_err.so)
endif

ifdef PTXCONF_E2FSPROGS_LIBE2P
	@$(call install_copy, e2fsprogs, 0, 0, 0644, -, \
		/usr/lib/libe2p.so.2.3)
	@$(call install_link, e2fsprogs, libe2p.so.2.3, /usr/lib/libe2p.so.2)
	@$(call install_link, e2fsprogs, libe2p.so.2.3, /usr/lib/libe2p.so)
endif

ifdef PTXCONF_E2FSPROGS_LIBEXT2FS
	@$(call install_copy, e2fsprogs, 0, 0, 0644, -, \
		/usr/lib/libext2fs.so.2.4)
	@$(call install_link, e2fsprogs, libext2fs.so.2.4, /usr/lib/libext2fs.so.2)
	@$(call install_link, e2fsprogs, libext2fs.so.2.4, /usr/lib/libext2fs.so)
endif

ifdef PTXCONF_E2FSPROGS_LIBSS
	@$(call install_copy, e2fsprogs, 0, 0, 0644, -, \
		/usr/lib/libss.so.2.0)
	@$(call install_link, e2fsprogs, libss.so.2.0, /usr/lib/libss.so.2)
	@$(call install_link, e2fsprogs, libss.so.2.0, /usr/lib/libss.so)
endif

#	#
#	# binaries in /usr/bin
#	#
ifdef PTXCONF_E2FSPROGS_INSTALL_CHATTR
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/bin/chattr)
endif
ifdef PTXCONF_E2FSPROGS_INSTALL_LSATTR
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/bin/lsattr)
endif


#	#
#	# binaries in /usr/sbin
#	#
ifdef PTXCONF_E2FSPROGS_INSTALL_BADBLOCKS
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/sbin/badblocks)
endif

ifdef PTXCONF_E2FSPROGS_INSTALL_DUMPE2FS
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/sbin/dumpe2fs)
endif


ifdef PTXCONF_E2FSPROGS_INSTALL_E2FSCK
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/sbin/e2fsck)
endif
ifdef PTXCONF_E2FSPROGS_INSTALL_FSCK_EXT2
	@$(call install_link, e2fsprogs, e2fsck, /usr/sbin/fsck.ext2)
endif
ifdef PTXCONF_E2FSPROGS_INSTALL_FSCK_EXT3
	@$(call install_link, e2fsprogs, e2fsck, /usr/sbin/fsck.ext3)
endif
ifdef PTXCONF_E2FSPROGS_INSTALL_FSCK_EXT4
	@$(call install_link, e2fsprogs, e2fsck, /usr/sbin/fsck.ext4)
endif
ifdef PTXCONF_E2FSPROGS_INSTALL_FSCK_EXT4DEV
	@$(call install_link, e2fsprogs, e2fsck, /usr/sbin/fsck.ext4dev)
endif


ifdef PTXCONF_E2FSPROGS_INSTALL_E2IMAGE
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/sbin/e2image)
endif

ifdef PTXCONF_E2FSPROGS_INSTALL_E2LABEL
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/sbin/e2label)
endif

ifdef PTXCONF_E2FSPROGS_INSTALL_E2UNDO
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/sbin/e2undo)
endif

ifdef PTXCONF_E2FSPROGS_INSTALL_FILEFRAG
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/sbin/filefrag)
endif

ifdef PTXCONF_E2FSPROGS_INSTALL_LOGSAVE
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/sbin/logsave)
endif


ifdef PTXCONF_E2FSPROGS_INSTALL_MKE2FS
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/sbin/mke2fs)
endif
ifdef PTXCONF_E2FSPROGS_INSTALL_MKFS_EXT2
	@$(call install_link, e2fsprogs, mke2fs, /usr/sbin/mkfs.ext2)
endif
ifdef PTXCONF_E2FSPROGS_INSTALL_MKFS_EXT3
	@$(call install_link, e2fsprogs, mke2fs, /usr/sbin/mkfs.ext3)
endif
ifdef PTXCONF_E2FSPROGS_INSTALL_MKFS_EXT4
	@$(call install_link, e2fsprogs, mke2fs, /usr/sbin/mkfs.ext4)
endif
ifdef PTXCONF_E2FSPROGS_INSTALL_MKFS_EXT4DEV
	@$(call install_link, e2fsprogs, mke2fs, /usr/sbin/mkfs.ext4dev)
endif


ifdef PTXCONF_E2FSPROGS_INSTALL_MKLOSTANDFOUND
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/sbin/mklost+found)
endif

ifdef PTXCONF_E2FSPROGS_INSTALL_RESIZE2FS
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/sbin/resize2fs)
endif

ifdef PTXCONF_E2FSPROGS_INSTALL_TUNE2FS
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/sbin/tune2fs)
endif

ifdef PTXCONF_E2FSPROGS_INSTALL_UUIDD
	@$(call install_copy, e2fsprogs, 0, 0, 0755, -, /usr/sbin/uuidd)
endif

	@$(call install_alternative, e2fsprogs, 0, 0, 0644, /etc/mke2fs.conf, n)

	@$(call install_finish,e2fsprogs)

	@$(call touch)

# vim: syntax=make