Index: branches/iFabio/Makefile
===================================================================
--- branches/iFabio/Makefile (revision 150)
+++ branches/iFabio/Makefile (revision 151)
@@ -1,139 +0,0 @@
-export USE_APPLE_PB_SUPPORT = all
-
-# Makefile for kernel booter
-
-# CFLAGS = -O $(MORECPP) -arch i386 -g
-DEFINES=
-CONFIG = hd
-LIBDIR = libsa
-INC = -I. -I$(LIBDIR)
-ifneq "" "$(wildcard /bin/mkdirs)"
- MKDIRS = /bin/mkdirs
-else
- MKDIRS = /bin/mkdir -p
-endif
-AS = as
-LD = ld
-PAX = /bin/pax
-
-OBJROOT = `pwd`/obj
-SYMROOT = `pwd`/sym
-DSTROOT = `pwd`/dst
-SRCROOT = /tmp
-DOCROOT = `pwd`/doc
-IMGROOT = `pwd`/sym/cache
-IMGSKELROOT = `pwd`/imgskel
-CDBOOT = ${IMGROOT}/usr/standalone/i386/cdboot
-
-THEME = default
-
-VERSION = `cat version`
-REVISION = `cat revision`
-PRODUCT = Chameleon-$(VERSION)-r$(REVISION)
-CDLABEL = ${PRODUCT}
-ISOIMAGE = ${SYMROOT}/${CDLABEL}.iso
-
-EXCLUDE = --exclude=.svn --exclude=.DS_Store --exclude=sym --exclude=obj \
- --exclude=package --exclude=archive --exclude=User_Guide_src --exclude=*.sh
-
-ARCHLESS_RC_CFLAGS=`echo $(RC_CFLAGS) | sed 's/-arch [a-z0-9]*//g'`
-
-VPATH = $(OBJROOT):$(SYMROOT)
-
-GENERIC_SUBDIRS =
-
-#
-# Currently builds for i386
-#
-
-all embedtheme tags debug install installhdrs: $(SYMROOT) $(OBJROOT)
- @if [ -e ".svn" ]; then svnversion -n | tr -d [:alpha:] > revision; fi
- @if [ -z "$(RC_ARCHS)" ]; then \
- RC_ARCHS="i386"; \
- fi; \
- SUBDIRS="$(GENERIC_SUBDIRS) $$RC_ARCHS"; \
- for i in $$SUBDIRS; \
- do \
- if [ -d $$i ]; then \
- echo ================= make $@ for $$i =================; \
- ( OBJROOT=$(OBJROOT)/$${i}; \
- SYMROOT=$(SYMROOT)/$${i}; \
- DSTROOT=$(DSTROOT); \
- XCFLAGS=$(ARCHLESS_RC_CFLAGS); \
- GENSUBDIRS="$(GENERIC_SUBDIRS)"; \
- for x in $$GENSUBDIRS; \
- do \
- if [ "$$x" == "$$i" ]; then \
- XCFLAGS="$(RC_CFLAGS)"; \
- break; \
- fi \
- done; \
- echo "$$OBJROOT $$SYMROOT $$DSTROOT"; \
- cd $$i; ${MAKE} \
- "OBJROOT=$$OBJROOT" \
- "SYMROOT=$$SYMROOT" \
- "DSTROOT=$$DSTROOT" \
- "SRCROOT=$$SRCROOT" \
- "RC_ARCHS=$$RC_ARCHS" \
- "TARGET=$$i" \
- "RC_KANJI=$(RC_KANJI)" \
- "JAPANESE=$(JAPANESE)" \
- "RC_CFLAGS=$$XCFLAGS" $@ \
- ) || exit $$?; \
- else \
- echo "========= nothing to build for $$i ========="; \
- fi; \
- done
-
-image:
- @if [ -e "$(SYMROOT)" ]; then \
- rm -r -f ${IMGROOT}; \
- mkdir -p ${IMGROOT}/usr/standalone/i386; \
- if [ -e "$(IMGSKELROOT)" ]; then \
- cp -R -f "${IMGSKELROOT}"/* "${IMGROOT}"; \
- fi; \
- cp -f ${SYMROOT}/i386/cdboot ${CDBOOT}; \
- cp -f ${SYMROOT}/i386/boot ${IMGROOT}/usr/standalone/i386; \
- cp -f ${SYMROOT}/i386/boot0 ${IMGROOT}/usr/standalone/i386; \
- cp -f ${SYMROOT}/i386/boot1h ${IMGROOT}/usr/standalone/i386; \
- cp -f ${SYMROOT}/i386/boot1f32 ${IMGROOT}/usr/standalone/i386;\
- $(shell hdiutil makehybrid -iso -joliet -hfs -hfs-volume-name \
- ${CDLABEL} -eltorito-boot ${CDBOOT} -no-emul-boot -ov -o \
- "${ISOIMAGE}" ${IMGROOT} -quiet) \
- fi;
-
-pkg installer: embedtheme
- @if [ -e "$(SYMROOT)" ]; then \
- sudo `pwd`/package/buildpkg `pwd`/sym/package; \
- fi;
-
-advanced installer: embedtheme
- @if [ -e "$(SYMROOT)" ]; then \
- sudo `pwd`/package/advanced `pwd`/sym/package; \
- fi;
-
-basic installer: embedtheme
- @if [ -e "$(SYMROOT)" ]; then \
- sudo `pwd`/package/basic `pwd`/sym/package; \
- fi;
-
-release: $(SYMROOT)
- @if [ -e ".svn" ]; then svnversion -n | tr -d [:alpha:] > revision; fi
- @if [ -e "$(SYMROOT)" ]; then \
- sudo `pwd`/package/buildpkg `pwd`/sym/package; \
- fi;
- @tar -czf $(SYMROOT)/$(PRODUCT)-src.tar.gz ${EXCLUDE} .
- @tar -cjf $(SYMROOT)/$(PRODUCT)-src.tar.bz2 ${EXCLUDE} .
-
-clean:
- rm -rf sym obj dst
-
-#distclean: clean
-# @rm -f $(SYMROOT)/$(PRODUCT)-src.*
-# @rm -f $(SYMROOT)/$(PRODUCT).pkg
-
-installsrc:
- gnutar cf - . | (cd ${SRCROOT}; gnutar xpf -)
-
-$(SYMROOT) $(OBJROOT) $(DSTROOT):
- @$(MKDIRS) $@
Index: branches/iFabio/Test/buildpkg.txt
===================================================================
--- branches/iFabio/Test/buildpkg.txt (revision 0)
+++ branches/iFabio/Test/buildpkg.txt (revision 151)
@@ -0,0 +1,367 @@
+#!/bin/bash
+
+# $1 Path to store built package
+
+packagesidentity="org.chameleon"
+
+packagename="Chameleon"
+
+pkgroot="${0%/*}"
+
+#version=$( grep I386BOOT_CHAMELEONVERSION sym/i386/vers.h | awk '{ print $3 }' | tr -d '\"' )
+version=$( cat version )
+stage=${version##*-}
+revision=$( grep I386BOOT_CHAMELEONREVISION sym/i386/vers.h | awk '{ print $3 }' | tr -d '\"' )
+builddate=$( grep I386BOOT_BUILDDATE sym/i386/vers.h | awk '{ print $3,$4 }' | tr -d '\"' )
+timestamp=$( date -j -f "%Y-%m-%d %H:%M:%S" "${builddate}" "+%s" )
+
+distributioncount=0
+xmlindent=0
+
+indent[0]="\t"
+indent[1]="\t\t"
+indent[2]="\t\t\t"
+indent[3]="\t\t\t\t"
+
+main ()
+{
+
+# clean up the destination path
+
+ rm -R -f "${1}"
+
+ echo "Building $packagename Install Package v${version%%-*} $stage r$revision $builddate"
+
+ outline[$((outlinecount++))]="${indent[$xmlindent]}"
+
+# Start
+
+
+
+# build Chameleon metapackages
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+ choices[$((choicescount++))]="\n\n"
+ ((xmlindent++))
+
+ # build core package
+ mkdir -p ${1}/Core/Root/i386
+ cp -f ${1%/*}/i386/boot ${1}/Core/Root/i386
+ cp -f ${1%/*}/i386/boot0 ${1}/Core/Root/i386
+ cp -f ${1%/*}/i386/boot0hfs ${1}/Core/Root/i386
+ cp -f ${1%/*}/i386/boot1f32 ${1}/Core/Root/i386
+ cp -f ${1%/*}/i386/boot1h ${1}/Core/Root/i386
+ cp -f ${1%/*}/i386/boot1he ${1}/Core/Root/i386
+ cp -f ${1%/*}/i386/boot1hp ${1}/Core/Root/i386
+ cp -f ${1%/*}/i386/cdboot ${1}/Core/Root/i386
+ cp -f ${1%/*}/i386/chain0 ${1}/Core/Root/i386
+ cp -f ${pkgroot}/fdisk440 ${1}/Core/Root/i386
+ fixperms "${1}/Core/Root/i386"
+ local coresize=$( du -hkc "${1}/Core/Root/i386" | tail -n1 | awk {'print $1'} )
+ echo "Building core package"
+ buildpackage "${1}/Core" "/binaries" "0" "start_visible=\"false\" start_selected=\"true\""
+
+ # End build core package
+
+ # build standard package
+ mkdir -p ${1}/boot0/Root
+ mkdir -p ${1}/boot0/Scripts
+ cp -f ${pkgroot}/Scripts/boot0/postinstall ${1}/boot0/Scripts
+ echo "Building boot0 package"
+ buildpackage "${1}/boot0" "/binaries" "${coresize}" "start_enabled=\"true\" start_selected=\"false\" selected=\"exclusive(choices['EnhancedHFS']) && exclusive(choices['boot0hfs']) && exclusive(choices['EnhancedFAT']) && exclusive(choices['noboot'])\""
+ # End build standard package
+
+ # build standard package with boot0hfs
+ mkdir -p ${1}/boot0hfs/Root
+ mkdir -p ${1}/boot0hfs/Scripts
+ cp -f ${pkgroot}/Scripts/boot0hfs/postinstall ${1}/boot0hfs/Scripts
+ echo "Building boot0hfs package"
+ buildpackage "${1}/boot0hfs" "/binaries" "${coresize}" "start_enabled=\"true\" start_selected=\"false\" selected=\"exclusive(choices['EnhancedHFS']) && exclusive(choices['boot0']) && exclusive(choices['EnhancedFAT']) && exclusive(choices['noboot'])\""
+ # End build standard package with boot0hfs
+
+ # build efi fat32 package
+ mkdir -p ${1}/EnhancedFAT/Root
+ mkdir -p ${1}/EnhancedFAT/Scripts/Tools
+ cp -f ${pkgroot}/Scripts/FAT/postinstall ${1}/EnhancedFAT/Scripts
+ ditto --arch i386 `which SetFile` ${1}/EnhancedFAT/Scripts/Tools/SetFile
+ echo "Building EnhacedFAT package"
+ buildpackage "${1}/EnhancedFAT" "/binaries" "${coresize}" "start_visible=\"systemHasGPT()\" start_selected=\"false\" selected=\"exclusive(choices['boot0']) && exclusive(choices['boot0hfs']) && exclusive(choices['EnhancedHFS']) && exclusive(choices['noboot'])\""
+ # End build efi fat32 package
+
+ # build efi hfs package
+ mkdir -p ${1}/EnhancedHFS/Root
+ mkdir -p ${1}/EnhancedHFS/Scripts/Tools
+ cp -f ${pkgroot}/Scripts/HFS/postinstall ${1}/EnhancedHFS/Scripts
+ ditto --arch i386 `which SetFile` ${1}/EnhancedHFS/Scripts/Tools/SetFile
+ echo "Building EnhacedHFS package"
+ buildpackage "${1}/EnhancedHFS" "/binaries" "${coresize}" "start_visible=\"systemHasGPT()\" start_selected=\"false\" selected=\"exclusive(choices['boot0']) && exclusive(choices['boot0hfs']) && exclusive(choices['EnhancedFAT']) && exclusive(choices['noboot'])\""
+ # End build efi hfs package
+
+ # build reset choice package
+ mkdir -p ${1}/noboot/Root
+ echo "Building reset choice package"
+ buildpackage "${1}/noboot" "/binaries" "${coresize}" "start_visible=\"true\" start_selected=\"true\" selected=\"exclusive(choices['boot0']) && exclusive(choices['boot0hfs']) && exclusive(choices['EnhancedFAT']) && exclusive(choices['EnhancedHFS'])\""
+ # End build reset choice package
+
+ ((xmlindent--))
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+# End Chameleon metapakage
+
+# build utility package
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+ choices[$((choicescount++))]="\n\n"
+ ((xmlindent++))
+ packagesidentity="org.chameleon"
+
+ # build package for bdmesg
+ mkdir -p "${1}/bdmesg/Root"
+ ditto --noextattr --noqtn "${1%/*}/i386/bdmesg" "${1}/bdmesg/Root"
+ echo "Building bdmesg package"
+ buildpackage "${1}/bdmesg" "/Extra/Util" "" "start_selected=\"false\""
+ # End build package for bdmesg
+
+ # build package for Chameleon PrefPanel
+ mkdir -p "${1}/prefPane/Root/"
+ ditto --noextattr --noqtn "${pkgroot}/Configuration" "${1}/prefPane/Root"
+ echo "Building Chameleon Preference Panel package"
+ buildpackage "${1}/prefPane" "/Library/PreferencePanes" "" "start_selected=\"false\""
+ # End build package for Chameleon PrefPanel
+
+ ((xmlindent--))
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+# End utility package
+
+# build options packages
+
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+ choices[$((choicescount++))]="\n\n"
+ ((xmlindent++))
+ packagesidentity="org.chameleon.options"
+ options=($( find "${pkgroot}/Scripts/Options" -type d -depth 1 -not -name '.svn' ))
+ for (( i = 0 ; i < ${#options[@]} ; i++))
+ do
+ packagesidentity="org.chameleon.flags"
+ flagname=($( find "${options[$i]}" -type d -depth 1 -not -name '.svn' ))
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+ choices[$((choicescount++))]="\n\n"
+ ((xmlindent++))
+ for (( j = 0 ; j < ${#flagname[@]} ; j++ ))
+ do
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+ choices[$((choicescount++))]="\n\n"
+ ((xmlindent++))
+ mkdir -p "${1}/${flagname[$j]##*/}/Root"
+ mkdir -p "${1}/${flagname[$j]##*/}/Scripts"
+ ditto --noextattr --noqtn "${options[$i]}/${flagname[$j]##*/}/postinstall" "${1}/${options[$i]##*/}${flagname[$j]##*/}/Scripts/postinstall"
+ # cp -f "${options[$i]}/${flagname[$j]##*/}/*" "${1}/${options[$i]##*/}${flagname[$j]##*/}/Scripts/postinstall"
+ # echo "Building ${options[$i]##*/}${flagname[$j]##*/} package"
+ buildpackage "${1}/${options[$i]##*/}_${flagname[$j]##*/}" "/" "${coresize}" "start_selected=\"false\""
+ rm -R -f "${1}/${j##*/}"
+ ((xmlindent--))
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+ done
+ ((xmlindent--))
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+ echo "Building ${options[$i]##*/} package"
+ buildpackage "${1}/${options[$i]##*/}" "/" "${coresize}" "start_selected=\"false\""
+ rm -R -f "${1}/${i##*/}"
+ done
+ ((xmlindent--))
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+# End build options packages
+
+# build theme packages
+
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+ choices[$((choicescount++))]="\n\n"
+ ((xmlindent++))
+ packagesidentity="org.chameleon.theme"
+ artwork="${1%/*}"
+ themes=($( find "${artwork%/*}/artwork/themes" -type d -depth 1 -not -name '.svn' ))
+ for (( i = 0 ; i < ${#themes[@]} ; i++ ))
+ do
+ theme=$( echo ${themes[$i]##*/} | awk 'BEGIN{OFS=FS=""}{$1=toupper($1);print}' )
+ mkdir -p "${1}/${theme}/Root/"
+ ditto --noextattr --noqtn "${themes[$i]}" "${1}/${themes[$i]##*/}/Root/${theme}"
+ find "${1}/${themes[$i]##*/}" -name '.DS_Store' -or -name '.svn' -exec rm -R {} \+
+ find "${1}/${themes[$i]##*/}" -type f -exec chmod 644 {} \+
+ buildpackage "${1}/${theme}" "/Extra/Themes" "" "start_selected=\"false\""
+ rm -R -f "${1}/${i##*/}"
+ done
+ ((xmlindent--))
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+# End build theme packages
+
+
+
+# build kext packages
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+ choices[$((choicescount++))]="\n\n"
+ ((xmlindent++))
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+ choices[$((choicescount++))]="\n\n"
+ ((xmlindent++))
+ packagesidentity="org.chameleon"
+ kexts=($( find "${pkgroot}/Kexts" -type d -name '*.kext' -depth 1 ))
+ for (( i = 0 ; i < ${#kexts[@]} ; i++ ))
+ do
+ filename="${kexts[$i]##*/}"
+ mkdir -p "${1}/${filename%.kext}/Root/"
+ ditto --noextattr --noqtn --arch i386 "${kexts[$i]}" "${1}/${filename%.kext}/Root/${filename}"
+ find "${1}/${filename%.kext}" -name '.DS_Store' -or -name '.svn' -exec rm -R -f {} \; 2>/dev/null
+ fixperms "${1}/${filename%.kext}/Root/"
+ chown 501:20 "${1}/${filename%.kext}/Root/"
+ buildpackage "${1}/${filename%.kext}" "/Extra/Extensions" "" "start_selected=\"false\""
+ rm -R -f "${1}/${filename%.kext}"
+ done
+ ((xmlindent--))
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+ ((xmlindent--))
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+# End build kext packages
+
+# build post install package
+ mkdir -p ${1}/Post/Root
+ mkdir -p ${1}/Post/Scripts
+ cp -f ${pkgroot}/Scripts/Post/* ${1}/Post/Scripts
+ buildpackage "${1}/Post" "/binaries" "" "start_visible=\"false\" start_selected=\"true\""
+# End post install package
+
+ outline[$((outlinecount++))]="${indent[$xmlindent]}"
+# End main package
+
+
+# build meta package
+
+ makedistribution "${1}" "${2}" "${3}" "${4}" "${5}"
+
+# clean up
+
+ rm -R -f "${1}"
+
+}
+
+fixperms ()
+{
+ # $1 path
+ find "${1}" -type f -exec chmod 644 {} \;
+ find "${1}" -type d -exec chmod 755 {} \;
+ chown -R 0:0 "${1}"
+}
+
+buildpackage ()
+{
+# $1 Path to package to build containing Root and or Scripts
+# $2 Install Location
+# $3 Size
+# $4 Options
+
+if [ -d "${1}/Root" ] && [ "${1}/Scripts" ]; then
+
+ local packagename="${1##*/}"
+ local identifier=$( echo ${packagesidentity}.${packagename//_/.} | tr [:upper:] [:lower:] )
+ find "${1}" -name '.DS_Store' -delete
+ local filecount=$( find "${1}/Root" | wc -l )
+ if [ "${3}" ]; then
+ local installedsize="${3}"
+ else
+ local installedsize=$( du -hkc "${1}/Root" | tail -n1 | awk {'print $1'} )
+ fi
+ local header="\n\n"
+ header+="\t\n"
+ rm -R -f "${1}/Temp"
+
+ [ -d "${1}/Temp" ] || mkdir -m 777 "${1}/Temp"
+ [ -d "${1}/Root" ] && mkbom "${1}/Root" "${1}/Temp/Bom"
+
+ if [ -d "${1}/Scripts" ]; then
+ header+="\t\n"
+ for script in $( find "${1}/Scripts" -type f \( -name 'pre*' -or -name 'post*' \) )
+ do
+ header+="\t\t<${script##*/} file=\"./${script##*/}\"/>\n"
+ done
+ header+="\t\n"
+ chown -R 0:0 "${1}/Scripts"
+ pushd "${1}/Scripts" >/dev/null
+ find . -print | cpio -o -z -H cpio > "../Temp/Scripts"
+ popd >/dev/null
+ fi
+
+ header+=""
+ echo -e "${header}" > "${1}/Temp/PackageInfo"
+ pushd "${1}/Root" >/dev/null
+ find . -print | cpio -o -z -H cpio > "../Temp/Payload"
+ popd >/dev/null
+ pushd "${1}/Temp" >/dev/null
+
+ xar -c -f "${1%/*}/${packagename// /}.pkg" --compression none .
+
+ popd >/dev/null
+
+ outline[$((outlinecount++))]="${indent[$xmlindent]}\t"
+
+ if [ "${4}" ]; then
+ local choiceoptions="${indent[$xmlindent]}${4}\n"
+ fi
+ choices[$((choicescount++))]="\n\t#${packagename// /}.pkg\n\n"
+
+ rm -R -f "${1}"
+fi
+}
+
+makedistribution ()
+{
+ rm -f "${1%/*}/${packagename// /}"*.pkg
+
+ find "${1}" -type f -name '*.pkg' -depth 1 | while read component
+ do
+ mkdir -p "${1}/${packagename}/${component##*/}"
+ pushd "${1}/${packagename}/${component##*/}" >/dev/null
+ xar -x -f "${1%}/${component##*/}"
+ popd >/dev/null
+ done
+
+ ditto --noextattr --noqtn "${pkgroot}/Distribution" "${1}/${packagename}/Distribution"
+ ditto --noextattr --noqtn "${pkgroot}/Resources" "${1}/${packagename}/Resources"
+
+ find "${1}/${packagename}/Resources" -type d -name '.svn' -exec rm -R -f {} \; 2>/dev/null
+
+ for (( i=0; i < ${#outline[*]} ; i++));
+ do
+ echo -e "${outline[$i]}" >> "${1}/${packagename}/Distribution"
+ done
+
+ for (( i=0; i < ${#choices[*]} ; i++));
+ do
+ echo -e "${choices[$i]}" >> "${1}/${packagename}/Distribution"
+ done
+
+ echo "" >> "${1}/${packagename}/Distribution"
+
+ perl -i -p -e "s/%CHAMELEONVERSION%/${version%%-*}/g" `find "${1}/${packagename}/Resources" -type f`
+ perl -i -p -e "s/%CHAMELEONREVISION%/${revision}/g" `find "${1}/${packagename}/Resources" -type f`
+
+ stage=${stage/RC/Release Candidate }
+ stage=${stage/FINAL/2.0 Final}
+ perl -i -p -e "s/%CHAMELEONSTAGE%/${stage}/g" `find "${1}/${packagename}/Resources" -type f`
+
+ find "${1}/${packagename}" -name '.DS_Store' -delete
+ pushd "${1}/${packagename}" >/dev/null
+ xar -c -f "${1%/*}/${packagename// /}-${version}-r${revision}.pkg" --compression none .
+ popd >/dev/null
+
+ md5=$( md5 "${1%/*}/${packagename// /}-${version}-r${revision}.pkg" | awk {'print $4'} )
+ echo "MD5 (${packagename// /}-${version}-r${revision}.pkg) = ${md5}" > "${1%/*}/${packagename// /}-${version}-r${revision}.pkg.md5"
+ cp -R -f "${1}/${packagename}/Resources" ${1%/*}/Resources
+}
+
+main "${1}" "${2}" "${3}" "${4}" "${5}"
+
Property changes on: branches/iFabio/Test/buildpkg.txt
___________________________________________________________________
Added: svn:executable
+ *
Index: branches/iFabio/Test/APPLE_LICENSE
===================================================================
--- branches/iFabio/Test/APPLE_LICENSE (revision 0)
+++ branches/iFabio/Test/APPLE_LICENSE (revision 151)
@@ -0,0 +1,367 @@
+APPLE PUBLIC SOURCE LICENSE
+Version 2.0 - August 6, 2003
+
+Please read this License carefully before downloading this software.
+By downloading or using this software, you are agreeing to be bound by
+the terms of this License. If you do not or cannot agree to the terms
+of this License, please do not download or use the software.
+
+1. General; Definitions. This License applies to any program or other
+work which Apple Computer, Inc. ("Apple") makes publicly available and
+which contains a notice placed by Apple identifying such program or
+work as "Original Code" and stating that it is subject to the terms of
+this Apple Public Source License version 2.0 ("License"). As used in
+this License:
+
+1.1 "Applicable Patent Rights" mean: (a) in the case where Apple is
+the grantor of rights, (i) claims of patents that are now or hereafter
+acquired, owned by or assigned to Apple and (ii) that cover subject
+matter contained in the Original Code, but only to the extent
+necessary to use, reproduce and/or distribute the Original Code
+without infringement; and (b) in the case where You are the grantor of
+rights, (i) claims of patents that are now or hereafter acquired,
+owned by or assigned to You and (ii) that cover subject matter in Your
+Modifications, taken alone or in combination with Original Code.
+
+1.2 "Contributor" means any person or entity that creates or
+contributes to the creation of Modifications.
+
+1.3 "Covered Code" means the Original Code, Modifications, the
+combination of Original Code and any Modifications, and/or any
+respective portions thereof.
+
+1.4 "Externally Deploy" means: (a) to sublicense, distribute or
+otherwise make Covered Code available, directly or indirectly, to
+anyone other than You; and/or (b) to use Covered Code, alone or as
+part of a Larger Work, in any way to provide a service, including but
+not limited to delivery of content, through electronic communication
+with a client other than You.
+
+1.5 "Larger Work" means a work which combines Covered Code or portions
+thereof with code not governed by the terms of this License.
+
+1.6 "Modifications" mean any addition to, deletion from, and/or change
+to, the substance and/or structure of the Original Code, any previous
+Modifications, the combination of Original Code and any previous
+Modifications, and/or any respective portions thereof. When code is
+released as a series of files, a Modification is: (a) any addition to
+or deletion from the contents of a file containing Covered Code;
+and/or (b) any new file or other representation of computer program
+statements that contains any part of Covered Code.
+
+1.7 "Original Code" means (a) the Source Code of a program or other
+work as originally made available by Apple under this License,
+including the Source Code of any updates or upgrades to such programs
+or works made available by Apple under this License, and that has been
+expressly identified by Apple as such in the header file(s) of such
+work; and (b) the object code compiled from such Source Code and
+originally made available by Apple under this License.
+
+1.8 "Source Code" means the human readable form of a program or other
+work that is suitable for making modifications to it, including all
+modules it contains, plus any associated interface definition files,
+scripts used to control compilation and installation of an executable
+(object code).
+
+1.9 "You" or "Your" means an individual or a legal entity exercising
+rights under this License. For legal entities, "You" or "Your"
+includes any entity which controls, is controlled by, or is under
+common control with, You, where "control" means (a) the power, direct
+or indirect, to cause the direction or management of such entity,
+whether by contract or otherwise, or (b) ownership of fifty percent
+(50%) or more of the outstanding shares or beneficial ownership of
+such entity.
+
+2. Permitted Uses; Conditions & Restrictions. Subject to the terms
+and conditions of this License, Apple hereby grants You, effective on
+the date You accept this License and download the Original Code, a
+world-wide, royalty-free, non-exclusive license, to the extent of
+Apple's Applicable Patent Rights and copyrights covering the Original
+Code, to do the following:
+
+2.1 Unmodified Code. You may use, reproduce, display, perform,
+internally distribute within Your organization, and Externally Deploy
+verbatim, unmodified copies of the Original Code, for commercial or
+non-commercial purposes, provided that in each instance:
+
+(a) You must retain and reproduce in all copies of Original Code the
+copyright and other proprietary notices and disclaimers of Apple as
+they appear in the Original Code, and keep intact all notices in the
+Original Code that refer to this License; and
+
+(b) You must include a copy of this License with every copy of Source
+Code of Covered Code and documentation You distribute or Externally
+Deploy, and You may not offer or impose any terms on such Source Code
+that alter or restrict this License or the recipients' rights
+hereunder, except as permitted under Section 6.
+
+2.2 Modified Code. You may modify Covered Code and use, reproduce,
+display, perform, internally distribute within Your organization, and
+Externally Deploy Your Modifications and Covered Code, for commercial
+or non-commercial purposes, provided that in each instance You also
+meet all of these conditions:
+
+(a) You must satisfy all the conditions of Section 2.1 with respect to
+the Source Code of the Covered Code;
+
+(b) You must duplicate, to the extent it does not already exist, the
+notice in Exhibit A in each file of the Source Code of all Your
+Modifications, and cause the modified files to carry prominent notices
+stating that You changed the files and the date of any change; and
+
+(c) If You Externally Deploy Your Modifications, You must make
+Source Code of all Your Externally Deployed Modifications either
+available to those to whom You have Externally Deployed Your
+Modifications, or publicly available. Source Code of Your Externally
+Deployed Modifications must be released under the terms set forth in
+this License, including the license grants set forth in Section 3
+below, for as long as you Externally Deploy the Covered Code or twelve
+(12) months from the date of initial External Deployment, whichever is
+longer. You should preferably distribute the Source Code of Your
+Externally Deployed Modifications electronically (e.g. download from a
+web site).
+
+2.3 Distribution of Executable Versions. In addition, if You
+Externally Deploy Covered Code (Original Code and/or Modifications) in
+object code, executable form only, You must include a prominent
+notice, in the code itself as well as in related documentation,
+stating that Source Code of the Covered Code is available under the
+terms of this License with information on how and where to obtain such
+Source Code.
+
+2.4 Third Party Rights. You expressly acknowledge and agree that
+although Apple and each Contributor grants the licenses to their
+respective portions of the Covered Code set forth herein, no
+assurances are provided by Apple or any Contributor that the Covered
+Code does not infringe the patent or other intellectual property
+rights of any other entity. Apple and each Contributor disclaim any
+liability to You for claims brought by any other entity based on
+infringement of intellectual property rights or otherwise. As a
+condition to exercising the rights and licenses granted hereunder, You
+hereby assume sole responsibility to secure any other intellectual
+property rights needed, if any. For example, if a third party patent
+license is required to allow You to distribute the Covered Code, it is
+Your responsibility to acquire that license before distributing the
+Covered Code.
+
+3. Your Grants. In consideration of, and as a condition to, the
+licenses granted to You under this License, You hereby grant to any
+person or entity receiving or distributing Covered Code under this
+License a non-exclusive, royalty-free, perpetual, irrevocable license,
+under Your Applicable Patent Rights and other intellectual property
+rights (other than patent) owned or controlled by You, to use,
+reproduce, display, perform, modify, sublicense, distribute and
+Externally Deploy Your Modifications of the same scope and extent as
+Apple's licenses under Sections 2.1 and 2.2 above.
+
+4. Larger Works. You may create a Larger Work by combining Covered
+Code with other code not governed by the terms of this License and
+distribute the Larger Work as a single product. In each such instance,
+You must make sure the requirements of this License are fulfilled for
+the Covered Code or any portion thereof.
+
+5. Limitations on Patent License. Except as expressly stated in
+Section 2, no other patent rights, express or implied, are granted by
+Apple herein. Modifications and/or Larger Works may require additional
+patent licenses from Apple which Apple may grant in its sole
+discretion.
+
+6. Additional Terms. You may choose to offer, and to charge a fee for,
+warranty, support, indemnity or liability obligations and/or other
+rights consistent with the scope of the license granted herein
+("Additional Terms") to one or more recipients of Covered Code.
+However, You may do so only on Your own behalf and as Your sole
+responsibility, and not on behalf of Apple or any Contributor. You
+must obtain the recipient's agreement that any such Additional Terms
+are offered by You alone, and You hereby agree to indemnify, defend
+and hold Apple and every Contributor harmless for any liability
+incurred by or claims asserted against Apple or such Contributor by
+reason of any such Additional Terms.
+
+7. Versions of the License. Apple may publish revised and/or new
+versions of this License from time to time. Each version will be given
+a distinguishing version number. Once Original Code has been published
+under a particular version of this License, You may continue to use it
+under the terms of that version. You may also choose to use such
+Original Code under the terms of any subsequent version of this
+License published by Apple. No one other than Apple has the right to
+modify the terms applicable to Covered Code created under this
+License.
+
+8. NO WARRANTY OR SUPPORT. The Covered Code may contain in whole or in
+part pre-release, untested, or not fully tested works. The Covered
+Code may contain errors that could cause failures or loss of data, and
+may be incomplete or contain inaccuracies. You expressly acknowledge
+and agree that use of the Covered Code, or any portion thereof, is at
+Your sole and entire risk. THE COVERED CODE IS PROVIDED "AS IS" AND
+WITHOUT WARRANTY, UPGRADES OR SUPPORT OF ANY KIND AND APPLE AND
+APPLE'S LICENSOR(S) (COLLECTIVELY REFERRED TO AS "APPLE" FOR THE
+PURPOSES OF SECTIONS 8 AND 9) AND ALL CONTRIBUTORS EXPRESSLY DISCLAIM
+ALL WARRANTIES AND/OR CONDITIONS, EXPRESS OR IMPLIED, INCLUDING, BUT
+NOT LIMITED TO, THE IMPLIED WARRANTIES AND/OR CONDITIONS OF
+MERCHANTABILITY, OF SATISFACTORY QUALITY, OF FITNESS FOR A PARTICULAR
+PURPOSE, OF ACCURACY, OF QUIET ENJOYMENT, AND NONINFRINGEMENT OF THIRD
+PARTY RIGHTS. APPLE AND EACH CONTRIBUTOR DOES NOT WARRANT AGAINST
+INTERFERENCE WITH YOUR ENJOYMENT OF THE COVERED CODE, THAT THE
+FUNCTIONS CONTAINED IN THE COVERED CODE WILL MEET YOUR REQUIREMENTS,
+THAT THE OPERATION OF THE COVERED CODE WILL BE UNINTERRUPTED OR
+ERROR-FREE, OR THAT DEFECTS IN THE COVERED CODE WILL BE CORRECTED. NO
+ORAL OR WRITTEN INFORMATION OR ADVICE GIVEN BY APPLE, AN APPLE
+AUTHORIZED REPRESENTATIVE OR ANY CONTRIBUTOR SHALL CREATE A WARRANTY.
+You acknowledge that the Covered Code is not intended for use in the
+operation of nuclear facilities, aircraft navigation, communication
+systems, or air traffic control machines in which case the failure of
+the Covered Code could lead to death, personal injury, or severe
+physical or environmental damage.
+
+9. LIMITATION OF LIABILITY. TO THE EXTENT NOT PROHIBITED BY LAW, IN NO
+EVENT SHALL APPLE OR ANY CONTRIBUTOR BE LIABLE FOR ANY INCIDENTAL,
+SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES ARISING OUT OF OR RELATING
+TO THIS LICENSE OR YOUR USE OR INABILITY TO USE THE COVERED CODE, OR
+ANY PORTION THEREOF, WHETHER UNDER A THEORY OF CONTRACT, WARRANTY,
+TORT (INCLUDING NEGLIGENCE), PRODUCTS LIABILITY OR OTHERWISE, EVEN IF
+APPLE OR SUCH CONTRIBUTOR HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
+DAMAGES AND NOTWITHSTANDING THE FAILURE OF ESSENTIAL PURPOSE OF ANY
+REMEDY. SOME JURISDICTIONS DO NOT ALLOW THE LIMITATION OF LIABILITY OF
+INCIDENTAL OR CONSEQUENTIAL DAMAGES, SO THIS LIMITATION MAY NOT APPLY
+TO YOU. In no event shall Apple's total liability to You for all
+damages (other than as may be required by applicable law) under this
+License exceed the amount of fifty dollars ($50.00).
+
+10. Trademarks. This License does not grant any rights to use the
+trademarks or trade names "Apple", "Apple Computer", "Mac", "Mac OS",
+"QuickTime", "QuickTime Streaming Server" or any other trademarks,
+service marks, logos or trade names belonging to Apple (collectively
+"Apple Marks") or to any trademark, service mark, logo or trade name
+belonging to any Contributor. You agree not to use any Apple Marks in
+or as part of the name of products derived from the Original Code or
+to endorse or promote products derived from the Original Code other
+than as expressly permitted by and in strict compliance at all times
+with Apple's third party trademark usage guidelines which are posted
+at http://www.apple.com/legal/guidelinesfor3rdparties.html.
+
+11. Ownership. Subject to the licenses granted under this License,
+each Contributor retains all rights, title and interest in and to any
+Modifications made by such Contributor. Apple retains all rights,
+title and interest in and to the Original Code and any Modifications
+made by or on behalf of Apple ("Apple Modifications"), and such Apple
+Modifications will not be automatically subject to this License. Apple
+may, at its sole discretion, choose to license such Apple
+Modifications under this License, or on different terms from those
+contained in this License or may choose not to license them at all.
+
+12. Termination.
+
+12.1 Termination. This License and the rights granted hereunder will
+terminate:
+
+(a) automatically without notice from Apple if You fail to comply with
+any term(s) of this License and fail to cure such breach within 30
+days of becoming aware of such breach;
+
+(b) immediately in the event of the circumstances described in Section
+13.5(b); or
+
+(c) automatically without notice from Apple if You, at any time during
+the term of this License, commence an action for patent infringement
+against Apple; provided that Apple did not first commence
+an action for patent infringement against You in that instance.
+
+12.2 Effect of Termination. Upon termination, You agree to immediately
+stop any further use, reproduction, modification, sublicensing and
+distribution of the Covered Code. All sublicenses to the Covered Code
+which have been properly granted prior to termination shall survive
+any termination of this License. Provisions which, by their nature,
+should remain in effect beyond the termination of this License shall
+survive, including but not limited to Sections 3, 5, 8, 9, 10, 11,
+12.2 and 13. No party will be liable to any other for compensation,
+indemnity or damages of any sort solely as a result of terminating
+this License in accordance with its terms, and termination of this
+License will be without prejudice to any other right or remedy of
+any party.
+
+13. Miscellaneous.
+
+13.1 Government End Users. The Covered Code is a "commercial item" as
+defined in FAR 2.101. Government software and technical data rights in
+the Covered Code include only those rights customarily provided to the
+public as defined in this License. This customary commercial license
+in technical data and software is provided in accordance with FAR
+12.211 (Technical Data) and 12.212 (Computer Software) and, for
+Department of Defense purchases, DFAR 252.227-7015 (Technical Data --
+Commercial Items) and 227.7202-3 (Rights in Commercial Computer
+Software or Computer Software Documentation). Accordingly, all U.S.
+Government End Users acquire Covered Code with only those rights set
+forth herein.
+
+13.2 Relationship of Parties. This License will not be construed as
+creating an agency, partnership, joint venture or any other form of
+legal association between or among You, Apple or any Contributor, and
+You will not represent to the contrary, whether expressly, by
+implication, appearance or otherwise.
+
+13.3 Independent Development. Nothing in this License will impair
+Apple's right to acquire, license, develop, have others develop for
+it, market and/or distribute technology or products that perform the
+same or similar functions as, or otherwise compete with,
+Modifications, Larger Works, technology or products that You may
+develop, produce, market or distribute.
+
+13.4 Waiver; Construction. Failure by Apple or any Contributor to
+enforce any provision of this License will not be deemed a waiver of
+future enforcement of that or any other provision. Any law or
+regulation which provides that the language of a contract shall be
+construed against the drafter will not apply to this License.
+
+13.5 Severability. (a) If for any reason a court of competent
+jurisdiction finds any provision of this License, or portion thereof,
+to be unenforceable, that provision of the License will be enforced to
+the maximum extent permissible so as to effect the economic benefits
+and intent of the parties, and the remainder of this License will
+continue in full force and effect. (b) Notwithstanding the foregoing,
+if applicable law prohibits or restricts You from fully and/or
+specifically complying with Sections 2 and/or 3 or prevents the
+enforceability of either of those Sections, this License will
+immediately terminate and You must immediately discontinue any use of
+the Covered Code and destroy all copies of it that are in your
+possession or control.
+
+13.6 Dispute Resolution. Any litigation or other dispute resolution
+between You and Apple relating to this License shall take place in the
+Northern District of California, and You and Apple hereby consent to
+the personal jurisdiction of, and venue in, the state and federal
+courts within that District with respect to this License. The
+application of the United Nations Convention on Contracts for the
+International Sale of Goods is expressly excluded.
+
+13.7 Entire Agreement; Governing Law. This License constitutes the
+entire agreement between the parties with respect to the subject
+matter hereof. This License shall be governed by the laws of the
+United States and the State of California, except that body of
+California law concerning conflicts of law.
+
+Where You are located in the province of Quebec, Canada, the following
+clause applies: The parties hereby confirm that they have requested
+that this License and all related documents be drafted in English. Les
+parties ont exige que le present contrat et tous les documents
+connexes soient rediges en anglais.
+
+EXHIBIT A.
+
+"Portions Copyright (c) 1999-2003 Apple Computer, Inc. All Rights
+Reserved.
+
+This file contains Original Code and/or Modifications of Original Code
+as defined in and that are subject to the Apple Public Source License
+Version 2.0 (the 'License'). You may not use this file except in
+compliance with the License. Please obtain a copy of the License at
+http://www.opensource.apple.com/apsl/ and read it before using this
+file.
+
+The Original Code and all software distributed under the License are
+distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
+Please see the License for the specific language governing rights and
+limitations under the License."
Index: branches/iFabio/Test/coding_standards.txt
===================================================================
--- branches/iFabio/Test/coding_standards.txt (revision 0)
+++ branches/iFabio/Test/coding_standards.txt (revision 151)
@@ -0,0 +1,83 @@
+Coding Standard rev. 0 (First Draft)
+
+1. Indentation
+ having seen most indentation styles going from 2 to 8 spaces, I would suggest a indentation of 4 spaces.
+
+2. Comments
+I see here two main differents cases:
+function description comments and one-line code quite comments
+
+For functions documentation, I suggest to use this syntax
+/**
+ *
+ */
+Note the use of /** that will make future html auto-documentation easier (i.e: Doxygen at least recognize this marker)
+
+for punctual, short code comment, let's use:
+//
+3) #define at top of document
+4) Global vars right below #include / #define (notation: gLobal)
+Note that global vars and static vars should be avoided as much as possible in favor of local variables use, get/set functions (properties).
+
+5) No curly brackets for single lines
+
+6) else
+{
+ ....
+}
+
+instead of:
+
+else {
+ ....
+}
+
+7) if
+{
+ ....
+}
+instead of:
+
+if {
+ ....
+}
+
+8) fall through code (using indention) or bail out early (using returns)?
+Using early bail out for preconditions early in the function code,
+use common sense to avoid as an example more than 4 imbricated if() constructions.
+In the later case, consider decomposing your function in more manageable primitives.
+
+9) Spaces/readability i.e. not: if (fd<0)
+but: if (fd < 0)
+
+10. types, variables, functions, naming
+non const variables should follow the (currently mostly used) CamelCase convention:
+int myVariableIsFine;
+instead of :
+int my_variable_is_ok;
+
+Functions should follow the same conventions except for standard c lib related functions.
+Types should share the same convention but start with a Captial letter instead of lower case.
+
+11. Please make sure you extensively initialize variables:
+avoid as much as possible:
+int myVar
+...
+myVar = 10;
+
+but use instead:
+int myVar = 10;
+
+12. const values:
+const int MY_CONST_VARIABLE=42; is also ok for me, depending on the context of use.
+or
+const int MyConstVariable = 42; (with a Capital first letter)
+
+13. macro definitions should follow this convention:
+#define MY_HANDY_MACROS_PSEUDO_FUNC() ...
+
+14. Macros use should be limited to really special cases where they bring real value (like special optimization cases)
+Most of the time inlining a function is much better than the use of macros
+
+15. Don't optimize your code blindly, always favor readability when in doubt.
+Very often, optimization is not necessary where you think it is, think about the bubble sort algorithm, where people would code it in assembly, where a heap or quick sort algorithm would be much more efficient (n log(n) instead of quadratic complexity), as an example when values count to be sorted get high.
Index: branches/iFabio/Test/TODO
===================================================================
--- branches/iFabio/Test/TODO (revision 0)
+++ branches/iFabio/Test/TODO (revision 151)
@@ -0,0 +1,69 @@
+TODO List for Chameleon Boot Loader
+====================================
+- Integrate Prasys current work on options and quick shortcut modified version of 18seven
+
+- Add autodetection of efistring algorythm to enabke graphics enabler to beanbled by default while not conflicting whith other efi string overriden content
+ (original idea of Galaxy)
+
+- Add a more sophisticated acpi loading mechanism to enable loading custom acpi tables when dsdtdrop=y
+ Here's a specification to think about:
+ First we must care about if a forced DSDT full path has been specified (was the pb smith had in
+ his first tries) and take it for the DSDT path as is.
+ Then we have the case where no DSDT path was set where we run our usual DSDT search algorithm to find this file.
+ In the latter case, the file has to be named DSDT.aml and be in one of the / /Extra or bt(0,0)/Extra directory.
+
+ Now a first idea to implement correctly the acpi tables loading would be:
+
+ Whatever the path was hardcoded in the DSDT option or was automatically found, we extract the path part of
+ the DSDT file that has been successfully found and we run a loop to enumerate all other acpi files in the same directory.
+ Now for each acpi file found, we should compare the name with an existing acpi table found in the system that
+ we would normally load and replace this usual injection by the content of the file.
+
+ Once DropDSDT=y is set, no other acpi table than dsdt is loaded, then it is the responsability of user
+ to provide any other acpi table.
+
+- Add a new module capable of writing proprietary Chameleon data to ioreg:
+ Using the DT__xxx() API, we will creat e a set of functions to write
+ to log info, chameleon boot info to be retrieved by helper applications...
+ the only public function for log info purpose of this module would be:
+ logMessageToIOREG(...); // var args printf style format
+ flushLogToIOREG(); // store a unique log info property to the ioreg
+
+ The preferred internal behavior of the log info ioreg buffer
+ would be to store the messages in a consolidated buffer then only write once,
+ this buffer (i.e just before call the kernel) with flushLogToIOREG();
+ The other public function for writing chameleon boot info data would be:
+
+ verbose() should incorporate a call to logMessageToIOREG()
+ to permit helper applications to extract
+ this log info (i.e: the chameleon system pref pane)
+
+- Add API for displaying and logging messages like:
+
+ void verbose(...)
+ {
+ ...
+ logMessageToIOREG("%s: %sn", title, s);
+
+ }
+
+ void display_and_log( const char* title, const char* msg)
+ {
+ printf("%s: %sn", title, s);
+ logMessageToIOREG(title,s);
+ }
+
+ void deprecated(const char * s)
+ {
+ display_and_log("WARNING: Deprecated option",s);
+ sleep(1);
+ }
+
+ void error_message(const char * s)
+ {
+ display_and_log("ERROR",s);
+ getc();
+ }
+
+ - Case unsensitive parsing for the bootConfig options:
+ should help the common/novice user to setup more easily.
Index: branches/iFabio/Test/version
===================================================================
--- branches/iFabio/Test/version (revision 0)
+++ branches/iFabio/Test/version (revision 151)
@@ -0,0 +1 @@
+2.0-RC5
\ No newline at end of file
Index: branches/iFabio/Test/GPL_V2_LICENSE
===================================================================
--- branches/iFabio/Test/GPL_V2_LICENSE (revision 0)
+++ branches/iFabio/Test/GPL_V2_LICENSE (revision 151)
@@ -0,0 +1,339 @@
+ GNU GENERAL PUBLIC LICENSE
+ Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The licenses for most software are designed to take away your
+freedom to share and change it. By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users. This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it. (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.) You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+ To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have. You must make sure that they, too, receive or can get the
+source code. And you must show them these terms so they know their
+rights.
+
+ We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+ Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software. If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+ Finally, any free program is threatened constantly by software
+patents. We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary. To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ GNU GENERAL PUBLIC LICENSE
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+ 0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License. The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language. (Hereinafter, translation is included without limitation in
+the term "modification".) Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope. The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+ 1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+ 2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+ a) You must cause the modified files to carry prominent notices
+ stating that you changed the files and the date of any change.
+
+ b) You must cause any work that you distribute or publish, that in
+ whole or in part contains or is derived from the Program or any
+ part thereof, to be licensed as a whole at no charge to all third
+ parties under the terms of this License.
+
+ c) If the modified program normally reads commands interactively
+ when run, you must cause it, when started running for such
+ interactive use in the most ordinary way, to print or display an
+ announcement including an appropriate copyright notice and a
+ notice that there is no warranty (or else, saying that you provide
+ a warranty) and that users may redistribute the program under
+ these conditions, and telling the user how to view a copy of this
+ License. (Exception: if the Program itself is interactive but
+ does not normally print such an announcement, your work based on
+ the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole. If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works. But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+ 3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+ a) Accompany it with the complete corresponding machine-readable
+ source code, which must be distributed under the terms of Sections
+ 1 and 2 above on a medium customarily used for software interchange; or,
+
+ b) Accompany it with a written offer, valid for at least three
+ years, to give any third party, for a charge no more than your
+ cost of physically performing source distribution, a complete
+ machine-readable copy of the corresponding source code, to be
+ distributed under the terms of Sections 1 and 2 above on a medium
+ customarily used for software interchange; or,
+
+ c) Accompany it with the information you received as to the offer
+ to distribute corresponding source code. (This alternative is
+ allowed only for noncommercial distribution and only if you
+ received the program in object code or executable form with such
+ an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it. For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable. However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+ 4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License. Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+ 5. You are not required to accept this License, since you have not
+signed it. However, nothing else grants you permission to modify or
+distribute the Program or its derivative works. These actions are
+prohibited by law if you do not accept this License. Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+ 6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions. You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+ 7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all. For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices. Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+ 8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded. In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+ 9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number. If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation. If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+ 10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission. For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this. Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+ NO WARRANTY
+
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+
+ Copyright (C)
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License along
+ with this program; if not, write to the Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+Also add information on how to contact you by electronic and paper mail.
+
+If the program is interactive, make it output a short notice like this
+when it starts in an interactive mode:
+
+ Gnomovision version 69, Copyright (C) year name of author
+ Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, the commands you use may
+be called something other than `show w' and `show c'; they could even be
+mouse-clicks or menu items--whatever suits your program.
+
+You should also get your employer (if you work as a programmer) or your
+school, if any, to sign a "copyright disclaimer" for the program, if
+necessary. Here is a sample; alter the names:
+
+ Yoyodyne, Inc., hereby disclaims all copyright interest in the program
+ `Gnomovision' (which makes passes at compilers) written by James Hacker.
+
+ , 1 April 1989
+ Ty Coon, President of Vice
+
+This General Public License does not permit incorporating your program into
+proprietary programs. If your program is a subroutine library, you may
+consider it more useful to permit linking proprietary applications with the
+library. If this is what you want to do, use the GNU Lesser General
+Public License instead of this License.
\ No newline at end of file
Index: branches/iFabio/Test/CREDITS
===================================================================
--- branches/iFabio/Test/CREDITS (revision 0)
+++ branches/iFabio/Test/CREDITS (revision 151)
@@ -0,0 +1,37 @@
+Credit goes to:
+===============
+
+Developers:
+----------
+ Crazor
+ Dense
+ fassl
+ iNDi
+ JrCs
+ Kabyl
+ kaitek
+ mackerintel
+ mercurysquad
+ munky
+ meklort
+ mozodojo
+ rekursor
+ Turbo
+ valv
+ zef
+
+Thanks to:
+---------
+ asereBLN
+ Azimutz
+ bumby
+ cosmo1t
+ dfe
+ Galaxy
+ kalyway
+ Krazubu
+ MasterChief
+ netkas
+ sckevyn
+ smith@@
+ THeKiNG
Index: branches/iFabio/Test/Makefile
===================================================================
--- branches/iFabio/Test/Makefile (revision 0)
+++ branches/iFabio/Test/Makefile (revision 151)
@@ -0,0 +1,139 @@
+export USE_APPLE_PB_SUPPORT = all
+
+# Makefile for kernel booter
+
+# CFLAGS = -O $(MORECPP) -arch i386 -g
+DEFINES=
+CONFIG = hd
+LIBDIR = libsa
+INC = -I. -I$(LIBDIR)
+ifneq "" "$(wildcard /bin/mkdirs)"
+ MKDIRS = /bin/mkdirs
+else
+ MKDIRS = /bin/mkdir -p
+endif
+AS = as
+LD = ld
+PAX = /bin/pax
+
+OBJROOT = `pwd`/obj
+SYMROOT = `pwd`/sym
+DSTROOT = `pwd`/dst
+SRCROOT = /tmp
+DOCROOT = `pwd`/doc
+IMGROOT = `pwd`/sym/cache
+IMGSKELROOT = `pwd`/imgskel
+CDBOOT = ${IMGROOT}/usr/standalone/i386/cdboot
+
+THEME = default
+
+VERSION = `cat version`
+REVISION = `cat revision`
+PRODUCT = Chameleon-$(VERSION)-r$(REVISION)
+CDLABEL = ${PRODUCT}
+ISOIMAGE = ${SYMROOT}/${CDLABEL}.iso
+
+EXCLUDE = --exclude=.svn --exclude=.DS_Store --exclude=sym --exclude=obj \
+ --exclude=package --exclude=archive --exclude=User_Guide_src --exclude=*.sh
+
+ARCHLESS_RC_CFLAGS=`echo $(RC_CFLAGS) | sed 's/-arch [a-z0-9]*//g'`
+
+VPATH = $(OBJROOT):$(SYMROOT)
+
+GENERIC_SUBDIRS =
+
+#
+# Currently builds for i386
+#
+
+all embedtheme tags debug install installhdrs: $(SYMROOT) $(OBJROOT)
+ @if [ -e ".svn" ]; then svnversion -n | tr -d [:alpha:] > revision; fi
+ @if [ -z "$(RC_ARCHS)" ]; then \
+ RC_ARCHS="i386"; \
+ fi; \
+ SUBDIRS="$(GENERIC_SUBDIRS) $$RC_ARCHS"; \
+ for i in $$SUBDIRS; \
+ do \
+ if [ -d $$i ]; then \
+ echo ================= make $@ for $$i =================; \
+ ( OBJROOT=$(OBJROOT)/$${i}; \
+ SYMROOT=$(SYMROOT)/$${i}; \
+ DSTROOT=$(DSTROOT); \
+ XCFLAGS=$(ARCHLESS_RC_CFLAGS); \
+ GENSUBDIRS="$(GENERIC_SUBDIRS)"; \
+ for x in $$GENSUBDIRS; \
+ do \
+ if [ "$$x" == "$$i" ]; then \
+ XCFLAGS="$(RC_CFLAGS)"; \
+ break; \
+ fi \
+ done; \
+ echo "$$OBJROOT $$SYMROOT $$DSTROOT"; \
+ cd $$i; ${MAKE} \
+ "OBJROOT=$$OBJROOT" \
+ "SYMROOT=$$SYMROOT" \
+ "DSTROOT=$$DSTROOT" \
+ "SRCROOT=$$SRCROOT" \
+ "RC_ARCHS=$$RC_ARCHS" \
+ "TARGET=$$i" \
+ "RC_KANJI=$(RC_KANJI)" \
+ "JAPANESE=$(JAPANESE)" \
+ "RC_CFLAGS=$$XCFLAGS" $@ \
+ ) || exit $$?; \
+ else \
+ echo "========= nothing to build for $$i ========="; \
+ fi; \
+ done
+
+image:
+ @if [ -e "$(SYMROOT)" ]; then \
+ rm -r -f ${IMGROOT}; \
+ mkdir -p ${IMGROOT}/usr/standalone/i386; \
+ if [ -e "$(IMGSKELROOT)" ]; then \
+ cp -R -f "${IMGSKELROOT}"/* "${IMGROOT}"; \
+ fi; \
+ cp -f ${SYMROOT}/i386/cdboot ${CDBOOT}; \
+ cp -f ${SYMROOT}/i386/boot ${IMGROOT}/usr/standalone/i386; \
+ cp -f ${SYMROOT}/i386/boot0 ${IMGROOT}/usr/standalone/i386; \
+ cp -f ${SYMROOT}/i386/boot1h ${IMGROOT}/usr/standalone/i386; \
+ cp -f ${SYMROOT}/i386/boot1f32 ${IMGROOT}/usr/standalone/i386;\
+ $(shell hdiutil makehybrid -iso -joliet -hfs -hfs-volume-name \
+ ${CDLABEL} -eltorito-boot ${CDBOOT} -no-emul-boot -ov -o \
+ "${ISOIMAGE}" ${IMGROOT} -quiet) \
+ fi;
+
+pkg installer: embedtheme
+ @if [ -e "$(SYMROOT)" ]; then \
+ sudo `pwd`/package/buildpkg `pwd`/sym/package; \
+ fi;
+
+advanced installer: embedtheme
+ @if [ -e "$(SYMROOT)" ]; then \
+ sudo `pwd`/package/advanced `pwd`/sym/package; \
+ fi;
+
+basic installer: embedtheme
+ @if [ -e "$(SYMROOT)" ]; then \
+ sudo `pwd`/package/basic `pwd`/sym/package; \
+ fi;
+
+release: $(SYMROOT)
+ @if [ -e ".svn" ]; then svnversion -n | tr -d [:alpha:] > revision; fi
+ @if [ -e "$(SYMROOT)" ]; then \
+ sudo `pwd`/package/buildpkg `pwd`/sym/package; \
+ fi;
+ @tar -czf $(SYMROOT)/$(PRODUCT)-src.tar.gz ${EXCLUDE} .
+ @tar -cjf $(SYMROOT)/$(PRODUCT)-src.tar.bz2 ${EXCLUDE} .
+
+clean:
+ rm -rf sym obj dst
+
+#distclean: clean
+# @rm -f $(SYMROOT)/$(PRODUCT)-src.*
+# @rm -f $(SYMROOT)/$(PRODUCT).pkg
+
+installsrc:
+ gnutar cf - . | (cd ${SRCROOT}; gnutar xpf -)
+
+$(SYMROOT) $(OBJROOT) $(DSTROOT):
+ @$(MKDIRS) $@
Property changes on: branches/iFabio/Test/Makefile
___________________________________________________________________
Added: svn:executable
+ *
Index: branches/iFabio/Test/README
===================================================================
--- branches/iFabio/Test/README (revision 0)
+++ branches/iFabio/Test/README (revision 151)
@@ -0,0 +1,7 @@
+Chameleon is a Darwin/XNU boot loader based on Apple's boot-132.
+
+Because Chameleon now uses part of GPL V2 licensed code in 2 files,
+it *must* conform to the most restrictive license that it uses that is the:
+GPL Version 2 LICENSE
+
+Chameleon can thus be (and has to be) freely distributed under the term of the GPL V2 license which prevails, as it is the most restrictive license.
Index: branches/iFabio/Test/MEMTEST86_LICENSE
===================================================================
--- branches/iFabio/Test/MEMTEST86_LICENSE (revision 0)
+++ branches/iFabio/Test/MEMTEST86_LICENSE (revision 151)
@@ -0,0 +1,32 @@
+dram_controllers.c/h that scans from the pci host controller USES
+an adaptation for chameleon 2.0 RC5 from original :
+
+========================
+memtest86 license notice
+========================
+
+ Released under version 2 of the Gnu Public License.
+ By Chris Brady, cbrady@sgi.com
+ ----------------------------------------------------
+ MemTest86+ V4.00 Specific code (GPL V2.0)
+ By Samuel DEMEULEMEESTER, sdemeule@memtest.org
+ http://www.canardpc.com - http://www.memtest.org
+
+
+============================
+GPL version 2 license notice
+============================
+
+This program is free software; you can redistribute it and/or
+modify it under the terms of the GNU General Public License
+as published by the Free Software Foundation; either version 2
+of the License, or (at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
Index: branches/iFabio/Test/revision
===================================================================
--- branches/iFabio/Test/revision (revision 0)
+++ branches/iFabio/Test/revision (revision 151)
@@ -0,0 +1 @@
+516:535
\ No newline at end of file
Index: branches/iFabio/Original-package/Makefile
===================================================================
--- branches/iFabio/Original-package/Makefile (revision 0)
+++ branches/iFabio/Original-package/Makefile (revision 151)
@@ -0,0 +1,129 @@
+export USE_APPLE_PB_SUPPORT = all
+
+# Makefile for kernel booter
+
+# CFLAGS = -O $(MORECPP) -arch i386 -g
+DEFINES=
+CONFIG = hd
+LIBDIR = libsa
+INC = -I. -I$(LIBDIR)
+ifneq "" "$(wildcard /bin/mkdirs)"
+ MKDIRS = /bin/mkdirs
+else
+ MKDIRS = /bin/mkdir -p
+endif
+AS = as
+LD = ld
+PAX = /bin/pax
+
+OBJROOT = `pwd`/obj
+SYMROOT = `pwd`/sym
+DSTROOT = `pwd`/dst
+SRCROOT = /tmp
+DOCROOT = `pwd`/doc
+IMGROOT = `pwd`/sym/cache
+IMGSKELROOT = `pwd`/imgskel
+CDBOOT = ${IMGROOT}/usr/standalone/i386/cdboot
+
+THEME = default
+
+VERSION = `cat version`
+REVISION = `cat revision`
+PRODUCT = Chameleon-$(VERSION)-r$(REVISION)
+CDLABEL = ${PRODUCT}
+ISOIMAGE = ${SYMROOT}/${CDLABEL}.iso
+
+EXCLUDE = --exclude=.svn --exclude=.DS_Store --exclude=sym --exclude=obj \
+ --exclude=package --exclude=archive --exclude=User_Guide_src --exclude=*.sh
+
+ARCHLESS_RC_CFLAGS=`echo $(RC_CFLAGS) | sed 's/-arch [a-z0-9]*//g'`
+
+VPATH = $(OBJROOT):$(SYMROOT)
+
+GENERIC_SUBDIRS =
+
+#
+# Currently builds for i386
+#
+
+all embedtheme tags debug install installhdrs: $(SYMROOT) $(OBJROOT)
+ @if [ -e ".svn" ]; then svnversion -n | tr -d [:alpha:] > revision; fi
+ @if [ -z "$(RC_ARCHS)" ]; then \
+ RC_ARCHS="i386"; \
+ fi; \
+ SUBDIRS="$(GENERIC_SUBDIRS) $$RC_ARCHS"; \
+ for i in $$SUBDIRS; \
+ do \
+ if [ -d $$i ]; then \
+ echo ================= make $@ for $$i =================; \
+ ( OBJROOT=$(OBJROOT)/$${i}; \
+ SYMROOT=$(SYMROOT)/$${i}; \
+ DSTROOT=$(DSTROOT); \
+ XCFLAGS=$(ARCHLESS_RC_CFLAGS); \
+ GENSUBDIRS="$(GENERIC_SUBDIRS)"; \
+ for x in $$GENSUBDIRS; \
+ do \
+ if [ "$$x" == "$$i" ]; then \
+ XCFLAGS="$(RC_CFLAGS)"; \
+ break; \
+ fi \
+ done; \
+ echo "$$OBJROOT $$SYMROOT $$DSTROOT"; \
+ cd $$i; ${MAKE} \
+ "OBJROOT=$$OBJROOT" \
+ "SYMROOT=$$SYMROOT" \
+ "DSTROOT=$$DSTROOT" \
+ "SRCROOT=$$SRCROOT" \
+ "RC_ARCHS=$$RC_ARCHS" \
+ "TARGET=$$i" \
+ "RC_KANJI=$(RC_KANJI)" \
+ "JAPANESE=$(JAPANESE)" \
+ "RC_CFLAGS=$$XCFLAGS" $@ \
+ ) || exit $$?; \
+ else \
+ echo "========= nothing to build for $$i ========="; \
+ fi; \
+ done
+
+image:
+ @if [ -e "$(SYMROOT)" ]; then \
+ rm -r -f ${IMGROOT}; \
+ mkdir -p ${IMGROOT}/usr/standalone/i386; \
+ if [ -e "$(IMGSKELROOT)" ]; then \
+ cp -R -f "${IMGSKELROOT}"/* "${IMGROOT}"; \
+ fi; \
+ cp -f ${SYMROOT}/i386/cdboot ${CDBOOT}; \
+ cp -f ${SYMROOT}/i386/boot ${IMGROOT}/usr/standalone/i386; \
+ cp -f ${SYMROOT}/i386/boot0 ${IMGROOT}/usr/standalone/i386; \
+ cp -f ${SYMROOT}/i386/boot1h ${IMGROOT}/usr/standalone/i386; \
+ cp -f ${SYMROOT}/i386/boot1f32 ${IMGROOT}/usr/standalone/i386;\
+ $(shell hdiutil makehybrid -iso -joliet -hfs -hfs-volume-name \
+ ${CDLABEL} -eltorito-boot ${CDBOOT} -no-emul-boot -ov -o \
+ "${ISOIMAGE}" ${IMGROOT} -quiet) \
+ fi;
+
+pkg installer: embedtheme
+ @if [ -e "$(SYMROOT)" ]; then \
+ sudo `pwd`/package/buildpkg `pwd`/sym/package; \
+ fi;
+
+release: $(SYMROOT)
+ @if [ -e ".svn" ]; then svnversion -n | tr -d [:alpha:] > revision; fi
+ @if [ -e "$(SYMROOT)" ]; then \
+ sudo `pwd`/package/buildpkg `pwd`/sym/package; \
+ fi;
+ @tar -czf $(SYMROOT)/$(PRODUCT)-src.tar.gz ${EXCLUDE} .
+ @tar -cjf $(SYMROOT)/$(PRODUCT)-src.tar.bz2 ${EXCLUDE} .
+
+clean:
+ rm -rf sym obj dst
+
+#distclean: clean
+# @rm -f $(SYMROOT)/$(PRODUCT)-src.*
+# @rm -f $(SYMROOT)/$(PRODUCT).pkg
+
+installsrc:
+ gnutar cf - . | (cd ${SRCROOT}; gnutar xpf -)
+
+$(SYMROOT) $(OBJROOT) $(DSTROOT):
+ @$(MKDIRS) $@