Lines 324-332
compile_unionfs_modules() {
Link Here
|
324 |
gen_die "Could not find unionfs source tarball: ${UNIONFS_SRCTAR}!" |
324 |
gen_die "Could not find unionfs source tarball: ${UNIONFS_SRCTAR}!" |
325 |
cd "${TEMP}" |
325 |
cd "${TEMP}" |
326 |
rm -rf ${UNIONFS_DIR} > /dev/null |
326 |
rm -rf ${UNIONFS_DIR} > /dev/null |
327 |
rm -rf unionfs > /dev/null |
327 |
rm -rf unionfs* > /dev/null |
328 |
mkdir -p unionfs |
328 |
mkdir unionfs |
329 |
/bin/tar -zxpf ${UNIONFS_SRCTAR} || |
329 |
/bin/tar xzpf ${UNIONFS_SRCTAR} || |
330 |
gen_die 'Could not extract unionfs source tarball!' |
330 |
gen_die 'Could not extract unionfs source tarball!' |
331 |
[ -d "${UNIONFS_DIR}" ] || |
331 |
[ -d "${UNIONFS_DIR}" ] || |
332 |
gen_die 'Unionfs directory ${UNIONFS_DIR} is invalid!' |
332 |
gen_die 'Unionfs directory ${UNIONFS_DIR} is invalid!' |
Lines 335-340
compile_unionfs_modules() {
Link Here
|
335 |
echo "LINUXSRC=${KERNEL_DIR}" >> fistdev.mk |
335 |
echo "LINUXSRC=${KERNEL_DIR}" >> fistdev.mk |
336 |
echo 'TOPINC=-I$(LINUXSRC)/include' >> fistdev.mk |
336 |
echo 'TOPINC=-I$(LINUXSRC)/include' >> fistdev.mk |
337 |
echo "MODDIR= /lib/modules/${KV}" >> fistdev.mk |
337 |
echo "MODDIR= /lib/modules/${KV}" >> fistdev.mk |
|
|
338 |
echo "KVERS=${KV}" >> fistdev.mk |
338 |
echo "KERNELVERSION=${KV}" >> fistdev.mk |
339 |
echo "KERNELVERSION=${KV}" >> fistdev.mk |
339 |
# Fix for hardened/selinux systems to have extened attributes |
340 |
# Fix for hardened/selinux systems to have extened attributes |
340 |
# per r2d2's request. Also add -DUNIONFS_UNSUPPORTED for 2.6.16 |
341 |
# per r2d2's request. Also add -DUNIONFS_UNSUPPORTED for 2.6.16 |
Lines 347-357
compile_unionfs_modules() {
Link Here
|
347 |
|
348 |
|
348 |
if [ "${PAT}" -ge '6' ] |
349 |
if [ "${PAT}" -ge '6' ] |
349 |
then |
350 |
then |
350 |
cd "${TEMP}" |
351 |
# ARCH is used by unionfs - and conflicts with genkernel |
351 |
cd "${UNIONFS_DIR}" |
352 |
ARCH_PUSH=${ARCH} |
|
|
353 |
unset ARCH |
352 |
# Compile unionfs module within the unionfs |
354 |
# Compile unionfs module within the unionfs |
353 |
# environment not within the kernelsrc dir |
355 |
# environment not within the kernelsrc dir |
354 |
make unionfs.ko || gen_die 'failed to compile unionfs' |
356 |
make unionfs.ko || gen_die 'failed to compile unionfs' |
|
|
357 |
ARCH=${ARCH_PUSH} |
355 |
else |
358 |
else |
356 |
gen_die 'unionfs is only supported on 2.6 targets' |
359 |
gen_die 'unionfs is only supported on 2.6 targets' |
357 |
fi |
360 |
fi |
Lines 383-389
compile_unionfs_utils() {
Link Here
|
383 |
gen_die "Could not find unionfs source tarball: ${UNIONFS_SRCTAR}!" |
386 |
gen_die "Could not find unionfs source tarball: ${UNIONFS_SRCTAR}!" |
384 |
cd "${TEMP}" |
387 |
cd "${TEMP}" |
385 |
rm -rf ${UNIONFS_DIR} > /dev/null |
388 |
rm -rf ${UNIONFS_DIR} > /dev/null |
386 |
rm -rf unionfs > /dev/null |
389 |
rm -rf unionfs* > /dev/null |
387 |
mkdir -p unionfs/sbin |
390 |
mkdir -p unionfs/sbin |
388 |
/bin/tar -zxpf ${UNIONFS_SRCTAR} || |
391 |
/bin/tar -zxpf ${UNIONFS_SRCTAR} || |
389 |
gen_die 'Could not extract unionfs source tarball!' |
392 |
gen_die 'Could not extract unionfs source tarball!' |
Lines 391-406
compile_unionfs_utils() {
Link Here
|
391 |
gen_die 'Unionfs directory ${UNIONFS_DIR} is invalid!' |
394 |
gen_die 'Unionfs directory ${UNIONFS_DIR} is invalid!' |
392 |
cd "${UNIONFS_DIR}" |
395 |
cd "${UNIONFS_DIR}" |
393 |
print_info 1 'unionfs tools: >> Compiling...' |
396 |
print_info 1 'unionfs tools: >> Compiling...' |
|
|
397 |
sed -i utils/Makefile -e 's|${CC} -o|${CC} -static -o|g' |
394 |
sed -i Makefile -e 's|${CC} -o|${CC} -static -o|g' |
398 |
sed -i Makefile -e 's|${CC} -o|${CC} -static -o|g' |
395 |
compile_generic utils utils |
399 |
compile_generic utils utils |
396 |
|
400 |
|
|
|
401 |
if [ ! -e "uniondbg" ]; then |
402 |
cd utils |
403 |
fi |
397 |
print_info 1 'unionfs: >> Copying to cache...' |
404 |
print_info 1 'unionfs: >> Copying to cache...' |
398 |
strip uniondbg unionctl |
405 |
strip uniondbg unionctl |
399 |
cp uniondbg ${TEMP}/unionfs/sbin/ || |
406 |
cp uniondbg ${TEMP}/unionfs/sbin/ || |
400 |
gen_die 'Could not copy the uniondbg binary to the tmp directory' |
407 |
gen_die 'Could not copy the uniondbg binary to the tmp directory' |
401 |
cp unionctl ${TEMP}/unionfs/sbin/ || |
408 |
cp unionctl ${TEMP}/unionfs/sbin/ || |
402 |
gen_die 'Could not copy the unionctl binary to the tmp directory' |
409 |
gen_die 'Could not copy the unionctl binary to the tmp directory' |
403 |
cd ${TEMP}/unionfs |
410 |
cd ${TEMP}/unionfs |
404 |
/bin/tar -cjf "${UNIONFS_BINCACHE}" . || |
411 |
/bin/tar -cjf "${UNIONFS_BINCACHE}" . || |
405 |
gen_die 'Could not create unionfs tools binary cache' |
412 |
gen_die 'Could not create unionfs tools binary cache' |
406 |
|
413 |
|