debian/0000755000000000000000000000000011455320607007171 5ustar debian/changelog0000644000000000000000000003537511455320607011060 0ustar refit (0.14-2ubuntu1) natty; urgency=low * Resynchronise with Debian. Remaining changes: - Create gptsync-udeb. - Build with -fno-stack-protector on Ubuntu. * Drop Ubuntu change to build-depend on syslinux rather than syslinux-common, since we have syslinux-common in our archive now. -- Colin Watson Wed, 13 Oct 2010 13:09:10 +0100 refit (0.14-2) unstable; urgency=low * debian/control: + Bump gnu-efi build-dep to 3.0i-3. * debian/patches/x64_no_optim.patch: + Removed; no longer needed as optimization wasn't the issue. -- Julien BLACHE Wed, 05 May 2010 18:21:55 +0200 refit (0.14-1) unstable; urgency=low * New upstream release. * Switch to source format 3.0 (quilt). * debian/control: + Bump Standards-Version to 3.8.4 (no changes). + Remove dpatch build-dep. + Drop ${shlibs:Depends} for refit. + Add ${misc:Depends}. * debian/rules: + Remove dpatch code. + Don't run dh_shlibdeps on refit. * debian/patches/efi_call_wrappers.patch: + Added; introduce new refit_callX_wrapper() macros. * EFI call wrapper patches: + Rewritten to use the refit_callX_wrapper() macros instead of using the call wrapper directly; turns out the arguments need to be UINT64 for the call wrapper to work properly. Fixes random failures and missing images on X64. * All patches refreshed, tagged with DEP-3 fields. -- Julien BLACHE Wed, 21 Apr 2010 18:11:08 +0200 refit (0.13-11) unstable; urgency=low * debian/control: + Bump gnu-efi build-dep, as we need a version of gnu-efi built without optimization for x64 builds; see below. * debian/patches/13_x64_no_optim.dpatch: + Added; disable optimization for x64 builds as it looks very much like there are issues with the call wrapper and optimized builds, leading to weird breakages at runtime. -- Julien BLACHE Wed, 11 Nov 2009 10:35:00 +0100 refit (0.13-10) unstable; urgency=low * debian/patches/23_gptsync_biosboot.dpatch: + Updated; remove unwanted hunk. -- Julien BLACHE Mon, 19 Oct 2009 23:05:29 +0200 refit (0.13-9) unstable; urgency=low * debian/patches/23_gptsync_biosboot.dpatch: + Updated; fix byte order for GUID data. -- Julien BLACHE Mon, 19 Oct 2009 22:47:31 +0200 refit (0.13-8) unstable; urgency=low * debian/patches/40_disable_EFI110_features.dpatch: + Updated; re-enable shutdown menu action now that gnu-efi provides the EfiResetShutdown definition and we have a build-dep on a newer gnu-efi version for other good reasons. * debian/patches/42_refit_uefi_call_wrapper.dpatch: + Updated. -- Julien BLACHE Sun, 20 Sep 2009 18:09:26 +0200 refit (0.13-7) unstable; urgency=low * debian/patches/10_kfreebsd.dpatch: + Updated; remove extra LDSCRIPT line. * debian/patches/11_fat_binaries_build.dpatch: + Updated. -- Julien BLACHE Sun, 20 Sep 2009 13:00:26 +0200 refit (0.13-6) unstable; urgency=low * debian/patches/10_kfreebsd.dpatch: + Added; select appropriate linker script on kfreebsd-amd64. * debian/patches/11_fat_binaries_build.dpatch: + Renamed, updated. * debian/patches/12_debian_version_string.dpatch: + Renamed. -- Julien BLACHE Sun, 20 Sep 2009 11:37:38 +0200 refit (0.13-5) unstable; urgency=low * debian/control: + Bump gnu-efi build-dep to 3.0i. + Add kfreebsd-amd64 to supported architectures. -- Julien BLACHE Sat, 12 Sep 2009 11:43:22 +0200 refit (0.13-4) unstable; urgency=low * debian/control: + Bump Standards-Version to 3.8.3 (no changes). * debian/patches/23_gptsync_biosboot.dpatch: + Map GPT "BIOS Boot Partition" type to MBR type 0xda ("Non-FS data") (closes: #545190). -- Julien BLACHE Sat, 05 Sep 2009 19:26:40 +0200 refit (0.13-3ubuntu2) karmic; urgency=low * No-change upload to build on amd64 as well (LP: #382184). -- Colin Watson Thu, 10 Sep 2009 13:31:12 +0100 refit (0.13-3ubuntu1) karmic; urgency=low * Resynchronise with Debian. Remaining changes: - Create gptsync-udeb. * Revert to build-depending on syslinux; we don't have syslinux-common yet (largely because updating syslinux+gfxboot is a time-consuming pain, unfortunately). * debian/patches/99_no_stack_protector.dpatch: - Build with -fno-stack-protector on Ubuntu. -- Colin Watson Wed, 24 Jun 2009 16:38:39 +0100 refit (0.13-3) unstable; urgency=low * debian/patches/10_fat_binaries_build.dpatch: + Add -mno-red-zone for x86_64 builds, consistent with gnu-efi. -- Julien BLACHE Fri, 19 Jun 2009 19:43:07 +0200 refit (0.13-2) unstable; urgency=low * debian/control: + Build-Depends on syslinux-common instead of syslinux. + Bump gnu-efi build-dep to 3.0e-3 implementing the /emul/ia32-linux to /usr/lib32 transition. * debian/patches/10_fat_binaries_build.dpatch: + Look for EFI libraries in /usr/lib32, not /emul/ia32-linux. -- Julien BLACHE Wed, 17 Jun 2009 16:45:15 +0200 refit (0.13-1) unstable; urgency=low * New upstream release. * debian/control: + Bump Standards-Version to 3.8.1 (no changes). * debian/copyright: + Update. * debian/patches/03_refit_gcc_warning_fix.dpatch: + Removed; merged upstream. * debian/patches/11_debian_version_string.dpatch: + Updated. * debian/patches/42_refit_uefi_call_wrapper.dpatch: + Updated. -- Julien BLACHE Fri, 27 Mar 2009 22:26:51 +0100 refit (0.12-2ubuntu1) jaunty; urgency=low * Resynchronise with Debian. Remaining changes: - Create gptsync-udeb. - debian/patches/10_fat_binaries_build.dpatch: + Ubuntu uses /usr/lib32 rather than /emul/ia32-linux/usr/lib; adjust accordingly. * Add showpart to gptsync-udeb. -- Colin Watson Sun, 23 Nov 2008 13:33:37 +0000 refit (0.12-2) unstable; urgency=low * Reupload to unstable. -- Julien BLACHE Mon, 03 Nov 2008 12:12:13 +0100 refit (0.12-1) experimental; urgency=low * New upstream release. * debian/copyright: + Update. * debian/patches/04_late_2008_laptops.dpatch: + Removed; stolen from this release. * debian/patches/11_debian_version_string.dpatch: + Updated. * debian/patches/43_libeg_uefi_call_wrapper.dpatch: + Updated. -- Julien BLACHE Thu, 23 Oct 2008 18:50:55 +0200 refit (0.11-5) unstable; urgency=low * debian/patches/04_late_2008_laptops.dpatch: + Added; add support for late 2008 Apple laptops, stolen from rEFIt 0.12. -- Julien BLACHE Thu, 23 Oct 2008 17:54:51 +0200 refit (0.11-4) unstable; urgency=low * debian/control: + Add missing Replaces: refit on gptsync. -- Julien BLACHE Thu, 31 Jul 2008 10:33:52 +0200 refit (0.11-3) unstable; urgency=low * debian/control: + New binary package gptsync (closes: #491604). * debian/patches/21_gptsync_manpage.dpatch: + Updated; fixup wording. * debian/showpart.8: + Added; manpage for showpart. -- Julien BLACHE Thu, 24 Jul 2008 22:25:11 +0200 refit (0.11-2) unstable; urgency=low * debian/control: + Bump Standards-Version to 3.8.0 (no changes). * debian/copyright: + Fix overly long lines. * debian/patches/20_gptsync_quiet_mode.dpatch: + Updated; showpart accepts no options. * debian/patches/22_gptsync_dont_truncate.dpatch: + Added; ignore partitions starting or extending beyond 2 TiB by default. Introduce a -t switch to force including and truncating such partitions. (closes: #491612). -- Julien BLACHE Thu, 24 Jul 2008 19:40:15 +0200 refit (0.11-1ubuntu2) intrepid; urgency=low * Install gptsync/buildux/gptsync rather than gptsync/gptsync. * Move gptsync-udeb to Section: debian-installer. -- Colin Watson Thu, 12 Jun 2008 11:03:28 +0100 refit (0.11-1ubuntu1) intrepid; urgency=low * Resynchronise with Debian (LP: #227207). Remaining changes: - Create gptsync-udeb. * Build gptsync-udeb on amd64. * debian/patches/10_fat_binaries_build.dpatch: - Ubuntu uses /usr/lib32 rather than /emul/ia32-linux/usr/lib; adjust accordingly. -- Colin Watson Thu, 12 Jun 2008 01:50:14 +0100 refit (0.11-1) unstable; urgency=low * New upstream release. * debian/font: + Ship an antialiased font for rEFIt. * debian/mbr: + Added mkmbrhdr.h to generate include/syslinux_mbr.h at build time. * debian/README.Debian: + Add a paragraph about the EFI shell and tools distributed with rEFIt upstream and why they aren't distributed in this package. + Document the build of a bootable rEFIt (EFI) CD/DVD. + Document the ia32 vs. x64 binaries and fat EFI binaries. * debian/copyright: + Update. * debian/control: + Build-Depend on syslinux, for /usr/lib/syslinux/mbr.bin. + Bump gnu-efi build-dep to >= 3.0e-2. * debian/rules: + Generate include/syslinux_mbr.h at build time. + Replace the font provided with rEFIt by the antialised font shipped in debian/font. * debian/install: + Install showpart. + Install icons, vollabel and config file. + Install ia32 and x64 binaries too, for bootable CDs. * debian/patches/10_fat_binaries_build.dpatch: + Updated; add -DEFI32 / -DEFIX64 to CPPFLAGS in Make.common. * debian/patches/11_debian_version_string.dpatch: + Updated. * debian/patches/20_gptsync_quiet_mode.dpatch: + Added; add a quiet mode to gptsync for non-interactive use. * debian/patches/21_gptsync_manpage.dpatch: + Added; rewrite the manpage. * debian/patches/40_disable_EFI110_features.dpatch: + Updated. * debian/patches/42_refit_uefi_call_wrapper.dpatch: + Updated. * debian/patches/03_refit_gcc_warning_fix.dpatch: + Added; fix a gcc warning. -- Julien BLACHE Wed, 04 Jun 2008 22:53:05 +0200 refit (0.10-1) unstable; urgency=low * New upstream release. * debian/control: + Build-Depend on python, gcc-multilib. * debian/rules: + Build ia32 and x86_64 EFI binaries, then assemble them into final fat EFI binaries. * debian/patches/02_ia32_build_on_amd64.dpatch: + Removed; we're now building fat EFI binaries with ia32 and x86_64 architecture support. * debian/patches/03_replace_mcpu.dpatch: + Removed; looks like this is not needed after all, at least gnu-efi currently doesn't set any option for ia32 code generation. * debian/patches/04_gptsync_nom_nom_nom_newline.dpatch: + Renamed; 02_gptsync_nom_nom_nom_newline.dpatch. * debian/patches/10_fat_binaries_build.dpatch: + Added; support in the build infrastructure to build ia32 and x86_64 binaries in separate build directories. * debian/patches/10_debian_version_string.dpatch: + Renamed & updated; 11_debian_version_string.dpatch. * debian/patches/41_gptsync_uefi_call_wrapper.dpatch: + Added; wrap EFI API calls in uefi_call_wrapper(). * debian/patches/42_refit_uefi_call_wrapper.dpatch: + Added; wrap EFI API calls in uefi_call_wrapper(). * debian/patches/43_libeg_uefi_call_wrapper.dpatch: + Added; wrap EFI API calls in uefi_call_wrapper(). * debian/README.sources: + Added. * debian/TODO: + Updated. -- Julien BLACHE Wed, 21 May 2008 20:41:23 +0200 refit (0.9-1) unstable; urgency=low * New upstream release. * debian/patches/01_gptsync_64bit_fix.dpatch: + Updated. * debian/patches/30_gptsync_man.dpatch: + Removed; merged upstream. * debian/patches/40_disable_EFI110_features.dpatch: + Updated; disable shutdown feature. * debian/patches/10_debian_version_string.dpatch: + Updated. -- Julien BLACHE Tue, 20 May 2008 19:41:32 +0200 refit (0.8-1) unstable; urgency=low * New upstream release. * debian/rules: + Pass DEBVER when building refit. * debian/patches/10_gptsync_EFI_app_build.dpatch: + Removed; merged upstream. * debian/patches/40_disable_EFI110_features.dpatch: + Added; disable features that require EFI110. * debian/patches/10_debian_version_string.dpatch: + Added; append the debian version to the version string. * debian/README.Debian, debian/TODO: + Update. -- Julien BLACHE Tue, 20 May 2008 19:13:04 +0200 refit (0.7-6) unstable; urgency=low * debian/patches/04_gptsync_nom_nom_nom_newline.dpatch: + Added; when prompting for user input, consume characters up to and including newline (closes: #387957). -- Julien BLACHE Mon, 19 May 2008 22:52:05 +0200 refit (0.7-5) unstable; urgency=low * debian/control: + Build-Depend on gcc-multilib on amd64 (for 32bit libgcc.a). * debian/patches/02_ia32_build_on_amd64.dpatch: + Updated; pick up the 32bit libgcc.a when building on amd64. -- Julien BLACHE Mon, 19 May 2008 19:00:58 +0200 refit (0.7-4) unstable; urgency=low * Adopting refit, taking over from Enrico Tassi (closes: #430721). * debian/control: + Bump Standards-Version to 3.7.3 (no changes). + Build-Depend: gnu-efi (>= 3.0e-1.1) to be able to build on amd64. + refit: add amd64 to Architecture. + refit: rewrite descriptions. * debian/README.Debian, debian/TODO: + Update. * debian/patches/01_gptsync_efi.dpatch: + Renamed; 10_gptsync_EFI_app_build.dpatch. * debian/patches/03_gptsync_man.dpatch: + Renamed; 30_gptsync_man.dpatch. * debian/patches/01_gptsync_64bit_fix.dpatch: + Added; fix runtime failure of gptsync on 64bit platforms. * debian/patches/02_ia32_build_on_amd64.dpatch: + Added; enabled building a ia32 refit binary on amd64. * debian/patches/03_replace_mcpu.dpatch: + Added; use -mtune instead of -mcpu which is deprecated. -- Julien BLACHE Sun, 18 May 2008 17:24:00 +0200 refit (0.7-3ubuntu1) feisty; urgency=low * Create gptsync-udeb. -- Colin Watson Sat, 13 Jan 2007 22:47:50 +0000 refit (0.7-3) unstable; urgency=low * debian/copyright: add missing copyright information on syslinux and Intel code. -- Junichi Uekawa Sun, 9 Jul 2006 22:47:30 +0900 refit (0.7-2) unstable; urgency=low * README.Debian: update a little bit. * remove gptsync.o from UNIX build so that it's not used in EFI build. -- Junichi Uekawa Sat, 8 Jul 2006 13:42:08 +0900 refit (0.7-1) unstable; urgency=low * Initial release (Closes: #375999) - 01_gptsync_efi: build gptsync.efi - 02_wip: other patches pending resolution of 376000. - 03_gptsync_man: manpage for gptsync command. -- Junichi Uekawa Sun, 2 Jul 2006 08:50:51 +0900 debian/font/0000755000000000000000000000000011455320607010137 5ustar debian/font/font.png.uu0000644000000000000000000002667311455320607012261 0ustar begin 664 font.png MB5!.1PT*&@H````-24A$4@```J`````,"`8```"]?0]Y```*36E#0U!0:&]T M;W-H;W`@24-#('!R;V9I;&4``'C:G5-W6)/W%C[?]V4/5D+8\+&7;($`(B.L M",@06:(0D@!AA!`20,6%B`I6%!41G$A5Q(+5"DB=B.*@*+AG08J(6HM57#CN M']RGM7UZ[^WM^]?[O.><\/@!$2)I'FHFH`.5*%/#K8'X]/2,3)O8`" M%4C@!"`0YLO"9P7%``#P`WEX?G2P/_P!KV\``@!PU2XD$L?A_X.Z4"97`""1 M`.`B$N<+`9!2`,@N5,@4`,@8`+!3LV0*`)0``&QY?$(B`*H-`.ST23X%`-BI MD]P7`-BB'*D(`(T!`)DH1R0"0+L`8%6!4BP"P,(`H*Q`(BX$P*X!@%FV,D<" M@+T%`':.6)`/0&``@)E"+,P`(#@"`$,>$\T#($P#H##2O^"I7W"%N$@!`,#+ ME0BG)>;(Q-(YP-,S@P``!KY MT<'^.#^0Y^;DX>9FYVSO],6B_FOP;R(^(?'?_KR,`@0`$$[/[]I?Y>76`W#' M`;!UOVNI6P#:5@!HW_E=,]L)H%H*T'KYBWDX_$`>GJ%0R#P='`H+"^TE8J&] M,..+/O\SX6_@BW[V_$`>_MMZ\`!QFD"9K<"C@_UQ86YVKE*.Y\L$0C%N]^%?_V.*='B-+%<+!6*\5B)N%`B3<=YN5*11"')E>(2Z7\R\1^6_0F3=PT` MK(9/P$ZV![7+;,!^[@$"BPY8TG8`0'[S+8P:"Y$`$& MPAB\A@D$0<@($V$A.H@18H[8(LX(%YF.!")A2#22@*0@Z8@442+%R'*D`JE" M:I%=2"/R+7(4.8U<0/J0V\@@,HK\BKQ',92!LE$#U`)U0+FH'QJ*QJ!ST70T M#UV`EJ)KT1JT'CV`MJ*GT4OH=70`?8J.8X#1,0YFC-EA7(R'16")6!HFQQ9C MY5@U5H\U8QU8-W85&\">8>\()`*+@!/L"%Z$$,)L@I"01UA,6$.H)>PCM!*Z M"%<)@X0QPB&(ZL9!81JPF[B$>(9XE7B<.$U^32"0.R9+D M3@HA)9`R20M):TC;2"VD4Z0^TA!IG$PFZY!MR=[D"+*`K""7D;>0#Y!/DOO) MP^2W%#K%B.),":(D4J24$DHU93_E!*6?,D*9H*I1S:F>U`BJB#J?6DEMH'90 M+U.'J1,T=9HES9L60\ND+:/5T)II9VGW:"_I=+H)W8,>19?0E])KZ`?IY^F# M]'<,#88-@\=(8B@9:QE[&:<8MQDOF4RF!=.7FMJ^VF+MO:[W5PG4"=+)WU.FTZ M]W4)NC:Z4;J%NMMUS^H^TV/K>>D)]9=QK/&%B:3+;I,2DQ>2^*8;[9O-O\C86E19S%2HLVB\>6VI9\RP6639;WK)A6/E9Y5O56UZQ)UESK M+.MMUE=L4!M7FPR;.IO+MJBMFZW$=IMMWQ3B%(\ITBGU4V[:,>S\[`KLFNP& M[3GV8?8E]FWVSQW,'!(=UCMT.WQR='7,=FQPO.NDX33#J<2IP^E79QMGH7.= M\S47IDN0RQ*7=I<74VVGBJ=NGWK+E>4:[KK2M=/UHYN[F]RMV6W4W^[T>3[.<)I[6,&W( MV\1;X+W+>V`Z/CUE^L[I`S[&/@*?>I^'OJ:^(M\]OB-^UGZ9?@?\GOL[^LO] MC_B_X7GR%O%.!6`!P0'E`;V!&H&S`VL#'P29!*4'-06-!;L&+PP^%4(,"0U9 M'W*3;\`7\AOY8S/<9RR:T17*")T56AOZ,,PF3![6$8Z&SPC?$'YOIOE,Z]JE]5;5G\J%Y5?K'"L MJ*[XL$:XYN)73E_5?/5Y;=K:WDJWRNWK2.NDZVZL]UF_KTJ]:D'5T(;P#:T; M\8WE&U]M2MYTH7IJ]8[-M,W*S0,U837M6\RVK-ORH3:C]GJ=?UW+5OVMJ[>^ MV2;:UK_==WOS#H,=%3O>[Y3LO+4K>%=KO45]]6[2[H+=CQIB&[J_YG[=N$=W M3\6>CWNE>P?V1>_K:G1O;-ROO[^R"6U2-HT>2#IPY9N`;]J;[9IWM7!:*@[" M0>7!)]^F?'OC4.BASL/YX]=\+QP]"+W8MLEMTNM/:X]1WYP_>%(KUMO MZV7WR^U7/*YT]$WK.]'OTW_Z:L#5<]?XURY=GWF][\;L&[=N)MTH]XK_R^VOWJ!_H/ZG^T_K%EP&W@^&#`8,_#60_O#@F'GOZ4 M_].'X=)'S$?5(T8CC8^='Q\;#1J]\F3.D^&GLJ<3S\I^5O]YZW.KY]_]XOM+ MSUC\V/`+^8O/OZYYJ?-R[ZNIKSK'(\]'YDH M_$#^4//1^F/'I]!/]S[G?/[\+_>$\_LETI\S````!F)+1T0`_P#_`/^@O:>3 M````"7!(67,```L3```+$P$`FIP8````!W1)344'V`47$QX1EP;6L```%E)) M1$%4>-KM77M<5-7VWX/(8P:&P4>`D(`(2"GRM'124RZ#I*F@AI!HW4IO5D1T MT\P*4PN-DIM9J:EIWO*:@$EEI*&&<2U+"Q&N;T'#0A10AL<,,_.]?_Q^9W?. MG'WF`6B/R_?SX0-G/];9>^V]UUI[K;T/,@`@/?C3HZ.C@_3NW;N'$;]#[-RY MDZ2DI-`QVKY].TE*2NIA3`]ZT(,>].!/"P=;"_KY^8G29#(9B8R,%/W-X?+E MRR0D)(3^-H>GIR=3&2L4"K)SY\Y.=4@FDUG,7[1HD4UI?"B5RM^=,1D<'$S: MVMH((824EI:2I*0D$A`00)R4EJF=>QYRF^=A: MRF]N;B:3)T\F@8&!Y,X[[R0^/CZB.JSGG)P<0=JZ=>LL]M,6FJRV\],'#QY, M""$D(2%!1'_:M&E,&C_^^",)#P\G+BXN)"XNCE165C+;&!861LK+RVE>4U,3 M&3]^/'%V=B8!`0%DV[9MHCJ.CHYD[-BQI*:FAM;[XHLO2&!@(/'P\"#_^,<_ MB*^OK\4QL,:GSN9Y>GJ*Y)]2J22>GIYVC8,U.<$!`%F^?+F`%RP9SZ+'X-C8TVZQEKNN9&T.'DG4*A(*-'C^XV^I;*2(W;S>!/#VXL*BHJ MR&VWW<;,8]EGA!`2%A9&/O[XX^YI`&P$JR@A!*M7KQ;]S6'5JE5X\LDGZ6\. MA86%Z-V[-P@AZ-NWKZ".7"X'(01RN1R=@:4NG3IU"O/GSQ>ESY\_'V?/GA6E M3YTZ%?/FS0,A!//FS4-24I*H3)\^?7"SL7;M6OSM;W^CSR$A(;ARY0H`H*RL M#`J%PB:^J%0J[-Z]6S`F',:-&X=OOOD&1J-1E`<`!H,!PX_=&86$A M`*"MK0U;MVZ%R63J%CXW-C8B+2T-?_WK7ZV6G35K%E)34]'8V"A9AN,CO\TL M?ID_ZW0ZQ,7%X8L[*RD).3@Y,)A-*2TNA5"IMIF%MW5JCT=34A(2$!'SWW7=6Z1%"$!`0 M@)J:&@P=.E10CA""V-A8-#4UB6C,FC4+QXX=@TZGPX$#!Q`9&/CAAV$T&@$`$R=.Q-Z]>P$`>_?NQ<2)$R7GYYUW MWFG3F.MT.KSQQAN=DO5%145P=W='45&1W>O]ZM6K>/311[M%UW1%9QD,!G1T M=##+FLN.F]E.>VG>B/?^7L!?+W]D!`<'H[JZVJ[Q.W?N7*?ZS])_73)`^_?O MCZM7KXK^YC!\^'#\\,,/]#>'?OWZ27:ZL+`0>$`@DSDCL[Z^'EY>7C3OFV^^P:1)D]#6UH;ITZ<+9/?I MTZ>A5JMA-!JA5JOI.N7CYY]_AK^_/TZ?/FWSF.?EY4D:85+U3YX\B:BH*)P] M>Q9145$X>?)DM\C103^JJJK@Y>6%7KUZX>Z[ M[\;//_\L.'#@@""?$(*2DA+X^OJ*#-COO_]>1(O? M/]:[S.6`I?HL>G/GSD5961EFSY[]JR'R_WFK5Z]&W[Y]1>V\:QG2WF>GIYT\PD`"H6".KVD MZG%./19]

)I378V3PIL/1?EPQ02S`?)+X'9L*$"!`Y M.3FXYYY[!-XN;A&>/7L69\Z<80KG@0,'2K9IV+!A`B'!X?SY\Q@V;!BS3D9& M!J9.G8K4U-3?Q2YOS9HU>.211P1I3DY.75;PQ<7%J*^O9X[CJ%&CJ`<2`)J; MFS%X\&#\\LLO3-K.SLX@A(B$2$9&!M+3TR&7RQ$>'HY__>M?S+9,GCP9GW[Z MJ<"PBXB(P,R9,W'???=AV[9M(H]`1T<'BHJ*!(("`&)B8@0>*7-$1T?OII)"0DH+:VUNJ\Y@L'3KG$Q<7AZ:>?EC0>FIN;X>GI*1H;KB_F_(R/ MC\?1HT>A5JL%WEU^.[R]O7'QXD6:)Y/))#W!EHP42PK%4KZ#@P/UBEE39-UE M@'+&Y[???FLS/4((WGOO/2B52JQ:M4K4]PL7+F#\^/$"&@:#`1$1$:+-->M] M1XX

VWWT[31XT:)2BGT6C0UM8FJ-/G"\:VLP;HKEV[<.^]]])-S6>??4;SA@X=BG__^]\@A.#@P8.B_JU?OQY! M04'XX(,/1.]C!DSL&G3)NAT.FS>O%G0C\3$1%155<%H-.+KK[_&U*E3 M;>+9E"E3Z,9IQXX=HGG]S#//0*O5,J-97=D`OOKJJTA/3V?*&JGYN6#!`KB[ MNR,Y.5FT^7WNN>?0VMHJ:F=:6AK5"9]^^BGNO_]^0;W\_'RJ`_B1RBE3IF#/ MGCW0Z70H*BIB]F/2I$DX?ORX8&Z[N;DA.3D9'1T=V+]_/U0JE>JG;C,RNV#U\_6>NHI%!04"+PX5ZY<06!@(*JJ MJCK5<1<7%QJ",C=Z^=X'#A45%_?W^JI`'@\<??(*$A`21)X4S0`L* M"D2>#6]O;YA,)D1'1Z.LK(SI`=VZ=2LF3)@@,$#M529=\8#R#5YN7H>&AG9I M?O*/M[!H:#0:9&9FXKWWWK/+`#U__CP((3ATZ!"S[^/&C>'AX0(Z MY@8I7P:4E)30]*BH*)&1U-#0()(%PX8-$T60.,_HNG7KF%YZ>PW0CHX.#!@P M`'5U=5BY,?!U=55,"_,CZ))\4RA4%":C8V-HG;RO/,AUI+[WT$I8M6R9*OW+E"M/NL65. MN+BXB-KRX89GQ&Z]]5:1$6V^4S=_[_[]^W';;;<)\MY^^VWF MPN=[$@!0`XP+<7I[>TNV=?;LV5WB<7M[.[*RLJ#1:/#33S]UV@.:E97%](`J ME4J1HC8/P3LZ.M*\%UYX0?`^OO'-'U.#P2#P&#@Y.4F>1S4_/\D*P=LKE`8, M&$`]XE)&K;T*T!J-[[__'@"P>/%B%!<7VU37%N-[_?KU6+ERI2!OX<*%@GKF M$1$IOBQ>O%CP/'?N7'I>FU]GU:I5M#_FZ.CH$$4YI-[IXN)"Y51;6YM@+@%` M9F8F\O+R1)N_]/1T>B1AVK1I`N5175V-Z=.GTQ`\2^ZRVG+BQ`GX^_L+YH4] MLK.PL)`9TK^9LC<@(``;-VY$:VLK&AH:)`T[K58KT'%RN1S7KEUCTG1W=YPQ0_CC88H!*P60R MH;Z^'BM6K+#J`>7>P4\W&HV"Y\K*2J2FID*GTV'(D"%T(PH`CSWV&!8L6`!" M")8N78HQ8\;0O%.G3B$R,A()"0G,J/',F3.Q8<,&S)PY$UNV;!'D96=GX^67 M7V;V3Z/1",YLVS,G$A,317IX]NS9:&EI07Y^/KR\O+!CQPZK^N^&K6#^V4_S M<(Y*I:*[2JDP"^LRDIN;&_;OWX\WWWP3(2$A5L\(F2,L+(PY@)9"\+9Z>KW5=F[=NA5' MCAQAEGG\\<>I82H5MF'5BXF)P>NOOXZFIB9!O8*"`@0$!%"/06MK*_/<[<,/ M/XR-&S<*TH*#@^FDU6JU"`X.IGE\Y;9DR1)LWKS9)GYR MSO322N'##S^T>`;4WCED-!KAY^>'7;MVT=VCEY<7W5Q8NH24F9F)%U]\$<#_ MA5[Y\YNK5U96AN#@X"Y=0N*P:-$BO/;::W1G[>#@T&4%R,D'UOSCEZ^OKQ>< M?^VJ`=K8V(C8V%A!WMMOOXWR\G+H]7H<.'"`ANFM\>7]]]]'<7$Q]'H]OO[Z M:V@T&F8=D\DD.(/FYN:&N7/GXNS9LR@I*6$>(V&],SX^'ILV;8+!8,"F39MP M]]UW"_)__/%'#!\^7&3L+EBP`'Y^?B"$P-?7EQK<1J,1#SWT$-W,-#0T""XA M66I+3$P,=N[<:?=+0O`+%RY$04&!I/%J M*03__OOO`P"V;-ER4PQ0SK$0'Q_/-$*[TP!-34VEY_'S\_-%(?C=NW?3$#S? M&6)+")X%E4J%JJHJF$PFIOSA9)->K\?NW;LQSO(\H"N7;L6[N[NN.>>>_#FFV_:+8"RLK*H,N>CH*!`Y.&P%5)' M$U:O7@V93":ZN6P+GUG*)C>5EY=# MK5:C5Z]>%C<*YG7_\Y__8,R8,7!T=!35R\G)09\^?>#FYH9QX\;1V[-\A(2$ MB#PF_,LYYC35:C6\O;TQ>O1HYDY/BI_<'`T-#66&#CE#)#4U%;-FS;(Z;K;< M@A\R9(C@?*"Y,..,M[2T-"9OI0ZNL_AB,!B0F9F)6VZY!<.'#T=%186(!NLV MOJ7Y8NG8B$ZG0TI*"E0J%8*"@JBRL-0'`/0K"MS/P8,'1>-NJ9T+BPOBXN($X2=+?#&93$A/3P2"$(#@X&(00*K,]/#Q$7]60R^6",XV6+JK80]NS9(^#-]>O7,7WZ=#@[.R,T-!1+EBRQB9_<):0!`P8(+C9U9@VP MP#_2PZK/W]#8LOXL_;#:65]?#XU&`P\/#TR8,$%P7(7;"`P8,`"1D9',2TB! M@8%T_&SA9U14%)8O7PZ%0L'4?_Q+2LG)R3AQX@1-=W)R0G1T-,K+RT5TUZ]? M#[E<+KIO7AX")QP/M1N'DR9/,SS`]^NBCS,\P=06)B8DV&2ZV MP&@TPM_?O]MN=?;@5X]X>7FYU7*L,T*=*6-IL\49V+Z^OLS0Q1\%7!BP![^B MHJ("A!`H%`KF!N1_%;8HL>KJ:N3FYO[FQY_^*#"93/C\\\]%QYVZJC?-+P/_ MT>;1GWG.-#0TP-?7%]>O7[>[KEPNE_QZB?FQ`_X&JKL^0^5XHSYP>N;,&4(( M(:=.G9(LT]#0<%,_NAH2$D+UF5%55V51.+I=W2QDI)"4E$;U>_Z?@J:NK:\_$,D-@8"!!SS^< ML_B1]V_;.1_T6<.'&"A(6%$0<'!Y*0D$#V[MW;99H>'AY$ MJ]42;V]OLF;-FM_U_)')9%;7F#UE_VCKA_L'$?;V:]>N763TZ-%,^T+JGS*, M&3.&[-NWKWO:CQ[)V(,>]*`'/?B3PL/#@UR_?IV9WM34U,.@'O3@-\)_`=B[ 20^7"G4ZF`````$E%3D2N0F"" ` end debian/font/egemb_font.h0000644000000000000000000006117711455320607012431 0ustar static const UINT8 egemb_font_data[4118] = { 0xf7, 0x00, 0x00, 0x05, 0xe3, 0x00, 0x04, 0x51, 0xfa, 0xff, 0xfa, 0x51, 0xff, 0x00, 0xff, 0x00, 0xff, 0x00, 0xbb, 0x00, 0x00, 0xe4, 0x81, 0x00, 0x04, 0xff, 0xcf, 0x00, 0xff, 0xcf, 0x80, 0x00, 0x03, 0x16, 0xda, 0x16, 0xda, 0x81, 0x00, 0x00, 0xef, 0x81, 0x00, 0x02, 0x51, 0xf5, 0x51, 0x8a, 0x00, 0x00, 0xff, 0x84, 0x00, 0x00, 0x87, 0x81, 0x00, 0x00, 0x87, 0x84, 0x00, 0x00, 0xf2, 0xa0, 0x00, 0x0d, 0x05, 0xdb, 0x09, 0x00, 0x3e, 0xaf, 0xe0, 0xfa, 0x51, 0x00, 0x00, 0x2e, 0x80, 0xed, 0x81, 0x00, 0x0b, 0x59, 0xfd, 0xff, 0xfa, 0x51, 0x00, 0x00, 0x2b, 0xa6, 0xf7, 0xfa, 0x51, 0x81, 0x00, 0x02, 0x48, 0xff, 0xff, 0x80, 0x00, 0x80, 0xff, 0x00, 0xef, 0x80, 0x00, 0x05, 0x5d, 0xfd, 0xff, 0xd2, 0x00, 0x00, 0x81, 0xff, 0x0e, 0xfc, 0x00, 0x00, 0x44, 0xfa, 0xff, 0xfa, 0x44, 0x00, 0x00, 0x51, 0xfa, 0xff, 0xff, 0x7d, 0x91, 0x00, 0x00, 0x09, 0x85, 0x00, 0x00, 0x09, 0x8b, 0x00, 0x04, 0xfa, 0x51, 0x00, 0x51, 0xfa, 0x80, 0x00, 0x01, 0xff, 0xd7, 0x80, 0x00, 0x81, 0xff, 0x09, 0xfa, 0x51, 0x00, 0x00, 0x0f, 0xba, 0xf2, 0xb8, 0xe9, 0x00, 0x80, 0xff, 0x03, 0xfa, 0x51, 0x00, 0x00, 0x83, 0xff, 0x01, 0x00, 0x00, 0x83, 0xff, 0x06, 0x00, 0x0d, 0xb2, 0xdf, 0xc8, 0xe7, 0x00, 0x80, 0xff, 0x00, 0x00, 0x80, 0xff, 0x01, 0x00, 0x79, 0x80, 0xff, 0x00, 0x67, 0x80, 0x00, 0x81, 0xff, 0x00, 0x00, 0x80, 0xff, 0x00, 0x00, 0x80, 0xff, 0x00, 0x00, 0x80, 0xff, 0x80, 0x00, 0x04, 0xff, 0xff, 0xdc, 0x00, 0xb9, 0x81, 0xff, 0x01, 0xad, 0x00, 0x80, 0xff, 0x07, 0x00, 0x30, 0xd2, 0xf8, 0xbd, 0x2b, 0x00, 0x00, 0x80, 0xff, 0x09, 0xd7, 0x2f, 0x00, 0x00, 0x10, 0xbe, 0xf9, 0xe0, 0x59, 0x00, 0x80, 0xff, 0x0a, 0xfc, 0xc1, 0x1f, 0x00, 0x00, 0x47, 0xdf, 0xf1, 0x70, 0xe5, 0x00, 0x87, 0xff, 0x00, 0x00, 0x83, 0xff, 0x00, 0x00, 0x83, 0xff, 0x00, 0x00, 0x80, 0xff, 0x01, 0xef, 0xf2, 0x80, 0x00, 0x01, 0xf2, 0xef, 0x80, 0xff, 0x00, 0x00, 0x80, 0xff, 0x00, 0x00, 0x82, 0xff, 0x80, 0x00, 0x80, 0xff, 0x04, 0x00, 0x00, 0x01, 0x7c, 0x1f, 0x83, 0x00, 0x80, 0xff, 0x82, 0x00, 0x00, 0x33, 0x8a, 0x00, 0x01, 0x96, 0x11, 0x86, 0x00, 0x01, 0xff, 0xff, 0x8d, 0x00, 0x01, 0xff, 0xff, 0x87, 0x00, 0x03, 0x51, 0xfa, 0xf5, 0xc3, 0x85, 0x00, 0x01, 0xff, 0xff, 0x85, 0x00, 0x00, 0xff, 0x83, 0x00, 0x00, 0xff, 0x80, 0x00, 0x01, 0xff, 0xff, 0x84, 0x00, 0x01, 0xff, 0xff, 0xe5, 0x00, 0x01, 0x2d, 0xd6, 0x82, 0x00, 0x00, 0xef, 0x82, 0x00, 0x01, 0xd7, 0x50, 0x98, 0x00, 0x00, 0xff, 0x81, 0x00, 0x04, 0xff, 0x6d, 0x00, 0xff, 0x6d, 0x80, 0x00, 0x09, 0x71, 0x90, 0x71, 0x90, 0x00, 0x00, 0x51, 0xfa, 0xff, 0xec, 0x80, 0x00, 0x02, 0xf5, 0xff, 0xf5, 0x8a, 0x00, 0x00, 0xff, 0x83, 0x00, 0x01, 0x25, 0x95, 0x81, 0x00, 0x01, 0x95, 0x22, 0x81, 0x00, 0x04, 0xaf, 0x98, 0xff, 0x98, 0xae, 0x81, 0x00, 0x00, 0xed, 0x99, 0x00, 0x08, 0x67, 0x97, 0x00, 0x00, 0xd9, 0x13, 0x00, 0x3a, 0xf4, 0x81, 0x00, 0x00, 0xff, 0x81, 0x00, 0x0b, 0xef, 0x49, 0x00, 0x51, 0xfa, 0x00, 0x00, 0xbe, 0x37, 0x02, 0x51, 0xfa, 0x80, 0x00, 0x03, 0x03, 0xd0, 0x2b, 0xff, 0x80, 0x00, 0x00, 0xff, 0x82, 0x00, 0x02, 0x55, 0x9c, 0x0b, 0x81, 0x00, 0x13, 0xff, 0x00, 0x00, 0x16, 0xe4, 0x00, 0x00, 0xe6, 0x19, 0x00, 0x19, 0xe6, 0x00, 0x00, 0xfa, 0x51, 0x00, 0x08, 0x5c, 0x01, 0x8e, 0x00, 0x02, 0x10, 0xa5, 0x9d, 0x85, 0x00, 0x02, 0xa3, 0xa6, 0x10, 0x83, 0x00, 0x06, 0x51, 0xfa, 0xfa, 0x51, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x80, 0x00, 0x02, 0x06, 0xbc, 0x30, 0x80, 0x00, 0x15, 0xff, 0x00, 0x00, 0x51, 0xfa, 0x00, 0x00, 0x8e, 0x73, 0x08, 0x38, 0xf3, 0x00, 0x00, 0xff, 0x00, 0x3d, 0xe0, 0x51, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x80, 0x00, 0x09, 0xff, 0x00, 0x8d, 0x78, 0x01, 0x3d, 0xf1, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x81, 0x00, 0x00, 0xff, 0x84, 0x00, 0x00, 0xff, 0x80, 0x00, 0x08, 0xff, 0x00, 0x00, 0x0f, 0xb8, 0x34, 0x00, 0x00, 0xff, 0x82, 0x00, 0x12, 0xff, 0xdf, 0x1e, 0xd3, 0xff, 0x00, 0x00, 0xff, 0xca, 0x0f, 0x00, 0xff, 0x00, 0x00, 0xa3, 0x2d, 0x06, 0x3f, 0xce, 0x80, 0x00, 0x22, 0xff, 0x00, 0x31, 0xcb, 0x00, 0x00, 0x7c, 0x53, 0x07, 0x4d, 0xdd, 0x00, 0x00, 0xff, 0x00, 0x05, 0x7d, 0xc2, 0x00, 0x00, 0xe6, 0x2c, 0x05, 0x47, 0xf2, 0x00, 0xff, 0x00, 0x00, 0xff, 0x00, 0x00, 0xff, 0x00, 0xff, 0x80, 0x00, 0x23, 0xff, 0x00, 0x12, 0xe6, 0x06, 0x00, 0x01, 0xe1, 0x06, 0x05, 0xf6, 0x00, 0x00, 0x01, 0xf7, 0x03, 0x16, 0xbd, 0x10, 0x00, 0x10, 0x9b, 0x02, 0x00, 0xb4, 0x44, 0x00, 0x44, 0xb4, 0x00, 0x00, 0xff, 0x00, 0x00, 0x51, 0xc7, 0x80, 0x00, 0x00, 0xff, 0x82, 0x00, 0x01, 0x06, 0x6e, 0x85, 0x00, 0x00, 0xff, 0x81, 0x00, 0x02, 0x4d, 0xf2, 0x4d, 0x89, 0x00, 0x01, 0x12, 0x96, 0x87, 0x00, 0x00, 0xff, 0x8e, 0x00, 0x00, 0xff, 0x80, 0x00, 0x01, 0x03, 0x04, 0x82, 0x00, 0x01, 0xfa, 0x51, 0x88, 0x00, 0x00, 0xff, 0x91, 0x00, 0x00, 0xff, 0x85, 0x00, 0x00, 0xff, 0xb3, 0x00, 0x00, 0xf6, 0xae, 0x00, 0x01, 0xda, 0x1f, 0x82, 0x00, 0x00, 0xff, 0x82, 0x00, 0x01, 0x21, 0xf6, 0x89, 0x00, 0x03, 0x51, 0xfa, 0xfa, 0x51, 0x88, 0x00, 0x00, 0xff, 0x81, 0x00, 0x04, 0xea, 0x12, 0x00, 0xea, 0x12, 0x80, 0x00, 0x07, 0xd0, 0x30, 0xd0, 0x30, 0x00, 0x00, 0xeb, 0x1f, 0x82, 0x00, 0x02, 0x51, 0xf5, 0x51, 0x82, 0x00, 0x03, 0x6b, 0xe6, 0xc9, 0x3d, 0x81, 0x00, 0x00, 0xff, 0x83, 0x00, 0x01, 0x8a, 0x4f, 0x81, 0x00, 0x01, 0x52, 0x89, 0x81, 0x00, 0x04, 0x16, 0x67, 0xf6, 0x87, 0x16, 0x81, 0x00, 0x00, 0xff, 0x98, 0x00, 0x05, 0x06, 0xdc, 0x1e, 0x00, 0x00, 0xdd, 0x80, 0x00, 0x00, 0xff, 0x81, 0x00, 0x00, 0xff, 0x84, 0x00, 0x01, 0x04, 0xc9, 0x81, 0x00, 0x02, 0x02, 0x4d, 0xce, 0x80, 0x00, 0x03, 0x66, 0x99, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x82, 0x00, 0x00, 0x99, 0x86, 0x00, 0x0b, 0x63, 0x99, 0x00, 0x00, 0xec, 0x23, 0x00, 0x12, 0xea, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0x87, 0x80, 0x00, 0x01, 0xca, 0xca, 0x83, 0x00, 0x01, 0xca, 0xca, 0x81, 0x00, 0x02, 0x41, 0xcf, 0x53, 0x87, 0x00, 0x02, 0x5a, 0xd2, 0x41, 0x82, 0x00, 0x0a, 0xed, 0x51, 0x51, 0xfa, 0x00, 0x00, 0xff, 0x00, 0x51, 0xfa, 0xff, 0x80, 0x00, 0x02, 0x56, 0x78, 0x83, 0x80, 0x00, 0x08, 0xff, 0x00, 0x02, 0x4d, 0xbc, 0x00, 0x00, 0xe2, 0x15, 0x82, 0x00, 0x09, 0xff, 0x00, 0x00, 0x15, 0xfa, 0x00, 0x00, 0xff, 0x00, 0xff, 0x82, 0x00, 0x02, 0xff, 0x00, 0xff, 0x80, 0x00, 0x01, 0xe0, 0x1d, 0x82, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x81, 0x00, 0x00, 0xff, 0x84, 0x00, 0x00, 0xff, 0x80, 0x00, 0x04, 0xff, 0x00, 0x0f, 0xb9, 0x35, 0x80, 0x00, 0x00, 0xff, 0x82, 0x00, 0x0e, 0xff, 0xa0, 0x88, 0xaa, 0xff, 0x00, 0x00, 0xff, 0x77, 0x64, 0x00, 0xff, 0x00, 0x00, 0x98, 0x80, 0x00, 0x00, 0xad, 0x80, 0x00, 0x06, 0xff, 0x00, 0x01, 0xf8, 0x00, 0x00, 0x85, 0x80, 0x00, 0x0c, 0x91, 0x0a, 0x00, 0xff, 0x00, 0x00, 0x06, 0xf7, 0x00, 0x00, 0xe3, 0x54, 0x07, 0x83, 0x00, 0x00, 0xff, 0x81, 0x00, 0x00, 0xff, 0x80, 0x00, 0x1c, 0xff, 0x00, 0x00, 0xad, 0x52, 0x00, 0x25, 0x9f, 0x00, 0x00, 0xeb, 0x10, 0x00, 0x14, 0xe8, 0x00, 0x00, 0x37, 0xb3, 0x08, 0xab, 0x1f, 0x00, 0x00, 0x24, 0xc4, 0x02, 0xc4, 0x23, 0x81, 0x00, 0x02, 0x18, 0xe0, 0x24, 0x80, 0x00, 0x00, 0xff, 0x83, 0x00, 0x01, 0x70, 0x04, 0x84, 0x00, 0x00, 0xff, 0x80, 0x00, 0x04, 0x26, 0xcd, 0x22, 0xcd, 0x26, 0x8e, 0x00, 0x22, 0x9f, 0xe9, 0xd9, 0x55, 0x00, 0x00, 0xff, 0x36, 0xe6, 0xcf, 0x1e, 0x00, 0x00, 0x1a, 0xc6, 0xf5, 0x77, 0xe3, 0x00, 0x00, 0x1d, 0xcc, 0xe8, 0x44, 0xff, 0x00, 0x00, 0x29, 0xe8, 0xfc, 0xbf, 0x18, 0x00, 0x00, 0xf5, 0x81, 0xff, 0x12, 0x00, 0x00, 0x1f, 0xce, 0xe7, 0x3f, 0xff, 0xff, 0x00, 0xff, 0x42, 0xe4, 0xfa, 0x51, 0x00, 0x00, 0x33, 0xff, 0xff, 0x81, 0x00, 0x81, 0xff, 0x80, 0x00, 0x01, 0xff, 0x00, 0x80, 0xff, 0x81, 0x00, 0x00, 0xff, 0x80, 0x00, 0x32, 0xff, 0xff, 0x99, 0x3a, 0xa1, 0x51, 0x00, 0xff, 0xff, 0x6d, 0xec, 0xfa, 0x51, 0x00, 0x00, 0x13, 0xb3, 0xe6, 0xb2, 0x12, 0x00, 0xff, 0xff, 0x46, 0xe7, 0xcb, 0x1f, 0x00, 0x00, 0x1f, 0xc8, 0xdf, 0x3a, 0xff, 0xff, 0x00, 0xff, 0xff, 0x29, 0xd6, 0x95, 0x00, 0x00, 0x51, 0xfa, 0xf4, 0x80, 0xdb, 0x00, 0x00, 0xf2, 0x81, 0xff, 0x07, 0x00, 0xff, 0xff, 0x00, 0x00, 0xff, 0xff, 0x00, 0x80, 0xff, 0x00, 0x00, 0x83, 0xff, 0x00, 0x00, 0x80, 0xff, 0x06, 0xee, 0xf2, 0x00, 0x00, 0xf4, 0xed, 0x00, 0x80, 0xff, 0x04, 0x00, 0xff, 0xff, 0xec, 0x00, 0x82, 0xff, 0x00, 0x10, 0x80, 0x00, 0x00, 0xff, 0x83, 0x00, 0x00, 0xff, 0x83, 0x00, 0x00, 0xff, 0x89, 0x00, 0x03, 0xed, 0x51, 0x51, 0xfa, 0x88, 0x00, 0x00, 0xff, 0x88, 0x00, 0x00, 0xf2, 0x80, 0xff, 0x05, 0xf3, 0x00, 0x00, 0xb7, 0x80, 0x1d, 0x81, 0x00, 0x04, 0x07, 0x3c, 0x78, 0xb5, 0xe6, 0x80, 0x00, 0x03, 0xf5, 0x22, 0x23, 0x07, 0x81, 0x00, 0x00, 0xe1, 0x83, 0x00, 0x01, 0xd2, 0x1e, 0x81, 0x00, 0x01, 0x20, 0xd2, 0x82, 0x00, 0x02, 0x91, 0xaf, 0xa6, 0x82, 0x00, 0x00, 0xff, 0x98, 0x00, 0x01, 0x6b, 0x9a, 0x80, 0x00, 0x00, 0xf9, 0x80, 0x00, 0x00, 0xff, 0x81, 0x00, 0x00, 0xff, 0x84, 0x00, 0x01, 0x47, 0x14, 0x81, 0x00, 0x09, 0xf2, 0xc5, 0x19, 0x00, 0x00, 0x0c, 0xdb, 0x17, 0x00, 0xff, 0x80, 0x00, 0x0a, 0xf8, 0xff, 0xfa, 0x51, 0x00, 0x00, 0x91, 0xa2, 0xf5, 0xd1, 0x57, 0x82, 0x00, 0x0f, 0xb1, 0x4b, 0x00, 0x00, 0x5a, 0xcf, 0xa7, 0xa9, 0x58, 0x00, 0x00, 0xfa, 0x51, 0x04, 0x4d, 0xdb, 0x80, 0x00, 0x01, 0xcb, 0xcb, 0x83, 0x00, 0x07, 0xcc, 0xcc, 0x00, 0x00, 0x07, 0x8c, 0xb8, 0x1a, 0x81, 0x00, 0x00, 0xf2, 0x80, 0xff, 0x00, 0xf2, 0x80, 0x00, 0x03, 0x1d, 0xbc, 0x8c, 0x07, 0x82, 0x00, 0x08, 0x0c, 0xee, 0x00, 0x00, 0xff, 0x00, 0xfa, 0x51, 0xff, 0x80, 0x00, 0x05, 0xba, 0x31, 0xc4, 0x01, 0x00, 0x00, 0x80, 0xff, 0x05, 0xe7, 0x1c, 0x00, 0x00, 0xfe, 0x01, 0x82, 0x00, 0x00, 0xff, 0x80, 0x00, 0x02, 0xff, 0x00, 0x00, 0x80, 0xff, 0x82, 0x00, 0x80, 0xff, 0x80, 0x00, 0x01, 0xfd, 0x02, 0x82, 0x00, 0x82, 0xff, 0x81, 0x00, 0x00, 0xff, 0x84, 0x00, 0x00, 0xff, 0x80, 0x00, 0x03, 0xff, 0x0f, 0xb9, 0x36, 0x81, 0x00, 0x00, 0xff, 0x82, 0x00, 0x0e, 0xff, 0x60, 0xf1, 0x71, 0xff, 0x00, 0x00, 0xff, 0x1d, 0xbd, 0x00, 0xff, 0x00, 0x03, 0xcf, 0x80, 0x00, 0x00, 0xd0, 0x80, 0x00, 0x06, 0xff, 0x00, 0x32, 0xd4, 0x00, 0x00, 0xc5, 0x80, 0x00, 0x0e, 0xb9, 0x08, 0x00, 0xff, 0x00, 0x0c, 0x5e, 0xb1, 0x00, 0x00, 0x2a, 0xab, 0xee, 0xa2, 0x1c, 0x81, 0x00, 0x00, 0xff, 0x81, 0x00, 0x00, 0xff, 0x80, 0x00, 0x0e, 0xff, 0x00, 0x00, 0x4e, 0xb2, 0x00, 0x56, 0x4a, 0x00, 0x00, 0xd3, 0x39, 0xff, 0x3c, 0xd0, 0x80, 0x00, 0x02, 0x65, 0xdc, 0x5a, 0x81, 0x00, 0x02, 0x86, 0xa6, 0x85, 0x82, 0x00, 0x01, 0xb6, 0x66, 0x81, 0x00, 0x00, 0xff, 0x83, 0x00, 0x01, 0x23, 0x51, 0x84, 0x00, 0x00, 0xff, 0x80, 0x00, 0x04, 0xc4, 0x2d, 0x00, 0x2d, 0xc4, 0x8e, 0x00, 0x1f, 0x0d, 0x01, 0x35, 0xf8, 0x00, 0x00, 0xff, 0x64, 0x0b, 0x76, 0xb0, 0x00, 0x00, 0xad, 0x81, 0x0b, 0x42, 0xf0, 0x00, 0x00, 0xaa, 0x61, 0x06, 0x5f, 0xff, 0x00, 0x00, 0xb6, 0x29, 0x02, 0x3b, 0xaf, 0x80, 0x00, 0x00, 0xff, 0x82, 0x00, 0x0b, 0xb0, 0x64, 0x00, 0x54, 0xff, 0x00, 0x00, 0xff, 0x8a, 0x0b, 0x51, 0xfa, 0x81, 0x00, 0x00, 0xff, 0x84, 0x00, 0x00, 0xff, 0x80, 0x00, 0x04, 0xff, 0x00, 0x75, 0xa2, 0x01, 0x81, 0x00, 0x00, 0xff, 0x81, 0x00, 0x20, 0xff, 0x89, 0xf2, 0xad, 0xfa, 0x00, 0x00, 0xff, 0x85, 0x09, 0x51, 0xfa, 0x00, 0x00, 0xa5, 0x4b, 0x00, 0x4b, 0xa4, 0x00, 0x00, 0xff, 0x53, 0x04, 0x4d, 0xae, 0x00, 0x00, 0xb0, 0x45, 0x06, 0x4d, 0xff, 0x80, 0x00, 0x0a, 0xff, 0xb3, 0x2b, 0x5a, 0x00, 0x00, 0xf3, 0xad, 0x04, 0x40, 0xef, 0x80, 0x00, 0x00, 0xff, 0x82, 0x00, 0x00, 0xff, 0x80, 0x00, 0x23, 0xff, 0x00, 0x05, 0xe1, 0x0c, 0x00, 0x0d, 0xdd, 0x0e, 0x02, 0xef, 0x03, 0x00, 0x00, 0xe6, 0x16, 0x1f, 0xb6, 0x1a, 0x2a, 0xcc, 0x21, 0x00, 0x02, 0xca, 0x2d, 0x00, 0x00, 0xbb, 0x49, 0x00, 0xff, 0x00, 0x00, 0x7d, 0x7e, 0x81, 0x00, 0x00, 0xff, 0x83, 0x00, 0x00, 0xff, 0x83, 0x00, 0x00, 0xff, 0x8b, 0x00, 0x01, 0x0c, 0xee, 0x88, 0x00, 0x00, 0xee, 0x89, 0x00, 0x02, 0xff, 0x00, 0xff, 0x80, 0x00, 0x03, 0x02, 0x45, 0xaa, 0x9d, 0x80, 0x00, 0x09, 0x9a, 0xca, 0x8e, 0x52, 0x15, 0x00, 0x00, 0x13, 0xde, 0x29, 0x8a, 0x00, 0x01, 0xf7, 0x06, 0x81, 0x00, 0x01, 0x07, 0xf7, 0x81, 0x00, 0x06, 0x2c, 0x80, 0x02, 0xd3, 0x23, 0x00, 0xec, 0x82, 0xff, 0x00, 0xec, 0x85, 0x00, 0x82, 0xff, 0x87, 0x00, 0x02, 0x08, 0xe0, 0x20, 0x80, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x81, 0x00, 0x00, 0xff, 0x83, 0x00, 0x01, 0x48, 0x18, 0x82, 0x00, 0x09, 0x09, 0x84, 0x89, 0x00, 0x00, 0x83, 0x7b, 0x00, 0x00, 0xff, 0x82, 0x00, 0x08, 0x1e, 0xfa, 0x00, 0x15, 0xef, 0x88, 0x0e, 0x03, 0x58, 0x81, 0x00, 0x10, 0x09, 0xea, 0x08, 0x00, 0x00, 0x93, 0x29, 0x00, 0x19, 0x92, 0x00, 0x00, 0x51, 0xfa, 0xf7, 0xb0, 0xa4, 0x8c, 0x00, 0x02, 0xa5, 0xc0, 0x02, 0x8b, 0x00, 0x02, 0x03, 0xc4, 0xa4, 0x81, 0x00, 0x1a, 0x4c, 0xb8, 0x55, 0x00, 0x00, 0xff, 0x00, 0xfa, 0x52, 0xff, 0x00, 0x00, 0x1f, 0xe7, 0x01, 0xcc, 0x3a, 0x00, 0x00, 0xff, 0x00, 0x02, 0x5c, 0xb7, 0x00, 0x00, 0xfe, 0x83, 0x00, 0x00, 0xff, 0x80, 0x00, 0x05, 0xff, 0x00, 0x00, 0xff, 0x00, 0xff, 0x82, 0x00, 0x02, 0xff, 0x00, 0xff, 0x80, 0x00, 0x07, 0xfe, 0x01, 0x00, 0xff, 0xff, 0xd8, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x81, 0x00, 0x00, 0xff, 0x81, 0x00, 0x03, 0xed, 0x00, 0x00, 0xff, 0x80, 0x00, 0x03, 0xff, 0xb9, 0x8f, 0x60, 0x81, 0x00, 0x00, 0xff, 0x82, 0x00, 0x0e, 0xff, 0x20, 0xff, 0x38, 0xff, 0x00, 0x00, 0xff, 0x00, 0xbe, 0x1c, 0xff, 0x00, 0x00, 0xd1, 0x80, 0x00, 0x00, 0xcf, 0x80, 0x00, 0x06, 0xff, 0xff, 0xec, 0x42, 0x00, 0x00, 0xcd, 0x80, 0x00, 0x02, 0xc4, 0x11, 0x00, 0x80, 0xff, 0x01, 0xd2, 0x12, 0x81, 0x00, 0x02, 0x06, 0x66, 0xca, 0x81, 0x00, 0x00, 0xff, 0x81, 0x00, 0x00, 0xff, 0x80, 0x00, 0x0e, 0xff, 0x00, 0x00, 0x04, 0xe5, 0x16, 0x76, 0x06, 0x00, 0x00, 0xba, 0x72, 0xff, 0x74, 0xb8, 0x80, 0x00, 0x02, 0x5b, 0xdc, 0x5a, 0x81, 0x00, 0x02, 0x0b, 0xff, 0x0b, 0x81, 0x00, 0x01, 0x6a, 0xb3, 0x82, 0x00, 0x00, 0xff, 0x84, 0x00, 0x00, 0x75, 0x84, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0x03, 0x80, 0x00, 0x00, 0x03, 0x8d, 0x00, 0x0f, 0x3d, 0xd7, 0xfa, 0xcc, 0xff, 0x00, 0x00, 0xff, 0x14, 0x00, 0x0a, 0xf4, 0x00, 0x00, 0xf3, 0x0c, 0x82, 0x00, 0x07, 0xf1, 0x09, 0x00, 0x0b, 0xff, 0x00, 0x00, 0xf6, 0x80, 0xff, 0x00, 0xf5, 0x80, 0x00, 0x00, 0xff, 0x82, 0x00, 0x0b, 0xf4, 0x09, 0x00, 0x10, 0xff, 0x00, 0x00, 0xff, 0x04, 0x00, 0x00, 0xff, 0x81, 0x00, 0x00, 0xff, 0x84, 0x00, 0x00, 0xff, 0x80, 0x00, 0x03, 0xff, 0x91, 0xb4, 0x04, 0x82, 0x00, 0x00, 0xff, 0x81, 0x00, 0x07, 0xff, 0x00, 0xff, 0x01, 0xff, 0x00, 0x00, 0xff, 0x80, 0x00, 0x15, 0xff, 0x00, 0x00, 0xf3, 0x08, 0x00, 0x08, 0xf2, 0x00, 0x00, 0xff, 0x0c, 0x00, 0x07, 0xf2, 0x00, 0x00, 0xf4, 0x07, 0x00, 0x0a, 0xff, 0x80, 0x00, 0x01, 0xff, 0x0a, 0x81, 0x00, 0x04, 0x4d, 0xfa, 0xf7, 0xd8, 0x35, 0x80, 0x00, 0x00, 0xff, 0x82, 0x00, 0x00, 0xff, 0x80, 0x00, 0x14, 0xff, 0x00, 0x00, 0x8d, 0x55, 0x00, 0x74, 0x80, 0x00, 0x00, 0xc6, 0x39, 0xff, 0x27, 0xeb, 0x00, 0x00, 0x1d, 0xb8, 0xce, 0x24, 0x80, 0x00, 0x04, 0x3d, 0xc4, 0x01, 0x31, 0xd2, 0x81, 0x00, 0x01, 0x7e, 0x7c, 0x81, 0x00, 0x01, 0x13, 0xf7, 0x83, 0x00, 0x00, 0xff, 0x83, 0x00, 0x01, 0xf7, 0x24, 0x80, 0x00, 0x04, 0x59, 0xe8, 0x58, 0x0b, 0xa0, 0x81, 0x00, 0x02, 0x4c, 0xb8, 0x55, 0x94, 0x00, 0x00, 0xf4, 0x80, 0xff, 0x06, 0xf3, 0x00, 0x00, 0xef, 0x0f, 0x21, 0xf1, 0x82, 0x00, 0x09, 0x51, 0xf5, 0x51, 0x00, 0x00, 0xca, 0x3c, 0xc9, 0x8f, 0x1e, 0x88, 0x00, 0x01, 0xf8, 0x06, 0x81, 0x00, 0x01, 0x07, 0xf7, 0x84, 0x00, 0x01, 0x0c, 0x02, 0x81, 0x00, 0x00, 0xff, 0x97, 0x00, 0x01, 0x70, 0x9e, 0x81, 0x00, 0x00, 0xff, 0x80, 0x00, 0x01, 0xff, 0x03, 0x80, 0x00, 0x00, 0xff, 0x82, 0x00, 0x01, 0x62, 0x26, 0x84, 0x00, 0x04, 0x05, 0xf6, 0x00, 0x00, 0xe2, 0x81, 0xff, 0x00, 0xaf, 0x82, 0x00, 0x03, 0xff, 0x00, 0x40, 0xd5, 0x80, 0x00, 0x00, 0x69, 0x81, 0x00, 0x01, 0x4d, 0xb0, 0x80, 0x00, 0x04, 0xe7, 0x01, 0x00, 0x01, 0xe7, 0x83, 0x00, 0x00, 0xa1, 0x8c, 0x00, 0x03, 0x07, 0x8d, 0xb9, 0x1b, 0x81, 0x00, 0x00, 0xf2, 0x80, 0xff, 0x00, 0xf2, 0x80, 0x00, 0x03, 0x1d, 0xbc, 0x8d, 0x07, 0x81, 0x00, 0x01, 0xf1, 0x0b, 0x80, 0x00, 0x07, 0xff, 0x00, 0x51, 0xfa, 0xfb, 0x00, 0x00, 0x82, 0x80, 0xff, 0x0b, 0x92, 0x00, 0x00, 0xff, 0x00, 0x00, 0x03, 0xfa, 0x00, 0x00, 0xf9, 0x10, 0x82, 0x00, 0x07, 0xff, 0x00, 0x00, 0x0f, 0xfa, 0x00, 0x00, 0xff, 0x84, 0x00, 0x00, 0xff, 0x82, 0x00, 0x07, 0xe5, 0x17, 0x00, 0x00, 0xff, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x81, 0x00, 0x00, 0xff, 0x81, 0x00, 0x03, 0xff, 0x00, 0x00, 0xff, 0x80, 0x00, 0x04, 0xff, 0x33, 0x00, 0x84, 0x47, 0x80, 0x00, 0x06, 0xff, 0x00, 0x00, 0xff, 0x00, 0x00, 0xff, 0x80, 0x00, 0x0a, 0xff, 0x00, 0x00, 0xff, 0x00, 0x65, 0x76, 0xff, 0x00, 0x00, 0x88, 0x80, 0x00, 0x00, 0xa6, 0x80, 0x00, 0x00, 0xff, 0x82, 0x00, 0x00, 0x84, 0x80, 0x00, 0x07, 0x99, 0x13, 0x00, 0xff, 0x00, 0x00, 0x71, 0x33, 0x82, 0x00, 0x01, 0x04, 0xf9, 0x81, 0x00, 0x00, 0xff, 0x81, 0x00, 0x04, 0xf7, 0x02, 0x00, 0x08, 0xfb, 0x80, 0x00, 0x02, 0x8f, 0x70, 0x58, 0x80, 0x00, 0x0b, 0xa2, 0xaa, 0xff, 0xac, 0xa0, 0x00, 0x00, 0x1f, 0xab, 0x08, 0xab, 0x1e, 0x81, 0x00, 0x00, 0xff, 0x81, 0x00, 0x02, 0x27, 0xe0, 0x17, 0x82, 0x00, 0x00, 0xff, 0x84, 0x00, 0x01, 0x51, 0x23, 0x83, 0x00, 0x00, 0xff, 0x95, 0x00, 0x0f, 0xdf, 0x62, 0x09, 0x11, 0xff, 0x00, 0x00, 0xff, 0x04, 0x00, 0x0b, 0xf3, 0x00, 0x00, 0xf5, 0x0e, 0x82, 0x00, 0x07, 0xf2, 0x09, 0x00, 0x0b, 0xff, 0x00, 0x00, 0xc3, 0x84, 0x00, 0x00, 0xff, 0x82, 0x00, 0x07, 0xf4, 0x09, 0x00, 0x11, 0xff, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x81, 0x00, 0x00, 0xff, 0x84, 0x00, 0x00, 0xff, 0x80, 0x00, 0x03, 0xff, 0xa0, 0xcd, 0x13, 0x82, 0x00, 0x00, 0xff, 0x81, 0x00, 0x07, 0xff, 0x00, 0xff, 0x00, 0xff, 0x00, 0x00, 0xff, 0x80, 0x00, 0x15, 0xff, 0x00, 0x00, 0xf3, 0x08, 0x00, 0x08, 0xf2, 0x00, 0x00, 0xff, 0x0c, 0x00, 0x07, 0xf3, 0x00, 0x00, 0xf4, 0x07, 0x00, 0x0a, 0xff, 0x80, 0x00, 0x00, 0xff, 0x83, 0x00, 0x03, 0x01, 0x14, 0x77, 0xef, 0x80, 0x00, 0x00, 0xff, 0x80, 0x00, 0x1a, 0x07, 0x00, 0xff, 0x00, 0x00, 0x02, 0xff, 0x00, 0x00, 0x2a, 0xa6, 0x06, 0xd7, 0x11, 0x00, 0x00, 0x94, 0x89, 0xff, 0x7d, 0xc1, 0x00, 0x00, 0x25, 0xce, 0xb8, 0x1d, 0x81, 0x00, 0x03, 0xa7, 0x63, 0xa7, 0x5e, 0x80, 0x00, 0x01, 0x80, 0x7a, 0x82, 0x00, 0x01, 0xb9, 0xb4, 0x83, 0x00, 0x00, 0xff, 0x83, 0x00, 0x01, 0xb6, 0xe7, 0x80, 0x00, 0x04, 0xa1, 0x0a, 0x53, 0xe8, 0x54, 0x81, 0x00, 0x01, 0xf1, 0x0b, 0x95, 0x00, 0x03, 0x30, 0xd0, 0x30, 0xd0, 0x80, 0x00, 0x03, 0xef, 0xd7, 0xfa, 0x51, 0x82, 0x00, 0x09, 0xf5, 0xff, 0xf5, 0x00, 0x00, 0xf3, 0x40, 0x6c, 0xd9, 0x04, 0x88, 0x00, 0x01, 0xd6, 0x1d, 0x81, 0x00, 0x01, 0x20, 0xd2, 0x8a, 0x00, 0x00, 0xff, 0x82, 0x00, 0x02, 0x24, 0xff, 0xba, 0x88, 0x00, 0x01, 0xca, 0xca, 0x81, 0x00, 0x02, 0x09, 0xe4, 0x23, 0x81, 0x00, 0x05, 0xf6, 0x3a, 0x00, 0x35, 0xf1, 0x05, 0x80, 0x00, 0x00, 0xff, 0x81, 0x00, 0x0b, 0x5c, 0x32, 0x00, 0x00, 0xff, 0x00, 0x00, 0x93, 0x26, 0x00, 0x51, 0xfa, 0x83, 0x00, 0x0e, 0xff, 0x00, 0x00, 0xcb, 0x72, 0x0f, 0x51, 0xfa, 0x00, 0x52, 0xdf, 0x14, 0x00, 0x09, 0x89, 0x81, 0x00, 0x01, 0x9b, 0x62, 0x80, 0x00, 0x0b, 0xda, 0x0b, 0x00, 0x0b, 0xda, 0x00, 0x00, 0x17, 0x00, 0x00, 0x7f, 0x5f, 0x80, 0x00, 0x01, 0xca, 0xca, 0x82, 0x00, 0x02, 0x30, 0xff, 0xa1, 0x81, 0x00, 0x02, 0x42, 0xd1, 0x58, 0x87, 0x00, 0x02, 0x59, 0xd2, 0x41, 0x88, 0x00, 0x00, 0xff, 0x82, 0x00, 0x1d, 0x02, 0xe3, 0x4e, 0x00, 0x4c, 0xe8, 0x03, 0x00, 0xff, 0x00, 0x00, 0x51, 0xfa, 0x00, 0x00, 0x8f, 0x81, 0x00, 0x4e, 0xd2, 0x00, 0x00, 0xff, 0x00, 0x3a, 0xda, 0x51, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x82, 0x00, 0x07, 0x86, 0x73, 0x00, 0x13, 0xfd, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x81, 0x00, 0x00, 0xff, 0x81, 0x00, 0x03, 0xfa, 0x51, 0x51, 0xfa, 0x80, 0x00, 0x04, 0xff, 0x00, 0x00, 0x14, 0xbc, 0x80, 0x00, 0x06, 0xff, 0x00, 0x00, 0xff, 0x00, 0x00, 0xff, 0x80, 0x00, 0x0e, 0xff, 0x00, 0x00, 0xff, 0x00, 0x10, 0xca, 0xff, 0x00, 0x00, 0x69, 0x2e, 0x05, 0x3f, 0xbd, 0x80, 0x00, 0x00, 0xff, 0x82, 0x00, 0x12, 0x5d, 0x47, 0x05, 0x3b, 0xb9, 0x00, 0x00, 0xff, 0x00, 0x00, 0x01, 0x95, 0x00, 0x00, 0xf3, 0x99, 0x22, 0x42, 0xcb, 0x81, 0x00, 0x00, 0xff, 0x81, 0x00, 0x04, 0xba, 0x61, 0x03, 0x61, 0xbf, 0x80, 0x00, 0x02, 0x2f, 0xd0, 0x33, 0x80, 0x00, 0x0c, 0x89, 0xe3, 0xff, 0xe4, 0x88, 0x00, 0x02, 0x9c, 0x10, 0x00, 0x11, 0x9b, 0x02, 0x80, 0x00, 0x00, 0xff, 0x81, 0x00, 0x04, 0xcb, 0x50, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x84, 0x00, 0x01, 0x05, 0x70, 0x83, 0x00, 0x00, 0xff, 0x95, 0x00, 0x1e, 0xeb, 0x34, 0x0f, 0x74, 0xff, 0x00, 0x00, 0xff, 0x35, 0x06, 0x77, 0xae, 0x00, 0x00, 0xb0, 0x65, 0x03, 0x41, 0xa9, 0x00, 0x00, 0xac, 0x5f, 0x05, 0x5f, 0xff, 0x00, 0x00, 0x88, 0x52, 0x0e, 0x82, 0x00, 0x00, 0xff, 0x82, 0x00, 0x07, 0xb0, 0x5d, 0x00, 0x5e, 0xff, 0x00, 0x00, 0xff, 0x80, 0x00, 0x00, 0xff, 0x81, 0x00, 0x00, 0xff, 0x84, 0x00, 0x00, 0xff, 0x80, 0x00, 0x04, 0xff, 0x00, 0x40, 0xba, 0x13, 0x81, 0x00, 0x00, 0xff, 0x81, 0x00, 0x07, 0xff, 0x00, 0xff, 0x00, 0xff, 0x00, 0x00, 0xff, 0x80, 0x00, 0x15, 0xff, 0x00, 0x00, 0xa6, 0x53, 0x00, 0x53, 0xa4, 0x00, 0x00, 0xff, 0x49, 0x04, 0x4d, 0xaf, 0x00, 0x00, 0xb0, 0x45, 0x06, 0x4d, 0xff, 0x80, 0x00, 0x00, 0xff, 0x82, 0x00, 0x04, 0xef, 0x29, 0x01, 0x51, 0xfa, 0x80, 0x00, 0x0a, 0xfa, 0x51, 0x05, 0x49, 0xc6, 0x00, 0xfa, 0x51, 0x19, 0x92, 0xff, 0x80, 0x00, 0x02, 0xb9, 0x6a, 0x86, 0x80, 0x00, 0x0b, 0x63, 0xd8, 0xff, 0xd4, 0x97, 0x00, 0x21, 0xcd, 0x2a, 0x1a, 0xb6, 0x1f, 0x80, 0x00, 0x0a, 0x1c, 0xe3, 0xdf, 0x05, 0x00, 0x00, 0x82, 0x79, 0x00, 0x00, 0xff, 0x80, 0x00, 0x01, 0x0a, 0xfc, 0x83, 0x00, 0x00, 0xff, 0x83, 0x00, 0x01, 0xfd, 0x1b, 0x97, 0x00, 0x00, 0xcd, 0x88, 0x00, 0x03, 0x91, 0x70, 0x91, 0x70, 0x82, 0x00, 0x00, 0xff, 0x83, 0x00, 0x09, 0x51, 0xf5, 0x51, 0x00, 0x00, 0x67, 0xf2, 0xb5, 0x6c, 0xff, 0x88, 0x00, 0x01, 0x8d, 0x4e, 0x81, 0x00, 0x01, 0x52, 0x88, 0x8a, 0x00, 0x00, 0xee, 0x82, 0x00, 0x02, 0x6d, 0xfe, 0x30, 0x88, 0x00, 0x01, 0xcd, 0xcb, 0x81, 0x00, 0x01, 0x74, 0xa1, 0x82, 0x00, 0x06, 0x51, 0xfa, 0xf7, 0xe6, 0x3e, 0x00, 0x00, 0x82, 0xff, 0x02, 0x00, 0x00, 0xf6, 0x81, 0xff, 0x06, 0x00, 0x00, 0x2e, 0xc4, 0xfc, 0xfa, 0x51, 0x82, 0x00, 0x80, 0xff, 0x0c, 0x00, 0x28, 0xc1, 0xfb, 0xfa, 0x51, 0x00, 0x00, 0x78, 0xed, 0xf3, 0xbe, 0x44, 0x81, 0x00, 0x01, 0xd9, 0x17, 0x80, 0x00, 0x0a, 0x51, 0xfa, 0xff, 0xfa, 0x51, 0x00, 0x00, 0xc4, 0xe7, 0xc2, 0x7a, 0x81, 0x00, 0x01, 0xcd, 0xcb, 0x82, 0x00, 0x02, 0x91, 0xd8, 0x0b, 0x82, 0x00, 0x02, 0x10, 0xa6, 0xa3, 0x85, 0x00, 0x02, 0xa3, 0xa6, 0x10, 0x83, 0x00, 0x01, 0xd7, 0xd4, 0x81, 0x00, 0x05, 0xfa, 0x51, 0x00, 0x13, 0xa5, 0x00, 0x80, 0xff, 0x00, 0x00, 0x84, 0xff, 0x09, 0xfa, 0x51, 0x00, 0x00, 0x03, 0x8f, 0xe9, 0xd0, 0x2c, 0x00, 0x80, 0xff, 0x03, 0xfa, 0x51, 0x00, 0x00, 0x83, 0xff, 0x01, 0x00, 0x00, 0x80, 0xff, 0x81, 0x00, 0x05, 0x06, 0xa8, 0xef, 0xdc, 0x53, 0x00, 0x80, 0xff, 0x00, 0x00, 0x80, 0xff, 0x01, 0x00, 0x2b, 0x80, 0xff, 0x08, 0x3c, 0x00, 0x00, 0x51, 0xfa, 0xfa, 0x51, 0x00, 0x00, 0x80, 0xff, 0x04, 0x00, 0x00, 0xad, 0xdf, 0x00, 0x82, 0xff, 0x00, 0x00, 0x80, 0xff, 0x00, 0x00, 0x83, 0xff, 0x0b, 0x00, 0xae, 0xff, 0x00, 0x00, 0x06, 0xa4, 0xf7, 0xbc, 0x24, 0x00, 0x00, 0x80, 0xff, 0x81, 0x00, 0x05, 0x01, 0xa2, 0xff, 0xe1, 0x2b, 0x00, 0x80, 0xff, 0x09, 0x00, 0x00, 0x68, 0xea, 0x00, 0xe8, 0x6b, 0xf1, 0xdc, 0x34, 0x80, 0x00, 0x80, 0xff, 0x80, 0x00, 0x04, 0x1e, 0xc4, 0xf8, 0xc3, 0x1f, 0x81, 0x00, 0x01, 0xc0, 0x06, 0x80, 0x00, 0x07, 0x70, 0xff, 0xda, 0xff, 0x70, 0x00, 0xf0, 0xf4, 0x80, 0x00, 0x03, 0xf5, 0xf0, 0x00, 0x00, 0x80, 0xff, 0x80, 0x00, 0x82, 0xff, 0x80, 0x00, 0x00, 0xff, 0x85, 0x00, 0x01, 0x6e, 0x06, 0x82, 0x00, 0x00, 0xff, 0x95, 0x00, 0x03, 0x38, 0xcf, 0xd6, 0x3a, 0x81, 0xff, 0x1a, 0x91, 0xf4, 0xcf, 0x1d, 0x00, 0x00, 0x1a, 0xc0, 0xf5, 0xc5, 0x2a, 0x00, 0x00, 0x1e, 0xcc, 0xe8, 0x45, 0xff, 0xff, 0x00, 0x0d, 0xab, 0xf8, 0xd8, 0x7f, 0x00, 0x00, 0x82, 0xff, 0x07, 0x00, 0x00, 0x1f, 0xce, 0xe5, 0x44, 0xff, 0x00, 0x80, 0xff, 0x00, 0x00, 0x80, 0xff, 0x00, 0x00, 0x82, 0xff, 0x82, 0x00, 0x0a, 0xfe, 0x00, 0x00, 0xff, 0xff, 0x00, 0xff, 0xff, 0x33, 0x00, 0x00, 0x82, 0xff, 0x00, 0x00, 0x87, 0xff, 0x00, 0x00, 0x80, 0xff, 0x15, 0x00, 0x14, 0xb9, 0xf0, 0xb7, 0x12, 0x00, 0x00, 0xff, 0x35, 0xe5, 0xce, 0x1f, 0x00, 0x00, 0x1f, 0xc8, 0xde, 0x3a, 0xff, 0x00, 0x00, 0x82, 0xff, 0x06, 0x00, 0x00, 0xcd, 0x7b, 0xf4, 0xfa, 0x51, 0x80, 0x00, 0x10, 0x51, 0xfa, 0xf4, 0xad, 0x27, 0x00, 0x51, 0xf9, 0xcc, 0x2e, 0xff, 0xff, 0x00, 0x00, 0x65, 0xf5, 0x14, 0x80, 0x00, 0x0b, 0x31, 0xff, 0xd3, 0xff, 0x6d, 0x00, 0xf0, 0xf5, 0x00, 0x00, 0xf5, 0xee, 0x81, 0x00, 0x04, 0xa8, 0x73, 0x00, 0x00, 0x10, 0x82, 0xff, 0x81, 0x00, 0x00, 0xff, 0x83, 0x00, 0x00, 0xff, 0x83, 0x00, 0x00, 0xff, 0x89, 0x00, 0x01, 0xd7, 0xd4, 0x96, 0x00, 0x03, 0xdc, 0x16, 0xda, 0x16, 0x82, 0x00, 0x00, 0xee, 0x98, 0x00, 0x01, 0x26, 0x95, 0x81, 0x00, 0x01, 0x96, 0x22, 0x90, 0x00, 0x01, 0xb6, 0xa3, 0x8e, 0x00, 0x02, 0x02, 0xe0, 0x26, 0xd0, 0x00, 0x01, 0xd6, 0x2e, 0x85, 0x00, 0x00, 0x0a, 0x85, 0x00, 0x00, 0x0a, 0x8b, 0x00, 0x04, 0x51, 0xfa, 0xff, 0xe4, 0x54, 0xab, 0x00, 0x00, 0x09, 0xc1, 0x00, 0x03, 0x2c, 0xff, 0xf4, 0xd4, 0xbf, 0x00, 0x00, 0xff, 0x85, 0x00, 0x02, 0x1f, 0x74, 0x02, 0x81, 0x00, 0x00, 0xff, 0xc1, 0x00, 0x02, 0x01, 0x48, 0xd5, 0x8f, 0x00, 0x01, 0x26, 0xe6, 0xa3, 0x00, 0x00, 0xff, 0x87, 0x00, 0x00, 0xff, 0xb1, 0x00, 0x02, 0x11, 0xe4, 0x0d, 0x89, 0x00, 0x01, 0xf5, 0x1d, 0x82, 0x00, 0x00, 0xef, 0x82, 0x00, 0x01, 0x1e, 0xf6, 0xca, 0x00, 0x00, 0x88, 0x81, 0x00, 0x00, 0x86, 0x91, 0x00, 0x01, 0xdb, 0x1f, 0xff, 0x00, 0xfc, 0x00, 0x00, 0x0b, 0xc2, 0x00, 0x80, 0xff, 0x88, 0x00, 0x80, 0xff, 0xbf, 0x00, 0x04, 0x28, 0xff, 0xfd, 0xb6, 0x1a, 0x8d, 0x00, 0x03, 0xf1, 0xfd, 0xe5, 0x52, 0xa2, 0x00, 0x80, 0xff, 0x85, 0x00, 0x80, 0xff, 0xaf, 0x00, 0x81, 0xff, 0x89, 0x00, 0x01, 0x44, 0xe0, 0x88, 0x00, 0x01, 0xe0, 0x38, 0xff, 0x00, 0xff, 0x00, 0xff, 0x00, 0xc1, 0x00, 0x00, 0xf1, 0x82, 0xff, 0x00, 0xf0, 0xff, 0x00, 0xdb, 0x00, }; static EG_EMBEDDED_IMAGE egemb_font = { 672, 12, EG_EIPIXELMODE_ALPHA, EG_EICOMPMODE_RLE, egemb_font_data, 4118 }; debian/font/README0000644000000000000000000000044411455320607011021 0ustar Embedded font for libeg ----------------------- The font in font.png has been generated with GIMP and the Courier New font at 12px, no auto hinting. This font is antialiased, contrary to the font shipped with refit. -- Julien BLACHE , Fri, 23 May 2008 21:55:17 +0200 debian/rules0000755000000000000000000000606711455320607010262 0ustar #!/usr/bin/make -f # -*- makefile -*- # Sample debian/rules that uses debhelper. # This file was originally written by Joey Hess and Craig Small. # As a special exception, when this file is copied by dh-make into a # dh-make output file, you may use that output file without restriction. # This special exception was added by Craig Small in version 0.37 of dh-make. # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 # Debian version DEBVER = $(shell dpkg-parsechangelog | grep ^Version | cut -d' ' -f 2) CFLAGS = -Wall -g ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) CFLAGS += -O0 else CFLAGS += -O2 endif build: build-stamp build-stamp: dh_testdir # Generate include/syslinux_mbr.h chmod +x debian/mbr/mkmbrhdr.py debian/mbr/mkmbrhdr.py /usr/lib/syslinux/mbr.bin > include/syslinux_mbr.h # Move the AA font in place cp -f debian/font/egemb_font.h libeg/ # Build 32bit EFI applications mkdir libeg/build32 $(MAKE) -C libeg/build32 -f ../Makefile SRCDIR=$(CURDIR)/libeg ARCH=ia32 mkdir refit/build32 $(MAKE) -C refit/build32 -f ../Makefile SRCDIR=$(CURDIR)/refit ARCH=ia32 DEBVER="ia32 (Debian $(DEBVER))" mkdir gptsync/build32 $(MAKE) -C gptsync/build32 -f ../Makefile.gnuefi SRCDIR=$(CURDIR)/gptsync ARCH=ia32 # Build 64bit EFI applications mkdir libeg/build64 $(MAKE) -C libeg/build64 -f ../Makefile SRCDIR=$(CURDIR)/libeg ARCH=x86_64 mkdir refit/build64 $(MAKE) -C refit/build64 -f ../Makefile SRCDIR=$(CURDIR)/refit ARCH=x86_64 DEBVER="x86_64 (Debian $(DEBVER))" mkdir gptsync/build64 $(MAKE) -C gptsync/build64 -f ../Makefile.gnuefi SRCDIR=$(CURDIR)/gptsync ARCH=x86_64 # Assemble fat binaries mkdir fat-binaries ./fatglue.py fat-binaries/refit.efi refit/build32/refit.efi refit/build64/refit.efi mkdir fat-binaries/tools ./fatglue.py fat-binaries/tools/gptsync.efi gptsync/build32/gptsync.efi gptsync/build64/gptsync.efi # Build the gptsync command-line utility mkdir gptsync/buildux $(MAKE) -C gptsync/buildux -f ../Makefile.unix SRCDIR=$(CURDIR)/gptsync touch $@ clean: dh_testdir dh_testroot rm -f build-stamp configure-stamp # Add here commands to clean up after the build process. rm -rf libeg/build32 libeg/build64 rm -rf refit/build32 refit/build64 rm -rf gptsync/build32 gptsync/build64 gptsync/buildux rm -rf fat-binaries # Remove the MBR code rm -f include/syslinux_mbr.h # Remove the AA font rm -f libeg/egemb_font.h dh_clean install: build dh_testdir dh_testroot dh_clean -k dh_installdirs dh_install chmod 0644 $(CURDIR)/debian/refit/usr/lib/refit/ia32/* chmod 0644 $(CURDIR)/debian/refit/usr/lib/refit/x64/* # Build architecture-independent files here. binary-indep: build install # We have nothing to do by default. # Build architecture-dependent files here. binary-arch: build install dh_testdir dh_testroot dh_installchangelogs dh_installdocs dh_installexamples dh_installman dh_link dh_strip dh_compress dh_fixperms dh_installdeb dh_shlibdeps -Nrefit dh_gencontrol dh_md5sums dh_builddeb binary: binary-indep binary-arch .PHONY: build clean binary-indep binary-arch binary install configure debian/gptsync-udeb.install0000644000000000000000000000007311455320607013165 0ustar gptsync/buildux/gptsync sbin gptsync/buildux/showpart sbin debian/refit.install0000644000000000000000000000041511455320607011672 0ustar refit/build32/refit.efi usr/lib/refit/ia32 refit/build64/refit.efi usr/lib/refit/x64 fat-binaries/refit.efi usr/lib/refit/refit fat-binaries/tools usr/lib/refit icons usr/lib/refit/refit images/vollabel/refit.vollabel usr/lib/refit/refit refit.conf usr/lib/refit/refit debian/refit.TODO0000644000000000000000000000051111455320607010766 0ustar TODO ---- * Get gnu-efi to support EFI 1.10. * Once done, build the tools and EFI drivers and reenable the EFI 1.10 code in rEFIt. * Wrap all EFI calls in the tools and drivers with uefi_call_wrapper(); the call wrapper is mandatory on x86_64. -- Julien BLACHE , Sun, 18 May 2008 16:48:24 +0200 debian/refit.dirs0000644000000000000000000000005011455320607011160 0ustar usr/lib/refit/refit usr/lib/refit/tools debian/README.source0000644000000000000000000000434311455320607011354 0ustar rEFIt packaging --------------- First off, if you do not know what you are doing, do not have the faintest idea of what rEFIt does nor what EFI is: STOP RIGHT AWAY! YOU CAN ONLY BREAK SOMETHING! That being said, a couple things to keep in mind: - this package builds fat EFI binaries; that means the binaries are built twice, once for ia32 and once for x86_64, then assembled into a fat binary. => the code MUST build and work on both architectures - GNU-EFI uses a wrapper for any and all EFI API calls. Upstream doesn't use GNU-EFI, so the wrapper has to be added to every EFI API call for Debian. => upgrading to a new upstream release means doing a diff to the previous release, identifying all the new EFI API calls, then updating the individual debian patches for the wrapper. => enabling a new tool or driver means adding a new patch that adds the wrapper wherever necessary. - GNU-EFI currently doesn't support EFI 1.10. That means no filesystem driver can be built, and some features in rEFIt or in the tools have to be #ifdef'd away. => some tools probably cannot be built without EFI 1.10, plain and simple. => guard the EFI 1.10 code with #ifndef DEBIAN_ENABLE_EFI110 Source package -------------- Upstream unfortunately doesn't ship a complete source package. The tarball released by upstream, named refit-src-.tar.gz, doesn't contain the icons, source images nor the refit config file. The Debian source tarball is assembled from the upstream refit-src-.tar.gz source tarball, plus: - images/ directory exported from https://refit.svn.sourceforge.net/svnroot/refit/tags/release-/images - icons/ directory exported from https://refit.svn.sourceforge.net/svnroot/refit/tags/release-/dist/efi/refit/icons - refit.conf exported from https://refit.svn.sourceforge.net/svnroot/refit/tags/release-/dist/efi/refit/refit.conf Also, upstream ships include/syslinux_mbr.h in its source tarball, which contains an MBR image from syslinux. This file has been purged from the tarball and is generated at build time from the mbr.bin file shipped by the syslinux Debian package. -- Julien BLACHE , Sat, 24 May 2008 10:32:04 +0200 debian/compat0000644000000000000000000000000211455320607010367 0ustar 5 debian/refit.README.Debian0000644000000000000000000001230611455320607012344 0ustar refit for Debian ---------------- Installation ------------ EFI files are available in /usr/lib/refit/; copy the refit and tools subdirectories somewhere accessible from Mac OS X, boot into Mac OS X, then: - install the files in a directory named "efi" at the root of a FAT or HFS+ partition - 'bless' refit.efi (see man bless on Mac OS X) The first partition of your disk is a ca. 200 MB FAT partition that is used by the EFI ROM. It's usually empty, and is a good place to install refit. To 'bless' rEFIt, cd to the directory where refit.efi is located, and run $ sudo bless --folder "$PWD" --file "$PWD/refit.efi" --labelfile "$PWD/refit.vollabel" --setBoot You may need to use the --mount option to bless; see man bless for details. 32bit vs. 64bit EFI binaries and fat EFI binaries ------------------------------------------------- Intel Macs can use 32bit or 64bit binaries; it depends on the exact model of machine you have. Any machine equipped with a Santa Rosa CPU or later uses a 64bit EFI firmware and thus uses 64bit EFI binaries (x64 in EFI terminology). Any machine before that uses a 32bit EFI firmware and thus uses 32bit (ia32) EFI binaries. When installing an EFI application, you need to install the appropriate binary depending on your machine, unless that application is shipped as a fat EFI binary. Fat EFI binaries are a way to overcome this problem. The binaries contain both ia32 code and x64 code and the firmware picks up the appropriate code when loading the binaries. Everything under /usr/lib/refit/refit and /usr/lib/refit/tools is a fat binary; binaries under /usr/lib/refit/ia32 and /usr/lib/refit/x64 are respectively ia32 binaries and x64 binaries. rEFIt (and tools) is currently the only EFI application in Debian shipped as a fat EFI binary. There's a doubt as to whether fat EFI binaries are supported by non Apple machines, so this situation will probably remain. Building a bootable rEFIt CD/DVD -------------------------------- Creating a bootable EFI CD/DVD with rEFIt is quite easy. Start by creating a directory that will hold the files needed for the bootable image: $ mkdir bootimg Create an EFI directory: $ mkdir bootimg/efi Copy the rEFIt files: $ cp -a /usr/lib/refit/* bootimg/efi Now we rename, move around and remove some files: $ mv bootimg/efi/refit bootimg/efi/boot $ rm bootimg/efi/boot/refit.efi $ mv bootimg/efi/ia32/refit.efi bootimg/efi/boot/bootia32.efi $ rmdir bootimg/efi/ia32 $ mv bootimg/efi/x64/refit.efi bootimg/efi/boot/bootx64.efi $ rmdir bootimg/efi/x64 The efi/boot directory layout is mandated by the EFI spec. The bootia32.efi and bootx64.efi are respectively ia32 and x64 binaries that the EFI firmware will run. We first delete refit.efi because that binary is a fat EFI binary, and here we need to separate binaries. If you only need to boot a ia32 machine, you can leave out the bootx64.efi file, and vice versa. At that point, you can add to the image whatever utilities you want to have on the boot image. You can also add a rescue system, that is a linux kernel, an initrd and elilo.efi together with its configuration file. Pay attention to the architecture of the elilo.efi binary. To make the actual boot image, first determine its size: $ du -sk bootimg Round up the number to make some room for the metadata (5% will do) and make it a multiple of 16 ($size / 16 * 16), then create an msdos filesystem image using this number for the count= parameter: $ dd if=/dev/zero of=boot.img bs=1k count=1024 Format the image: $ mkfs.msdos -n "rEFItbootCD" boot.img And copy the files into the image: $ mcopy -iboot.img -s bootimg/efi ::/ Finally, build a bootable CD/DVD image: $ mkdir -p cdimg/boot $ cp boot.img cdimg/boot $ genisoimage -J -iso-level 3 -r -R -o rEFItCD.iso -b boot/boot.img \ -c boot/boot.cat -V rEFItBootCD -no-emul-boot ./cdimg (on the CD image, /boot can be an arbitrary location, and boot.{img,cat} can be arbritrary names -- adapt the genisoimage command line to suit your needs) Burn the resulting rEFItCD.iso to a CD or DVD. When mounting the CD, you should see 2 files on it, boot/boot.img and boot/boot.cat. Reboot the machine with the CD in the drive; hold down the Alt (Option) key when the machine starts, until the Apple Chooser shows up. You'll see hard drives icons and 2 CD icons: one labelled "Windows" and one labelled "EFI Boot". Use the CD icon labelled "EFI boot" to boot on the CD, and rEFIt will start. Do not use the other CD icon; it's a legacy boot entry and it won't boot. Differences from upstream ------------------------- rEFIt in Debian is built against gnu-efi. As gnu-efi doesn't support EFI 1.10, a number of rEFIt features have been taken out. Though rEFIt remains usable and able to boot the machine, those features are not available: - loading EFI drivers (ext2/ext3, reiserfs, ...) - machine shutdown EFI shell and tools ------------------- The EFI shell and tools distributed with the binary distribution of rEFIt come from the TianoCore (Intel) EFI Toolkit. A large part of the EFI Toolkit codebase is licensed under the 4-clause BSD license, which incompatible with the GPL, making it impossible to build the tools against gnu-efi. -- Julien BLACHE , Fri, 30 May 2008 20:10:32 +0200 debian/source/0000755000000000000000000000000011455320607010471 5ustar debian/source/format0000644000000000000000000000001411455320607011677 0ustar 3.0 (quilt) debian/showpart.80000644000000000000000000000115011455320607011126 0ustar .TH "showpart" 8 "2008 July 24" "Debian" "rEFIt" .SH NAME showpart \- show GPT and MBR partition tables side by side .SH SYNOPSIS .B showpart \fIdevice\fR .SH DESCRIPTION \fBshowpart\fR reads the GPT and MBR partition tables on \fIdevice\fR and displays their contents side by side. Display includes detailed partition tables, MBR content and detailed partition information. \fBshowpart\fR is a companion tool to \fBgptsync\fR. .SH AUTHOR \fBshowpart\fR was written by Christoph Pfisterer. This manual page was written by Julien BLACHE , for the Debian Project (but may be used by others). debian/mbr/0000755000000000000000000000000011455320607007751 5ustar debian/mbr/mkmbrhdr.py0000755000000000000000000000152211455320607012134 0ustar #!/usr/bin/python import sys if len(sys.argv) != 2: print >> sys.stderr, 'Usage: mkmbrhdr.py /path/to/mbr.bin' sys.exit(1) mbr = open(sys.argv[1], "rb") mbr_code = mbr.read(512) mbr.close() print >> sys.stderr, 'MBR code is %d bytes' % len(mbr_code) print """ /* * MBR boot code - from syslinux */ #ifndef __SYSLINUX_MBR_H__ #define __SYSLINUX_MBR_H__ #define MBR_BOOTCODE_SIZE (440) #define SYSLINUX_MBR_SIZE (%d) #if SYSLINUX_MBR_SIZE > MBR_BOOTCODE_SIZE # error MBR code overlength! #endif static UINT8 syslinux_mbr[SYSLINUX_MBR_SIZE] = {""" % len(mbr_code) wrap = 0 for byte in mbr_code: if wrap == 0: sys.stdout.write(" ") sys.stdout.write(" 0x%02x," % ord(byte)) wrap += 1 if wrap == 8: wrap = 0 sys.stdout.write("\n") print """ }; #endif /* __SYSLINUX_MBR_H__ */ """ debian/gptsync.dirs0000644000000000000000000000000611455320607011537 0ustar sbin debian/control0000644000000000000000000000302411455320607010573 0ustar Source: refit Section: admin Priority: optional Maintainer: Ubuntu Developers XSBC-Original-Maintainer: Julien BLACHE Build-Depends: debhelper (>= 5), gnu-efi (>= 3.0i-3), gcc-multilib, syslinux-common, python Standards-Version: 3.8.4 Package: refit Architecture: i386 amd64 kfreebsd-amd64 Depends: ${misc:Depends}, gptsync Description: graphical boot menu for ia32 and x64 EFI systems rEFIt is a boot menu and maintenance toolkit for EFI-based (Extensible Firmware Interface) machines like the Intel-based Macs. You can use it to boot multiple operating systems easily, including triple-boot setups with Apple's Boot Camp. Package: gptsync Architecture: i386 amd64 kfreebsd-amd64 Depends: ${shlibs:Depends}, ${misc:Depends} Replaces: refit Description: GPT and MBR partition tables synchronisation tool gptsync is a utility to maintain an MBR partition table synchronised with a GPT partition table used as reference. The resulting MBR partition table can contain up to 4 partitions; extended partitions are not supported. . An MBR partition table is required to use legacy bootloaders (lilo, grub) on EFI-based (Extensible Firmware Interface) machines like the Intel-based Macs. gptsync is usually used in combination with the rEFIt boot menu on such machines. Package: gptsync-udeb Section: debian-installer Architecture: i386 amd64 kfreebsd-amd64 XB-Package-Type: udeb Depends: ${shlibs:Depends}, ${misc:Depends} Description: GPT and MBR partition tables synchronisation tool debian/gptsync.install0000644000000000000000000000007311455320607012250 0ustar gptsync/buildux/gptsync sbin gptsync/buildux/showpart sbin debian/patches/0000755000000000000000000000000011455320607010620 5ustar debian/patches/gptsync_nom_nom_nom_newline.patch0000644000000000000000000000133611455320607017447 0ustar Description: Consume newline characters after prompt When prompting for user input, consume characters up to the newline character; avoids leaving characters behind that end up being consumed by the shell after gptsync terminates. Author: Julien BLACHE Index: refit-0.14/gptsync/os_unix.c =================================================================== --- refit-0.14.orig/gptsync/os_unix.c 2010-04-19 18:30:26.094931554 +0200 +++ refit-0.14/gptsync/os_unix.c 2010-04-19 18:30:19.863932083 +0200 @@ -150,7 +150,11 @@ printf("No\n"); *bool_out = FALSE; } - + + /* Consume everything up to and including newline */ + while (getchar() != '\n') + ; + return 0; } debian/patches/gptsync_quiet_mode.patch0000644000000000000000000001006211455320607015542 0ustar Description: Add a quiet mode to gptsync for non-interactive use gptsync's output is a nuisance when used in scripts. Author: Julien BLACHE Index: refit-0.14/gptsync/Makefile.unix =================================================================== --- refit-0.14.orig/gptsync/Makefile.unix 2010-04-19 18:33:15.842932277 +0200 +++ refit-0.14/gptsync/Makefile.unix 2010-04-19 18:33:14.643931533 +0200 @@ -44,7 +44,7 @@ gptsync.unix.o: gptsync.c $(CC) $(CPPFLAGS) $(CFLAGS) -c $< -o $@ os_unix.gptsync.o: os_unix.c - $(CC) $(CPPFLAGS) -DPROGNAME=gptsync $(CFLAGS) -c $< -o $@ + $(CC) $(CPPFLAGS) -DPROGNAME=gptsync -DGPTSYNC $(CFLAGS) -c $< -o $@ $(SHOWPART_TARGET): $(SHOWPART_OBJS) $(CC) $(LDFLAGS) -o $@ $(SHOWPART_OBJS) $(LIBS) @@ -52,7 +52,7 @@ showpart.unix.o: showpart.c $(CC) $(CPPFLAGS) $(CFLAGS) -c $< -o $@ os_unix.showpart.o: os_unix.c - $(CC) $(CPPFLAGS) -DPROGNAME=showpart -DNOREADONLYWARN $(CFLAGS) -c $< -o $@ + $(CC) $(CPPFLAGS) -DPROGNAME=showpart -DSHOWPART -DNOREADONLYWARN $(CFLAGS) -c $< -o $@ lib.unix.o: lib.c $(CC) $(CPPFLAGS) $(CFLAGS) -c $< -o $@ Index: refit-0.14/gptsync/gptsync.8 =================================================================== --- refit-0.14.orig/gptsync/gptsync.8 2010-04-19 18:33:15.808931911 +0200 +++ refit-0.14/gptsync/gptsync.8 2010-04-19 18:33:14.643931533 +0200 @@ -1,16 +1,24 @@ -.TH "gptsync" 8 "2006 Jul 2" "Debian" "rEFIt" +.TH "gptsync" 8 "2008 May 23" "Debian" "rEFIt" .SH NAME gptsync \- GPT partition table to MBR partition table synchronisation -.SH "SYNOPSIS" -.BI "gptsync " "device" -.SH "DESCRIPTION" + +.SH SYNOPSIS +.B gptsync +[\fI\-q\fR] \fIdevice\fR + +.SH DESCRIPTION Reads the GPT partition table on the device and synchronise content of MBR partition table on the device. Useful for situations (as in mactel linux) where legacy operating systems require MBR partition table to function properly, while most other operating systems can work with GPT. -.SH "Author" +.SH OPTIONS +.TP +\fB\-q\fR +Do not print any message, do not prompt to modify the MBR. + +.SH AUTHOR Written by Christoph Pfisterer. This manual page contributed for Debian by Junichi Uekawa , but may be used for others. Index: refit-0.14/gptsync/os_unix.c =================================================================== --- refit-0.14.orig/gptsync/os_unix.c 2010-04-19 18:33:15.891931901 +0200 +++ refit-0.14/gptsync/os_unix.c 2010-04-19 18:33:14.643931533 +0200 @@ -43,8 +43,8 @@ #define PROGNAME_S STRINGIFY2(PROGNAME) // variables - static int fd; +int quiet = 0; // // error functions @@ -135,7 +135,13 @@ UINTN input_boolean(CHARN *prompt, BOOLEAN *bool_out) { int c; - + + if (quiet) + { + *bool_out = TRUE; + return 0; + } + printf("%s", prompt); fflush(NULL); @@ -168,7 +174,10 @@ char formatbuf[256]; char buf[4096]; int i; - + + if (quiet) + return; + for (i = 0; format[i]; i++) formatbuf[i] = (format[i] > 255) ? '?' : (char)(format[i] & 0xff); formatbuf[i] = 0; @@ -180,6 +189,18 @@ printf("%s", buf); } +void usage(void) +{ +#ifdef GPTSYNC + fprintf(stderr, "Usage: " PROGNAME_S " [-q] \n"); + fprintf(stderr, "\t-q\tquiet mode\n"); + +#elif defined(SHOWPART) + + fprintf(stderr, "Usage: " PROGNAME_S " \n"); +#endif +} + // // main entry point // @@ -192,14 +213,37 @@ UINT64 filesize; char *reason; int status; - + // argument check +#ifdef GPTSYNC + switch (argc) + { + case 2: + filename = argv[1]; + break; + case 3: + if (strncmp("-q", argv[1], 2) != 0) + { + usage(); + return 1; + } + quiet = 1; + filename = argv[2]; + break; + default: + usage(); + return 1; + } + +#elif defined(SHOWPART) + if (argc != 2) { - fprintf(stderr, "Usage: " PROGNAME_S " \n"); - return 1; + usage(); + return 1; } filename = argv[1]; - +#endif + // set input to unbuffered fflush(NULL); setvbuf(stdin, NULL, _IONBF, 0); debian/patches/refit_uefi_call_wrapper.patch0000644000000000000000000007452111455320607016526 0ustar Description: Wrap EFI API calls with refit_callX_wrapper() Mandatory for GNU EFI especially on x86_64. Author: Julien BLACHE Index: refit-0.14/refit/config.c =================================================================== --- refit-0.14.orig/refit/config.c 2010-04-21 17:27:19.338288906 +0200 +++ refit-0.14/refit/config.c 2010-04-21 17:52:44.332336109 +0200 @@ -35,6 +35,7 @@ */ #include "lib.h" +#include "refit_call_wrapper.h" // constants @@ -64,14 +65,14 @@ File->BufferSize = 0; // read the file, allocating a buffer on the woy - Status = BaseDir->Open(BaseDir, &FileHandle, FileName, EFI_FILE_MODE_READ, 0); + Status = refit_call5_wrapper(BaseDir->Open, BaseDir, &FileHandle, FileName, EFI_FILE_MODE_READ, 0); if (CheckError(Status, L"while loading the configuration file")) return Status; FileInfo = LibFileInfo(FileHandle); if (FileInfo == NULL) { // TODO: print and register the error - FileHandle->Close(FileHandle); + refit_call1_wrapper(FileHandle->Close, FileHandle); return EFI_LOAD_ERROR; } ReadSize = FileInfo->FileSize; @@ -81,14 +82,14 @@ File->BufferSize = (UINTN)ReadSize; // was limited to a few K before, so this is safe File->Buffer = AllocatePool(File->BufferSize); - Status = FileHandle->Read(FileHandle, &File->BufferSize, File->Buffer); + Status = refit_call3_wrapper(FileHandle->Read, FileHandle, &File->BufferSize, File->Buffer); if (CheckError(Status, L"while loading the configuration file")) { FreePool(File->Buffer); File->Buffer = NULL; - FileHandle->Close(FileHandle); + refit_call1_wrapper(FileHandle->Close, FileHandle); return Status; } - Status = FileHandle->Close(FileHandle); + Status = refit_call1_wrapper(FileHandle->Close, FileHandle); // setup for reading File->Current8Ptr = (CHAR8 *)File->Buffer; Index: refit-0.14/refit/lib.c =================================================================== --- refit-0.14.orig/refit/lib.c 2010-04-21 17:27:19.346288992 +0200 +++ refit-0.14/refit/lib.c 2010-04-21 17:52:55.803287996 +0200 @@ -35,6 +35,7 @@ */ #include "lib.h" +#include "refit_call_wrapper.h" // variables @@ -67,7 +68,7 @@ UINTN i; SelfImageHandle = ImageHandle; - Status = BS->HandleProtocol(SelfImageHandle, &LoadedImageProtocol, (VOID **) &SelfLoadedImage); + Status = refit_call3_wrapper(BS->HandleProtocol, SelfImageHandle, &LoadedImageProtocol, (VOID **) &SelfLoadedImage); if (CheckFatalError(Status, L"while getting a LoadedImageProtocol handle")) return EFI_LOAD_ERROR; @@ -105,12 +106,12 @@ UninitVolumes(); if (SelfDir != NULL) { - SelfDir->Close(SelfDir); + refit_call1_wrapper(SelfDir->Close, SelfDir); SelfDir = NULL; } if (SelfRootDir != NULL) { - SelfRootDir->Close(SelfRootDir); + refit_call1_wrapper(SelfRootDir->Close, SelfRootDir); SelfRootDir = NULL; } } @@ -141,7 +142,7 @@ } } - Status = SelfRootDir->Open(SelfRootDir, &SelfDir, SelfDirPath, EFI_FILE_MODE_READ, 0); + Status = refit_call5_wrapper(SelfRootDir->Open, SelfRootDir, &SelfDir, SelfDirPath, EFI_FILE_MODE_READ, 0); if (CheckFatalError(Status, L"while opening our installation directory")) return EFI_LOAD_ERROR; @@ -233,11 +234,11 @@ for (HandleIndex = 0; HandleIndex < HandleCount && PathCount < MaxPaths; HandleIndex++) { Handle = Handles[HandleIndex]; - Status = BS->HandleProtocol(Handle, &LoadedImageProtocol, (VOID **) &LoadedImage); + Status = refit_call3_wrapper(BS->HandleProtocol, Handle, &LoadedImageProtocol, (VOID **) &LoadedImage); if (EFI_ERROR(Status)) continue; // This can only happen if the firmware scewed up, ignore it. - Status = BS->HandleProtocol(LoadedImage->DeviceHandle, &DevicePathProtocol, (VOID **) &DevicePath); + Status = refit_call3_wrapper(BS->HandleProtocol, LoadedImage->DeviceHandle, &DevicePathProtocol, (VOID **) &DevicePath); if (EFI_ERROR(Status)) continue; // This happens, ignore it. @@ -293,8 +294,9 @@ return; // our buffer is too small... // look at the boot sector (this is used for both hard disks and El Torito images!) - Status = Volume->BlockIO->ReadBlocks(Volume->BlockIO, Volume->BlockIO->Media->MediaId, - Volume->BlockIOOffset, 2048, SectorBuffer); + Status = refit_call5_wrapper(Volume->BlockIO->ReadBlocks, + Volume->BlockIO, Volume->BlockIO->Media->MediaId, + Volume->BlockIOOffset, 2048, SectorBuffer); if (!EFI_ERROR(Status)) { if (*((UINT16 *)(SectorBuffer + 510)) == 0xaa55 && SectorBuffer[0] != 0) { @@ -446,7 +448,7 @@ Volume->DiskKind = DISK_KIND_INTERNAL; // default // get block i/o - Status = BS->HandleProtocol(Volume->DeviceHandle, &BlockIoProtocol, (VOID **) &(Volume->BlockIO)); + Status = refit_call3_wrapper(BS->HandleProtocol, Volume->DeviceHandle, &BlockIoProtocol, (VOID **) &(Volume->BlockIO)); if (EFI_ERROR(Status)) { Volume->BlockIO = NULL; Print(L"Warning: Can't get BlockIO protocol.\n"); @@ -493,7 +495,7 @@ // get the handle for that path RemainingDevicePath = DiskDevicePath; //Print(L" * looking at %s\n", DevicePathToStr(RemainingDevicePath)); - Status = BS->LocateDevicePath(&BlockIoProtocol, &RemainingDevicePath, &WholeDiskHandle); + Status = refit_call3_wrapper(BS->LocateDevicePath, &BlockIoProtocol, &RemainingDevicePath, &WholeDiskHandle); //Print(L" * remaining: %s\n", DevicePathToStr(RemainingDevicePath)); FreePool(DiskDevicePath); @@ -501,13 +503,13 @@ //Print(L" - original handle: %08x - disk handle: %08x\n", (UINT32)DeviceHandle, (UINT32)WholeDiskHandle); // get the device path for later - Status = BS->HandleProtocol(WholeDiskHandle, &DevicePathProtocol, (VOID **) &DiskDevicePath); + Status = refit_call3_wrapper(BS->HandleProtocol, WholeDiskHandle, &DevicePathProtocol, (VOID **) &DiskDevicePath); if (!EFI_ERROR(Status)) { Volume->WholeDiskDevicePath = DuplicateDevicePath(DiskDevicePath); } // look at the BlockIO protocol - Status = BS->HandleProtocol(WholeDiskHandle, &BlockIoProtocol, (VOID **) &Volume->WholeDiskBlockIO); + Status = refit_call3_wrapper(BS->HandleProtocol, WholeDiskHandle, &BlockIoProtocol, (VOID **) &Volume->WholeDiskBlockIO); if (!EFI_ERROR(Status)) { // check the media block size @@ -580,9 +582,10 @@ for (ExtCurrent = ExtBase; ExtCurrent; ExtCurrent = NextExtCurrent) { // read current EMBR - Status = WholeDiskVolume->BlockIO->ReadBlocks(WholeDiskVolume->BlockIO, - WholeDiskVolume->BlockIO->Media->MediaId, - ExtCurrent, 512, SectorBuffer); + Status = refit_call5_wrapper(WholeDiskVolume->BlockIO->ReadBlocks, + WholeDiskVolume->BlockIO, + WholeDiskVolume->BlockIO->Media->MediaId, + ExtCurrent, 512, SectorBuffer); if (EFI_ERROR(Status)) break; if (*((UINT16 *)(SectorBuffer + 510)) != 0xaa55) @@ -704,12 +707,14 @@ continue; // compare boot sector read through offset vs. directly - Status = Volume->BlockIO->ReadBlocks(Volume->BlockIO, Volume->BlockIO->Media->MediaId, - Volume->BlockIOOffset, 512, SectorBuffer1); + Status = refit_call5_wrapper(Volume->BlockIO->ReadBlocks, + Volume->BlockIO, Volume->BlockIO->Media->MediaId, + Volume->BlockIOOffset, 512, SectorBuffer1); if (EFI_ERROR(Status)) break; - Status = Volume->WholeDiskBlockIO->ReadBlocks(Volume->WholeDiskBlockIO, Volume->WholeDiskBlockIO->Media->MediaId, - MbrTable[PartitionIndex].StartLBA, 512, SectorBuffer2); + Status = refit_call5_wrapper(Volume->WholeDiskBlockIO->ReadBlocks, + Volume->WholeDiskBlockIO, Volume->WholeDiskBlockIO->Media->MediaId, + MbrTable[PartitionIndex].StartLBA, 512, SectorBuffer2); if (EFI_ERROR(Status)) break; if (CompareMem(SectorBuffer1, SectorBuffer2, 512) != 0) @@ -746,7 +751,7 @@ Volume = Volumes[VolumeIndex]; if (Volume->RootDir != NULL) { - Volume->RootDir->Close(Volume->RootDir); + refit_call1_wrapper(Volume->RootDir->Close, Volume->RootDir); Volume->RootDir = NULL; } @@ -770,7 +775,7 @@ if (Volume->DevicePath != NULL) { // get the handle for that path RemainingDevicePath = Volume->DevicePath; - Status = BS->LocateDevicePath(&BlockIoProtocol, &RemainingDevicePath, &DeviceHandle); + Status = refit_call3_wrapper(BS->LocateDevicePath, &BlockIoProtocol, &RemainingDevicePath, &DeviceHandle); if (!EFI_ERROR(Status)) { Volume->DeviceHandle = DeviceHandle; @@ -785,11 +790,11 @@ if (Volume->WholeDiskDevicePath != NULL) { // get the handle for that path RemainingDevicePath = Volume->WholeDiskDevicePath; - Status = BS->LocateDevicePath(&BlockIoProtocol, &RemainingDevicePath, &WholeDiskHandle); + Status = refit_call3_wrapper(BS->LocateDevicePath, &BlockIoProtocol, &RemainingDevicePath, &WholeDiskHandle); if (!EFI_ERROR(Status)) { // get the BlockIO protocol - Status = BS->HandleProtocol(WholeDiskHandle, &BlockIoProtocol, (VOID **) &Volume->WholeDiskBlockIO); + Status = refit_call3_wrapper(BS->HandleProtocol, WholeDiskHandle, &BlockIoProtocol, (VOID **) &Volume->WholeDiskBlockIO); if (EFI_ERROR(Status)) { Volume->WholeDiskBlockIO = NULL; CheckError(Status, L"from HandleProtocol"); @@ -809,9 +814,9 @@ EFI_STATUS Status; EFI_FILE *TestFile; - Status = BaseDir->Open(BaseDir, &TestFile, RelativePath, EFI_FILE_MODE_READ, 0); + Status = refit_call5_wrapper(BaseDir->Open, BaseDir, &TestFile, RelativePath, EFI_FILE_MODE_READ, 0); if (Status == EFI_SUCCESS) { - TestFile->Close(TestFile); + refit_call1_wrapper(TestFile->Close, TestFile); return TRUE; } return FALSE; @@ -836,7 +841,7 @@ LastBufferSize = BufferSize = 256; Buffer = AllocatePool(BufferSize); for (IterCount = 0; ; IterCount++) { - Status = Directory->Read(Directory, &BufferSize, Buffer); + Status = refit_call3_wrapper(Directory->Read, Directory, &BufferSize, Buffer); if (Status != EFI_BUFFER_TOO_SMALL || IterCount >= 4) break; if (BufferSize <= LastBufferSize) { @@ -885,7 +890,7 @@ DirIter->DirHandle = BaseDir; DirIter->CloseDirHandle = FALSE; } else { - DirIter->LastStatus = BaseDir->Open(BaseDir, &(DirIter->DirHandle), RelativePath, EFI_FILE_MODE_READ, 0); + DirIter->LastStatus = refit_call5_wrapper(BaseDir->Open, BaseDir, &(DirIter->DirHandle), RelativePath, EFI_FILE_MODE_READ, 0); DirIter->CloseDirHandle = EFI_ERROR(DirIter->LastStatus) ? FALSE : TRUE; } DirIter->LastFileInfo = NULL; @@ -929,7 +934,7 @@ DirIter->LastFileInfo = NULL; } if (DirIter->CloseDirHandle) - DirIter->DirHandle->Close(DirIter->DirHandle); + refit_call1_wrapper(DirIter->DirHandle->Close, DirIter->DirHandle); return DirIter->LastStatus; } Index: refit-0.14/refit/main.c =================================================================== --- refit-0.14.orig/refit/main.c 2010-04-21 17:50:57.051288666 +0200 +++ refit-0.14/refit/main.c 2010-04-21 17:53:08.701288018 +0200 @@ -35,6 +35,7 @@ */ #include "lib.h" +#include "refit_call_wrapper.h" #include "syslinux_mbr.h" @@ -125,7 +126,7 @@ // load the image into memory ReturnStatus = Status = EFI_NOT_FOUND; // in case the list is empty for (DevicePathIndex = 0; DevicePaths[DevicePathIndex] != NULL; DevicePathIndex++) { - ReturnStatus = Status = BS->LoadImage(FALSE, SelfImageHandle, DevicePaths[DevicePathIndex], NULL, 0, &ChildImageHandle); + ReturnStatus = Status = refit_call6_wrapper(BS->LoadImage, FALSE, SelfImageHandle, DevicePaths[DevicePathIndex], NULL, 0, &ChildImageHandle); if (ReturnStatus != EFI_NOT_FOUND) break; } @@ -138,7 +139,7 @@ // set load options if (LoadOptions != NULL) { - ReturnStatus = Status = BS->HandleProtocol(ChildImageHandle, &LoadedImageProtocol, (VOID **) &ChildLoadedImage); + ReturnStatus = Status = refit_call3_wrapper(BS->HandleProtocol, ChildImageHandle, &LoadedImageProtocol, (VOID **) &ChildLoadedImage); if (CheckError(Status, L"while getting a LoadedImageProtocol handle")) { if (ErrorInStep != NULL) *ErrorInStep = 2; @@ -162,7 +163,7 @@ // turn control over to the image // TODO: (optionally) re-enable the EFI watchdog timer! - ReturnStatus = Status = BS->StartImage(ChildImageHandle, NULL, NULL); + ReturnStatus = Status = refit_call3_wrapper(BS->StartImage, ChildImageHandle, NULL, NULL); // control returns here when the child image calls Exit() SPrint(ErrorInfo, 255, L"returned from %s", ImageTitle); if (CheckError(Status, ErrorInfo)) { @@ -175,7 +176,7 @@ bailout_unload: // unload the image, we don't care if it works or not... - Status = BS->UnloadImage(ChildImageHandle); + Status = refit_call1_wrapper(BS->UnloadImage, ChildImageHandle); bailout: if (FullLoadOptions != NULL) FreePool(FullLoadOptions); @@ -570,7 +571,7 @@ BOOLEAN HaveBootCode; // read MBR - Status = BlockIO->ReadBlocks(BlockIO, BlockIO->Media->MediaId, 0, 512, SectorBuffer); + Status = refit_call5_wrapper(BlockIO->ReadBlocks, BlockIO, BlockIO->Media->MediaId, 0, 512, SectorBuffer); if (EFI_ERROR(Status)) return Status; if (*((UINT16 *)(SectorBuffer + 510)) != 0xaa55) @@ -606,7 +607,7 @@ } // write MBR - Status = BlockIO->WriteBlocks(BlockIO, BlockIO->Media->MediaId, 0, 512, SectorBuffer); + Status = refit_call5_wrapper(BlockIO->WriteBlocks, BlockIO, BlockIO->Media->MediaId, 0, 512, SectorBuffer); if (EFI_ERROR(Status)) return Status; @@ -616,7 +617,7 @@ // NOTE: ExtBase was set above while looking at the MBR table for (ExtCurrent = ExtBase; ExtCurrent; ExtCurrent = NextExtCurrent) { // read current EMBR - Status = BlockIO->ReadBlocks(BlockIO, BlockIO->Media->MediaId, ExtCurrent, 512, SectorBuffer); + Status = refit_call5_wrapper(BlockIO->ReadBlocks, BlockIO, BlockIO->Media->MediaId, ExtCurrent, 512, SectorBuffer); if (EFI_ERROR(Status)) return Status; if (*((UINT16 *)(SectorBuffer + 510)) != 0xaa55) @@ -643,7 +644,7 @@ } // write current EMBR - Status = BlockIO->WriteBlocks(BlockIO, BlockIO->Media->MediaId, ExtCurrent, 512, SectorBuffer); + Status = refit_call5_wrapper(BlockIO->WriteBlocks, BlockIO, BlockIO->Media->MediaId, ExtCurrent, 512, SectorBuffer); if (EFI_ERROR(Status)) return Status; @@ -1005,10 +1006,11 @@ if (!Parent) { if (HandleType[Index] & EFI_HANDLE_TYPE_DEVICE_HANDLE) { - Status = BS->ConnectController(AllHandleBuffer[Index], - NULL, - NULL, - TRUE); + Status = refit_call4_wrapper(BS->ConnectController, + AllHandleBuffer[Index], + NULL, + NULL, + TRUE); } } } @@ -1071,7 +1073,7 @@ MainMenu.TimeoutSeconds = GlobalConfig.Timeout; // disable EFI watchdog timer - BS->SetWatchdogTimer(0x0000, 0x0000, 0x0000, NULL); + refit_call4_wrapper(BS->SetWatchdogTimer, 0x0000, 0x0000, 0x0000, NULL); // further bootstrap (now with config available) SetupScreen(); @@ -1120,13 +1122,13 @@ case TAG_RESET: // Restart TerminateScreen(); - RT->ResetSystem(EfiResetCold, EFI_SUCCESS, 0, NULL); + refit_call4_wrapper(RT->ResetSystem, EfiResetCold, EFI_SUCCESS, 0, NULL); MainLoopRunning = FALSE; // just in case we get this far break; case TAG_SHUTDOWN: // Shut Down TerminateScreen(); - RT->ResetSystem(EfiResetShutdown, EFI_SUCCESS, 0, NULL); + refit_call4_wrapper(RT->ResetSystem, EfiResetShutdown, EFI_SUCCESS, 0, NULL); MainLoopRunning = FALSE; // just in case we get this far break; @@ -1151,7 +1153,7 @@ // If we end up here, things have gone wrong. Try to reboot, and if that // fails, go into an endless loop. - RT->ResetSystem(EfiResetCold, EFI_SUCCESS, 0, NULL); + refit_call4_wrapper(RT->ResetSystem, EfiResetCold, EFI_SUCCESS, 0, NULL); EndlessIdleLoop(); return EFI_SUCCESS; Index: refit-0.14/refit/menu.c =================================================================== --- refit-0.14.orig/refit/menu.c 2010-04-21 17:27:19.361289004 +0200 +++ refit-0.14/refit/menu.c 2010-04-21 17:53:21.007477528 +0200 @@ -35,6 +35,7 @@ */ #include "lib.h" +#include "refit_call_wrapper.h" #include "egemb_back_selected_small.h" @@ -363,17 +364,17 @@ } // read key press (and wait for it if applicable) - Status = ST->ConIn->ReadKeyStroke(ST->ConIn, &key); + Status = refit_call2_wrapper(ST->ConIn->ReadKeyStroke, ST->ConIn, &key); if (Status == EFI_NOT_READY) { if (HaveTimeout && TimeoutCountdown == 0) { // timeout expired MenuExit = MENU_EXIT_TIMEOUT; break; } else if (HaveTimeout) { - BS->Stall(100000); + refit_call1_wrapper(BS->Stall, 100000); TimeoutCountdown--; } else - BS->WaitForEvent(1, &ST->ConIn->WaitForKey, &index); + refit_call3_wrapper(BS->WaitForEvent, 1, &ST->ConIn->WaitForKey, &index); continue; } if (HaveTimeout) { @@ -486,10 +487,10 @@ // initial painting BeginTextScreen(Screen->Title); if (Screen->InfoLineCount > 0) { - ST->ConOut->SetAttribute(ST->ConOut, ATTR_BASIC); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_BASIC); for (i = 0; i < (INTN)Screen->InfoLineCount; i++) { - ST->ConOut->SetCursorPosition(ST->ConOut, 3, 4 + i); - ST->ConOut->OutputString(ST->ConOut, Screen->InfoLines[i]); + refit_call3_wrapper(ST->ConOut->SetCursorPosition, ST->ConOut, 3, 4 + i); + refit_call2_wrapper(ST->ConOut->OutputString, ST->ConOut, Screen->InfoLines[i]); } } @@ -506,50 +507,50 @@ // paint the whole screen (initially and after scrolling) for (i = 0; i <= State->MaxIndex; i++) { if (i >= State->FirstVisible && i <= State->LastVisible) { - ST->ConOut->SetCursorPosition(ST->ConOut, 2, MenuPosY + (i - State->FirstVisible)); + refit_call3_wrapper(ST->ConOut->SetCursorPosition, ST->ConOut, 2, MenuPosY + (i - State->FirstVisible)); if (i == State->CurrentSelection) - ST->ConOut->SetAttribute(ST->ConOut, ATTR_CHOICE_CURRENT); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_CHOICE_CURRENT); else - ST->ConOut->SetAttribute(ST->ConOut, ATTR_CHOICE_BASIC); - ST->ConOut->OutputString(ST->ConOut, DisplayStrings[i]); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_CHOICE_BASIC); + refit_call2_wrapper(ST->ConOut->OutputString, ST->ConOut, DisplayStrings[i]); } } // scrolling indicators - ST->ConOut->SetAttribute(ST->ConOut, ATTR_SCROLLARROW); - ST->ConOut->SetCursorPosition(ST->ConOut, 0, MenuPosY); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_SCROLLARROW); + refit_call3_wrapper(ST->ConOut->SetCursorPosition, ST->ConOut, 0, MenuPosY); if (State->FirstVisible > 0) - ST->ConOut->OutputString(ST->ConOut, ArrowUp); + refit_call2_wrapper(ST->ConOut->OutputString, ST->ConOut, ArrowUp); else - ST->ConOut->OutputString(ST->ConOut, L" "); - ST->ConOut->SetCursorPosition(ST->ConOut, 0, MenuPosY + State->MaxVisible); + refit_call2_wrapper(ST->ConOut->OutputString, ST->ConOut, L" "); + refit_call3_wrapper(ST->ConOut->SetCursorPosition, ST->ConOut, 0, MenuPosY + State->MaxVisible); if (State->LastVisible < State->MaxIndex) - ST->ConOut->OutputString(ST->ConOut, ArrowDown); + refit_call2_wrapper(ST->ConOut->OutputString, ST->ConOut, ArrowDown); else - ST->ConOut->OutputString(ST->ConOut, L" "); + refit_call2_wrapper(ST->ConOut->OutputString, ST->ConOut, L" "); break; case MENU_FUNCTION_PAINT_SELECTION: // redraw selection cursor - ST->ConOut->SetCursorPosition(ST->ConOut, 2, MenuPosY + (State->LastSelection - State->FirstVisible)); - ST->ConOut->SetAttribute(ST->ConOut, ATTR_CHOICE_BASIC); - ST->ConOut->OutputString(ST->ConOut, DisplayStrings[State->LastSelection]); - ST->ConOut->SetCursorPosition(ST->ConOut, 2, MenuPosY + (State->CurrentSelection - State->FirstVisible)); - ST->ConOut->SetAttribute(ST->ConOut, ATTR_CHOICE_CURRENT); - ST->ConOut->OutputString(ST->ConOut, DisplayStrings[State->CurrentSelection]); + refit_call3_wrapper(ST->ConOut->SetCursorPosition, ST->ConOut, 2, MenuPosY + (State->LastSelection - State->FirstVisible)); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_CHOICE_BASIC); + refit_call2_wrapper(ST->ConOut->OutputString, ST->ConOut, DisplayStrings[State->LastSelection]); + refit_call3_wrapper(ST->ConOut->SetCursorPosition, ST->ConOut, 2, MenuPosY + (State->CurrentSelection - State->FirstVisible)); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_CHOICE_CURRENT); + refit_call2_wrapper(ST->ConOut->OutputString, ST->ConOut, DisplayStrings[State->CurrentSelection]); break; case MENU_FUNCTION_PAINT_TIMEOUT: if (ParamText[0] == 0) { // clear message - ST->ConOut->SetAttribute(ST->ConOut, ATTR_BASIC); - ST->ConOut->SetCursorPosition(ST->ConOut, 0, ConHeight - 1); - ST->ConOut->OutputString(ST->ConOut, BlankLine + 1); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_BASIC); + refit_call3_wrapper(ST->ConOut->SetCursorPosition, ST->ConOut, 0, ConHeight - 1); + refit_call2_wrapper(ST->ConOut->OutputString, ST->ConOut, BlankLine + 1); } else { // paint or update message - ST->ConOut->SetAttribute(ST->ConOut, ATTR_ERROR); - ST->ConOut->SetCursorPosition(ST->ConOut, 3, ConHeight - 1); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_ERROR); + refit_call3_wrapper(ST->ConOut->SetCursorPosition, ST->ConOut, 3, ConHeight - 1); TimeoutMessage = PoolPrint(L"%s ", ParamText); - ST->ConOut->OutputString(ST->ConOut, TimeoutMessage); + refit_call2_wrapper(ST->ConOut->OutputString, ST->ConOut, TimeoutMessage); FreePool(TimeoutMessage); } break; @@ -640,6 +641,7 @@ EntriesPosX, EntriesPosY + i * TEXT_LINE_HEIGHT); } // TODO: account for scrolling + // TODO: refit_callX_wrapper() if this code gets enabled someday /* for (i = 0; i <= State->MaxIndex; i++) { if (i >= State->FirstVisible && i <= State->LastVisible) { @@ -673,6 +675,7 @@ DrawMenuText(Screen->Entries[State->CurrentSelection]->Title, MenuWidth, EntriesPosX, EntriesPosY + State->CurrentSelection * TEXT_LINE_HEIGHT); // TODO: account for scrolling + // TODO: refit_callX_wrapper() if this code gets enabled someday /* ST->ConOut->SetCursorPosition(ST->ConOut, 2, 4 + (State->LastSelection - State->FirstVisible)); ST->ConOut->SetAttribute(ST->ConOut, ATTR_CHOICE_BASIC); Index: refit-0.14/refit/screen.c =================================================================== --- refit-0.14.orig/refit/screen.c 2010-04-21 17:27:19.370289076 +0200 +++ refit-0.14/refit/screen.c 2010-04-21 17:57:52.714969526 +0200 @@ -35,6 +35,7 @@ */ #include "lib.h" +#include "refit_call_wrapper.h" #include "egemb_refit_banner.h" @@ -85,10 +86,10 @@ GraphicsScreenDirty = TRUE; // disable cursor - ST->ConOut->EnableCursor(ST->ConOut, FALSE); + refit_call2_wrapper(ST->ConOut->EnableCursor, ST->ConOut, FALSE); // get size of text console - if (ST->ConOut->QueryMode(ST->ConOut, ST->ConOut->Mode->Mode, &ConWidth, &ConHeight) != EFI_SUCCESS) { + if (refit_call4_wrapper(ST->ConOut->QueryMode, ST->ConOut, ST->ConOut->Mode->Mode, &ConWidth, &ConHeight) != EFI_SUCCESS) { // use default values on error ConWidth = 80; ConHeight = 25; @@ -122,7 +123,7 @@ static VOID SwitchToText(IN BOOLEAN CursorEnabled) { egSetGraphicsModeEnabled(FALSE); - ST->ConOut->EnableCursor(ST->ConOut, CursorEnabled); + refit_call2_wrapper(ST->ConOut->EnableCursor, ST->ConOut, CursorEnabled); } static VOID SwitchToGraphics(VOID) @@ -194,11 +195,11 @@ VOID TerminateScreen(VOID) { // clear text screen - ST->ConOut->SetAttribute(ST->ConOut, ATTR_BASIC); - ST->ConOut->ClearScreen(ST->ConOut); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_BASIC); + refit_call1_wrapper(ST->ConOut->ClearScreen, ST->ConOut); // enable cursor - ST->ConOut->EnableCursor(ST->ConOut, TRUE); + refit_call2_wrapper(ST->ConOut->EnableCursor, ST->ConOut, TRUE); } static VOID DrawScreenHeader(IN CHAR16 *Title) @@ -206,23 +207,23 @@ UINTN y; // clear to black background - ST->ConOut->SetAttribute(ST->ConOut, ATTR_BASIC); - ST->ConOut->ClearScreen(ST->ConOut); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_BASIC); + refit_call1_wrapper(ST->ConOut->ClearScreen, ST->ConOut); // paint header background - ST->ConOut->SetAttribute(ST->ConOut, ATTR_BANNER); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_BANNER); for (y = 0; y < 3; y++) { - ST->ConOut->SetCursorPosition(ST->ConOut, 0, y); + refit_call3_wrapper(ST->ConOut->SetCursorPosition, ST->ConOut, 0, y); Print(BlankLine); } // print header text - ST->ConOut->SetCursorPosition(ST->ConOut, 3, 1); + refit_call3_wrapper(ST->ConOut->SetCursorPosition, ST->ConOut, 3, 1); Print(L"rEFIt - %s", Title); // reposition cursor - ST->ConOut->SetAttribute(ST->ConOut, ATTR_BASIC); - ST->ConOut->SetCursorPosition(ST->ConOut, 0, 4); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_BASIC); + refit_call3_wrapper(ST->ConOut->SetCursorPosition, ST->ConOut, 0, 4); } // @@ -237,7 +238,7 @@ GotKeyStrokes = FALSE; for (;;) { - Status = ST->ConIn->ReadKeyStroke(ST->ConIn, &key); + Status = refit_call2_wrapper(ST->ConIn->ReadKeyStroke, ST->ConIn, &key); if (Status == EFI_SUCCESS) { GotKeyStrokes = TRUE; continue; @@ -254,11 +255,11 @@ Print(L"\n* Hit any key to continue *"); if (ReadAllKeyStrokes()) { // remove buffered key strokes - BS->Stall(5000000); // 5 seconds delay + refit_call1_wrapper(BS->Stall, 5000000); // 5 seconds delay ReadAllKeyStrokes(); // empty the buffer again } - BS->WaitForEvent(1, &ST->ConIn->WaitForKey, &index); + refit_call3_wrapper(BS->WaitForEvent, 1, &ST->ConIn->WaitForKey, &index); ReadAllKeyStrokes(); // empty the buffer to protect the menu Print(L"\n"); @@ -282,7 +283,7 @@ for (;;) { ReadAllKeyStrokes(); - BS->WaitForEvent(1, &ST->ConIn->WaitForKey, &index); + refit_call3_wrapper(BS->WaitForEvent, 1, &ST->ConIn->WaitForKey, &index); } } @@ -298,9 +299,9 @@ return FALSE; StatusToString(ErrorName, Status); - ST->ConOut->SetAttribute(ST->ConOut, ATTR_ERROR); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_ERROR); Print(L"Fatal Error: %s %s\n", ErrorName, where); - ST->ConOut->SetAttribute(ST->ConOut, ATTR_BASIC); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_BASIC); haveError = TRUE; //BS->Exit(ImageHandle, ExitStatus, ExitDataSize, ExitData); @@ -316,9 +317,9 @@ return FALSE; StatusToString(ErrorName, Status); - ST->ConOut->SetAttribute(ST->ConOut, ATTR_ERROR); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_ERROR); Print(L"Error: %s %s\n", ErrorName, where); - ST->ConOut->SetAttribute(ST->ConOut, ATTR_BASIC); + refit_call2_wrapper(ST->ConOut->SetAttribute, ST->ConOut, ATTR_BASIC); haveError = TRUE; return TRUE; debian/patches/gptsync_uefi_call_wrapper.patch0000644000000000000000000000575111455320607017103 0ustar Description: Wrap EFI API calls with refit_callX_wrapper() Mandatory for GNU EFI especially on x86_64. Author: Julien BLACHE Index: refit-0.14/gptsync/os_efi.c =================================================================== --- refit-0.14.orig/gptsync/os_efi.c 2010-04-21 17:50:57.003287667 +0200 +++ refit-0.14/gptsync/os_efi.c 2010-04-21 17:52:03.555523286 +0200 @@ -35,6 +35,7 @@ */ #include "gptsync.h" +#include "refit_call_wrapper.h" // variables @@ -48,7 +49,7 @@ { EFI_STATUS Status; - Status = BlockIO->ReadBlocks(BlockIO, BlockIO->Media->MediaId, lba, 512, buffer); + Status = refit_call5_wrapper(BlockIO->ReadBlocks, BlockIO, BlockIO->Media->MediaId, lba, 512, buffer); if (EFI_ERROR(Status)) { // TODO: report error return 1; @@ -60,7 +61,7 @@ { EFI_STATUS Status; - Status = BlockIO->WriteBlocks(BlockIO, BlockIO->Media->MediaId, lba, 512, buffer); + Status = refit_call5_wrapper(BlockIO->WriteBlocks, BlockIO, BlockIO->Media->MediaId, lba, 512, buffer); if (EFI_ERROR(Status)) { // TODO: report error return 1; @@ -80,7 +81,7 @@ GotKeyStrokes = FALSE; for (;;) { - Status = ST->ConIn->ReadKeyStroke(ST->ConIn, &Key); + Status = refit_call2_wrapper(ST->ConIn->ReadKeyStroke, ST->ConIn, &Key); if (Status == EFI_SUCCESS) { GotKeyStrokes = TRUE; continue; @@ -97,11 +98,11 @@ Print(L"\n* Hit any key to continue *"); if (ReadAllKeyStrokes()) { // remove buffered key strokes - BS->Stall(5000000); // 5 seconds delay + refit_call1_wrapper(BS->Stall, 5000000); // 5 seconds delay ReadAllKeyStrokes(); // empty the buffer again } - BS->WaitForEvent(1, &ST->ConIn->WaitForKey, &Index); + refit_call3_wrapper(BS->WaitForEvent, 1, &ST->ConIn->WaitForKey, &Index); ReadAllKeyStrokes(); // empty the buffer to protect the menu Print(L"\n"); @@ -116,12 +117,12 @@ Print(prompt); if (ReadAllKeyStrokes()) { // remove buffered key strokes - BS->Stall(500000); // 0.5 seconds delay + refit_call1_wrapper(BS->Stall, 500000); // 0.5 seconds delay ReadAllKeyStrokes(); // empty the buffer again } - BS->WaitForEvent(1, &ST->ConIn->WaitForKey, &Index); - Status = ST->ConIn->ReadKeyStroke(ST->ConIn, &Key); + refit_call3_wrapper(BS->WaitForEvent, 1, &ST->ConIn->WaitForKey, &Index); + Status = refit_call2_wrapper(ST->ConIn->ReadKeyStroke, ST->ConIn, &Key); if (EFI_ERROR(Status)) return 1; @@ -222,7 +223,7 @@ if (!Usable) continue; - Status = BS->HandleProtocol(DeviceHandle, &BlockIoProtocol, (VOID **) &BlockIO); + Status = refit_call3_wrapper(BS->HandleProtocol, DeviceHandle, &BlockIoProtocol, (VOID **) &BlockIO); if (EFI_ERROR(Status)) { // TODO: report error BlockIO = NULL; debian/patches/disable_EFI110_features.patch0000644000000000000000000000157011455320607016052 0ustar Description: Disable features that require EFI110 gnu-efi doesn't support EFI 1.10, so disable anything that requires it. Author: Julien BLACHE Index: refit-0.14/refit/main.c =================================================================== --- refit-0.14.orig/refit/main.c 2010-04-19 18:38:11.930932047 +0200 +++ refit-0.14/refit/main.c 2010-04-19 18:37:59.327931990 +0200 @@ -925,6 +925,8 @@ } } + +#ifdef DEBIAN_ENABLE_EFI110 // // pre-boot driver functions // @@ -1036,6 +1038,7 @@ // connect all devices ConnectAllDriversToAllControllers(); } +#endif /* DEBIAN_ENABLE_EFI110 */ // // main entry point @@ -1072,7 +1075,9 @@ // further bootstrap (now with config available) SetupScreen(); +#ifdef DEBIAN_ENABLE_EFI110 LoadDrivers(); +#endif /* DEBIAN_ENABLE_EFI110 */ ScanVolumes(); DebugPause(); debian/patches/gptsync_dont_truncate.patch0000644000000000000000000001612611455320607016267 0ustar Description: Do not truncate partitions starting or extending beyond 2 TiB. Ignore such partitions by default, and introduce a -t switch to force including and truncating such partitions. Author: Julien BLACHE Index: refit-0.14/gptsync/gptsync.8 =================================================================== --- refit-0.14.orig/gptsync/gptsync.8 2010-04-19 18:34:09.877931491 +0200 +++ refit-0.14/gptsync/gptsync.8 2010-04-19 18:34:01.920932376 +0200 @@ -4,7 +4,7 @@ .SH SYNOPSIS .B gptsync -[\fI\-q\fR] \fIdevice\fR +[\fI\-q\fR] [\fI\-t\fR] \fIdevice\fR .SH DESCRIPTION .B gptsync @@ -20,6 +20,10 @@ .TP \fB\-q\fR Do not print any message, do not prompt to modify the MBR. +.TP +\fB\-t\fR +Truncate partitions starting or expending beyond 2 TiB (MBR limitation). +Default is to ignore such partitions. .SH AUTHOR \fBgptsync\fR was written by Christoph Pfisterer. Index: refit-0.14/gptsync/gptsync.c =================================================================== --- refit-0.14.orig/gptsync/gptsync.c 2010-04-19 18:34:09.912932056 +0200 +++ refit-0.14/gptsync/gptsync.c 2010-04-19 18:34:01.921931396 +0200 @@ -38,6 +38,8 @@ #include "syslinux_mbr.h" +BOOLEAN truncate_2tb = FALSE; + // // MBR functions // @@ -121,14 +123,14 @@ lba = new_mbr_parts[k].start_lba; if (lba > 0xffffffffULL) { - Print(L"Warning: Partition %d starts beyond 2 TiB limit\n", i+1); + Print(L"Warning: Partition %d truncated, starts beyond 2 TiB limit\n", i+1); lba = 0xffffffffULL; } table[i].start_lba = (UINT32)lba; lba = new_mbr_parts[k].end_lba + 1 - new_mbr_parts[k].start_lba; if (lba > 0xffffffffULL) { - Print(L"Warning: Partition %d extends beyond 2 TiB limit\n", i+1); + Print(L"Warning: Partition %d truncated, extends beyond 2 TiB limit\n", i+1); lba = 0xffffffffULL; } table[i].size = (UINT32)lba; @@ -222,6 +224,8 @@ UINTN i, k, iter, count_active, detected_parttype; CHARN *fsname; UINT64 min_start_lba; + UINT64 lba; + UINTN ignored_2tb; UINTN status; BOOLEAN have_esp; @@ -310,7 +314,7 @@ action = ACTION_NONE; } } - + if (action == ACTION_NOP) { Print(L"Status: Tables are synchronized, no need to sync.\n"); return 0; @@ -344,7 +348,26 @@ // add other GPT partitions until the table is full // TODO: in the future, prioritize partitions by kind + ignored_2tb = 0; for (; i < gpt_part_count && new_mbr_part_count < 4; i++) { + if (!truncate_2tb) { + lba = gpt_parts[i].start_lba; + if (lba > 0xffffffffULL) { + Print(L"Warning: GPT partition %d starts beyond 2 TiB limit, ignoring\n", i+1); + + ignored_2tb++; + continue; + } + + lba = gpt_parts[i].end_lba + 1 - gpt_parts[i].start_lba; + if (lba > 0xffffffffULL) { + Print(L"Warning: GPT partition %d extends beyond 2 TiB limit, ignoring\n", i+1); + + ignored_2tb++; + continue; + } + } + new_mbr_parts[new_mbr_part_count].index = new_mbr_part_count; new_mbr_parts[new_mbr_part_count].start_lba = gpt_parts[i].start_lba; new_mbr_parts[new_mbr_part_count].end_lba = gpt_parts[i].end_lba; @@ -409,6 +432,11 @@ } } } + + if (ignored_2tb > 0) { + Print(L"\n**** %d partitions ignored because of 2 TiB limitation\n", ignored_2tb); + Print(L"**** Re-run gptsync with -t to include and truncate the affected partitions\n"); + } // dump table Print(L"\nProposed new MBR partition table:\n"); Index: refit-0.14/gptsync/gptsync.h =================================================================== --- refit-0.14.orig/gptsync/gptsync.h 2010-04-19 18:34:10.047931802 +0200 +++ refit-0.14/gptsync/gptsync.h 2010-04-19 18:34:01.921931396 +0200 @@ -211,6 +211,7 @@ // // actual platform-independent programs // +extern BOOLEAN truncate_2tb; UINTN gptsync(VOID); UINTN showpart(VOID); Index: refit-0.14/gptsync/os_efi.c =================================================================== --- refit-0.14.orig/gptsync/os_efi.c 2010-04-19 18:34:09.957932155 +0200 +++ refit-0.14/gptsync/os_efi.c 2010-04-19 18:34:01.921931396 +0200 @@ -154,9 +154,43 @@ EFI_HANDLE DeviceHandle; EFI_DEVICE_PATH *DevicePath, *NextDevicePath; BOOLEAN Usable; + EFI_LOADED_IMAGE *info; + CHAR16 *args; + CHAR16 *argp; InitializeLib(ImageHandle, SystemTable); - + + // check arguments + // For now there's only one, if we need more arguments, + // something more complicated will be (badly) needed + Status = refit_call3_wrapper(BS->HandleProtocol, ImageHandle, &LoadedImageProtocol, (VOID **)&info); + if (EFI_ERROR(Status)) { + Print(L"LoadedImageProtocol not supported"); + return EFI_LOAD_ERROR; + } + + args = AllocateZeroPool(info->LoadOptionsSize + sizeof(CHAR16)); + if (args == NULL) { + Print(L"Allocation failed for arguments"); + return EFI_OUT_OF_RESOURCES; + } + CopyMem(args, info->LoadOptions, info->LoadOptionsSize); + + argp = args; + // skip image name + while ((*argp != L' ') && (*argp != CHAR_NULL)) + argp++; + + // skip spaces + while ((*argp == L' ') && (*argp != CHAR_NULL)) + argp++; + + if (StrnCmp(L"-t", argp, 2) == 0) { + truncate_2tb = TRUE; + } + + FreePool(args); + Status = LibLocateHandle(ByProtocol, &BlockIoProtocol, NULL, &HandleCount, &HandleBuffer); if (EFI_ERROR (Status)) { Index: refit-0.14/gptsync/os_unix.c =================================================================== --- refit-0.14.orig/gptsync/os_unix.c 2010-04-19 18:34:10.004932098 +0200 +++ refit-0.14/gptsync/os_unix.c 2010-04-19 18:34:01.922931322 +0200 @@ -192,8 +192,9 @@ void usage(void) { #ifdef GPTSYNC - fprintf(stderr, "Usage: " PROGNAME_S " [-q] \n"); + fprintf(stderr, "Usage: " PROGNAME_S " [-q] [-t] \n"); fprintf(stderr, "\t-q\tquiet mode\n"); + fprintf(stderr, "\t-t\ttruncate partitions affected by 2 TiB limitation\n"); #elif defined(SHOWPART) @@ -216,30 +217,37 @@ // argument check #ifdef GPTSYNC - switch (argc) + int opt; + + while ((opt = getopt(argc, argv, "qt")) != -1) { - case 2: - filename = argv[1]; - break; - case 3: - if (strncmp("-q", argv[1], 2) != 0) - { + switch (opt) + { + case 'q': + quiet = 1; + break; + case 't': + truncate_2tb = TRUE; + break; + default: usage(); return 1; - } - quiet = 1; - filename = argv[2]; - break; - default: - usage(); - return 1; + } } + if (optind >= argc) { + error("Missing device name"); + usage(); + return 1; + } + + filename = argv[optind]; + #elif defined(SHOWPART) if (argc != 2) { - usage(); - return 1; + usage(); + return 1; } filename = argv[1]; #endif debian/patches/libeg_uefi_call_wrapper.patch0000644000000000000000000001772611455320607016503 0ustar Description: Wrap EFI API calls with refit_callX_wrapper() Mandatory for GNU EFI especially on x86_64. Author: Julien BLACHE Index: refit-0.14/libeg/image.c =================================================================== --- refit-0.14.orig/libeg/image.c 2010-04-21 17:17:45.197289081 +0200 +++ refit-0.14/libeg/image.c 2010-04-21 17:54:04.778634048 +0200 @@ -35,6 +35,7 @@ */ #include "libegint.h" +#include "refit_call_wrapper.h" #define MAX_FILE_SIZE (1024*1024*1024) @@ -108,13 +109,13 @@ UINTN BufferSize; UINT8 *Buffer; - Status = BaseDir->Open(BaseDir, &FileHandle, FileName, EFI_FILE_MODE_READ, 0); + Status = refit_call5_wrapper(BaseDir->Open, BaseDir, &FileHandle, FileName, EFI_FILE_MODE_READ, 0); if (EFI_ERROR(Status)) return Status; FileInfo = LibFileInfo(FileHandle); if (FileInfo == NULL) { - FileHandle->Close(FileHandle); + refit_call1_wrapper(FileHandle->Close, FileHandle); return EFI_NOT_FOUND; } ReadSize = FileInfo->FileSize; @@ -125,12 +126,12 @@ BufferSize = (UINTN)ReadSize; // was limited to 1 GB above, so this is safe Buffer = (UINT8 *) AllocatePool(BufferSize); if (Buffer == NULL) { - FileHandle->Close(FileHandle); + refit_call1_wrapper(FileHandle->Close, FileHandle); return EFI_OUT_OF_RESOURCES; } - Status = FileHandle->Read(FileHandle, &BufferSize, Buffer); - FileHandle->Close(FileHandle); + Status = refit_call3_wrapper(FileHandle->Read, FileHandle, &BufferSize, Buffer); + refit_call1_wrapper(FileHandle->Close, FileHandle); if (EFI_ERROR(Status)) { FreePool(Buffer); return Status; @@ -172,14 +173,14 @@ return Status; } - Status = BaseDir->Open(BaseDir, &FileHandle, FileName, + Status = refit_call5_wrapper(BaseDir->Open, BaseDir, &FileHandle, FileName, EFI_FILE_MODE_READ | EFI_FILE_MODE_WRITE | EFI_FILE_MODE_CREATE, 0); if (EFI_ERROR(Status)) return Status; BufferSize = FileDataLength; - Status = FileHandle->Write(FileHandle, &BufferSize, FileData); - FileHandle->Close(FileHandle); + Status = refit_call3_wrapper(FileHandle->Write, FileHandle, &BufferSize, FileData); + refit_call1_wrapper(FileHandle->Close, FileHandle); return Status; } Index: refit-0.14/libeg/screen.c =================================================================== --- refit-0.14.orig/libeg/screen.c 2010-04-21 17:17:45.206289372 +0200 +++ refit-0.14/libeg/screen.c 2010-04-21 17:54:14.843705010 +0200 @@ -35,9 +35,10 @@ */ #include "libegint.h" +#include "refit_call_wrapper.h" #include -#include +/* #include */ #include // Console defines and variables @@ -84,7 +85,7 @@ egScreenHeight = GraphicsOutput->Mode->Info->VerticalResolution; egHasGraphics = TRUE; } else if (UgaDraw != NULL) { - Status = UgaDraw->GetMode(UgaDraw, &UGAWidth, &UGAHeight, &UGADepth, &UGARefreshRate); + Status = refit_call5_wrapper(UgaDraw->GetMode, UgaDraw, &UGAWidth, &UGAHeight, &UGADepth, &UGARefreshRate); if (EFI_ERROR(Status)) { UgaDraw = NULL; // graphics not available } else { @@ -130,7 +131,7 @@ EFI_CONSOLE_CONTROL_SCREEN_MODE CurrentMode; if (ConsoleControl != NULL) { - ConsoleControl->GetMode(ConsoleControl, &CurrentMode, NULL, NULL); + refit_call4_wrapper(ConsoleControl->GetMode, ConsoleControl, &CurrentMode, NULL, NULL); return (CurrentMode == EfiConsoleControlScreenGraphics) ? TRUE : FALSE; } @@ -143,12 +144,12 @@ EFI_CONSOLE_CONTROL_SCREEN_MODE NewMode; if (ConsoleControl != NULL) { - ConsoleControl->GetMode(ConsoleControl, &CurrentMode, NULL, NULL); + refit_call4_wrapper(ConsoleControl->GetMode, ConsoleControl, &CurrentMode, NULL, NULL); NewMode = Enable ? EfiConsoleControlScreenGraphics : EfiConsoleControlScreenText; if (CurrentMode != NewMode) - ConsoleControl->SetMode(ConsoleControl, NewMode); + refit_call2_wrapper(ConsoleControl->SetMode, ConsoleControl, NewMode); } } @@ -172,10 +173,10 @@ // EFI_GRAPHICS_OUTPUT_BLT_PIXEL and EFI_UGA_PIXEL have the same // layout, and the header from TianoCore actually defines them // to be the same type. - GraphicsOutput->Blt(GraphicsOutput, (EFI_GRAPHICS_OUTPUT_BLT_PIXEL *)&FillColor, EfiBltVideoFill, + refit_call10_wrapper(GraphicsOutput->Blt, GraphicsOutput, (EFI_GRAPHICS_OUTPUT_BLT_PIXEL *)&FillColor, EfiBltVideoFill, 0, 0, 0, 0, egScreenWidth, egScreenHeight, 0); } else if (UgaDraw != NULL) { - UgaDraw->Blt(UgaDraw, &FillColor, EfiUgaVideoFill, + refit_call10_wrapper(UgaDraw->Blt, UgaDraw, &FillColor, EfiUgaVideoFill, 0, 0, 0, 0, egScreenWidth, egScreenHeight, 0); } } @@ -191,10 +192,10 @@ } if (GraphicsOutput != NULL) { - GraphicsOutput->Blt(GraphicsOutput, (EFI_GRAPHICS_OUTPUT_BLT_PIXEL *)Image->PixelData, EfiBltBufferToVideo, + refit_call10_wrapper(GraphicsOutput->Blt, GraphicsOutput, (EFI_GRAPHICS_OUTPUT_BLT_PIXEL *)Image->PixelData, EfiBltBufferToVideo, 0, 0, ScreenPosX, ScreenPosY, Image->Width, Image->Height, 0); } else if (UgaDraw != NULL) { - UgaDraw->Blt(UgaDraw, (EFI_UGA_PIXEL *)Image->PixelData, EfiUgaBltBufferToVideo, + refit_call10_wrapper(UgaDraw->Blt, UgaDraw, (EFI_UGA_PIXEL *)Image->PixelData, EfiUgaBltBufferToVideo, 0, 0, ScreenPosX, ScreenPosY, Image->Width, Image->Height, 0); } } @@ -217,10 +218,10 @@ } if (GraphicsOutput != NULL) { - GraphicsOutput->Blt(GraphicsOutput, (EFI_GRAPHICS_OUTPUT_BLT_PIXEL *)Image->PixelData, EfiBltBufferToVideo, + refit_call10_wrapper(GraphicsOutput->Blt, GraphicsOutput, (EFI_GRAPHICS_OUTPUT_BLT_PIXEL *)Image->PixelData, EfiBltBufferToVideo, AreaPosX, AreaPosY, ScreenPosX, ScreenPosY, AreaWidth, AreaHeight, Image->Width * 4); } else if (UgaDraw != NULL) { - UgaDraw->Blt(UgaDraw, (EFI_UGA_PIXEL *)Image->PixelData, EfiUgaBltBufferToVideo, + refit_call10_wrapper(UgaDraw->Blt, UgaDraw, (EFI_UGA_PIXEL *)Image->PixelData, EfiUgaBltBufferToVideo, AreaPosX, AreaPosY, ScreenPosX, ScreenPosY, AreaWidth, AreaHeight, Image->Width * 4); } } @@ -249,10 +250,10 @@ // get full screen image if (GraphicsOutput != NULL) { - GraphicsOutput->Blt(GraphicsOutput, (EFI_GRAPHICS_OUTPUT_BLT_PIXEL *)Image->PixelData, EfiBltVideoToBltBuffer, + refit_call10_wrapper(GraphicsOutput->Blt, GraphicsOutput, (EFI_GRAPHICS_OUTPUT_BLT_PIXEL *)Image->PixelData, EfiBltVideoToBltBuffer, 0, 0, 0, 0, Image->Width, Image->Height, 0); } else if (UgaDraw != NULL) { - UgaDraw->Blt(UgaDraw, (EFI_UGA_PIXEL *)Image->PixelData, EfiUgaVideoToBltBuffer, + refit_call10_wrapper(UgaDraw->Blt, UgaDraw, (EFI_UGA_PIXEL *)Image->PixelData, EfiUgaVideoToBltBuffer, 0, 0, 0, 0, Image->Width, Image->Height, 0); } @@ -277,7 +278,7 @@ // DEBUG: switch to text mode bailout_wait: egSetGraphicsModeEnabled(FALSE); - BS->WaitForEvent(1, &ST->ConIn->WaitForKey, &Index); + refit_call3_wrapper(BS->WaitForEvent, 1, &ST->ConIn->WaitForKey, &Index); } /* EOF */ Index: refit-0.14/libeg/Makefile =================================================================== --- refit-0.14.orig/libeg/Makefile 2010-04-21 17:56:13.077289365 +0200 +++ refit-0.14/libeg/Makefile 2010-04-21 17:56:11.994733579 +0200 @@ -7,7 +7,7 @@ VPATH = $(SRCDIR) -LOCAL_CPPFLAGS = -I$(SRCDIR) +LOCAL_CPPFLAGS = -I$(SRCDIR) -I$(SRCDIR)/../include OBJS = screen.o image.o text.o load_bmp.o load_icns.o TARGET = libeg.a debian/patches/debian_version_string.patch0000644000000000000000000000275511455320607016227 0ustar Description: Add the Debian version in the version string Display the Debian package version in the About menu, making it easy and straightforward to identify a Debian build of rEFIt and its exact version. Author: Julien BLACHE Index: refit-0.14/refit/Makefile =================================================================== --- refit-0.14.orig/refit/Makefile 2010-04-19 18:32:19.764931838 +0200 +++ refit-0.14/refit/Makefile 2010-04-19 18:32:16.559932151 +0200 @@ -15,7 +15,7 @@ LIBEG = build64 endif -LOCAL_CPPFLAGS = -I$(SRCDIR) -I$(SRCDIR)/../include -I$(SRCDIR)/../libeg +LOCAL_CPPFLAGS = -I$(SRCDIR) -I$(SRCDIR)/../include -I$(SRCDIR)/../libeg -DDEBIAN_VERSION="L\"$(DEBVER)\"" LOCAL_LDFLAGS = -L$(SRCDIR)/../libeg/$(LIBEG) LOCAL_LIBS = -leg Index: refit-0.14/refit/main.c =================================================================== --- refit-0.14.orig/refit/main.c 2010-04-19 18:32:19.495931342 +0200 +++ refit-0.14/refit/main.c 2010-04-19 18:32:16.559932151 +0200 @@ -82,7 +82,7 @@ { if (AboutMenu.EntryCount == 0) { AboutMenu.TitleImage = BuiltinIcon(BUILTIN_ICON_FUNC_ABOUT); - AddMenuInfoLine(&AboutMenu, L"rEFIt Version 0.14"); + AddMenuInfoLine(&AboutMenu, L"rEFIt Version 0.14 " DEBIAN_VERSION); AddMenuInfoLine(&AboutMenu, L""); AddMenuInfoLine(&AboutMenu, L"Copyright (c) 2006-2010 Christoph Pfisterer"); AddMenuInfoLine(&AboutMenu, L"Portions Copyright (c) Intel Corporation and others"); debian/patches/efi_call_wrappers.patch0000644000000000000000000000500611455320607015323 0ustar Description: Add macros for wrapping EFI calls on X64 Turns out uefi_call_wrapper() needs all the arguments to be UINT64. As uefi_call_wrapper() is a function with a variable argument list and not a macro, we need an additional layer of macros as we can't cast all arguments to UINT64 on IA32... . This fixes rEFIt on X64; symptoms were missing images and error messages popping up randomly, requiring a key press or a reboot. Author: Julien BLACHE Index: refit-0.14/include/refit_call_wrapper.h =================================================================== --- /dev/null 1970-01-01 00:00:00.000000000 +0000 +++ refit-0.14/include/refit_call_wrapper.h 2010-04-21 17:25:59.526288272 +0200 @@ -0,0 +1,37 @@ +#ifndef __REFIT_CALL_WRAPPER_H__ +#define __REFIT_CALL_WRAPPER_H__ + +#ifdef EFIX64 +# define refit_call1_wrapper(f, a1) \ + uefi_call_wrapper(f, 1, (UINT64)(a1)) +# define refit_call2_wrapper(f, a1, a2) \ + uefi_call_wrapper(f, 2, (UINT64)(a1), (UINT64)(a2)) +# define refit_call3_wrapper(f, a1, a2, a3) \ + uefi_call_wrapper(f, 3, (UINT64)(a1), (UINT64)(a2), (UINT64)(a3)) +# define refit_call4_wrapper(f, a1, a2, a3, a4) \ + uefi_call_wrapper(f, 4, (UINT64)(a1), (UINT64)(a2), (UINT64)(a3), (UINT64)(a4)) +# define refit_call5_wrapper(f, a1, a2, a3, a4, a5) \ + uefi_call_wrapper(f, 5, (UINT64)(a1), (UINT64)(a2), (UINT64)(a3), (UINT64)(a4), (UINT64)(a5)) +# define refit_call6_wrapper(f, a1, a2, a3, a4, a5, a6) \ + uefi_call_wrapper(f, 6, (UINT64)(a1), (UINT64)(a2), (UINT64)(a3), (UINT64)(a4), (UINT64)(a5), (UINT64)(a6)) +# define refit_call10_wrapper(f, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10) \ + uefi_call_wrapper(f, 10, (UINT64)(a1), (UINT64)(a2), (UINT64)(a3), (UINT64)(a4), (UINT64)(a5), (UINT64)(a6), (UINT64)(a7), (UINT64)(a8), (UINT64)(a9), (UINT64)(a10)) +#else +# define refit_call1_wrapper(f, a1) \ + uefi_call_wrapper(f, 1, a1) +# define refit_call2_wrapper(f, a1, a2) \ + uefi_call_wrapper(f, 2, a1, a2) +# define refit_call3_wrapper(f, a1, a2, a3) \ + uefi_call_wrapper(f, 3, a1, a2, a3) +# define refit_call4_wrapper(f, a1, a2, a3, a4) \ + uefi_call_wrapper(f, 4, a1, a2, a3, a4) +# define refit_call5_wrapper(f, a1, a2, a3, a4, a5) \ + uefi_call_wrapper(f, 5, a1, a2, a3, a4, a5) +# define refit_call6_wrapper(f, a1, a2, a3, a4, a5, a6) \ + uefi_call_wrapper(f, 6, a1, a2, a3, a4, a5, a6) +# define refit_call10_wrapper(f, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10) \ + uefi_call_wrapper(f, 10, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10) +#endif + +#endif /* !__REFIT_CALL_WRAPPER_H__ */ + debian/patches/fat_binaries_build.patch0000644000000000000000000001127211455320607015451 0ustar Description: Support building fat EFI binaries - add support for building in a build directory (VPATH stuff) - rework previous support for ia32 builds on x86_64 - add support for x86_64 builds on ia32 Author: Julien BLACHE Index: refit-0.14/Make.common =================================================================== --- refit-0.14.orig/Make.common 2010-04-19 18:31:25.622931971 +0200 +++ refit-0.14/Make.common 2010-04-19 18:31:23.763931557 +0200 @@ -8,13 +8,15 @@ EFILIB = /usr/lib EFICRT0 = /usr/lib -ARCH = $(shell uname -m | sed s,i[3456789]86,ia32,) +HOSTARCH = $(shell uname -m | sed s,i[3456789]86,ia32,) +ARCH := $(HOSTARCH) OS = $(shell uname -s) CPPFLAGS = -I$(EFIINC) -I$(EFIINC)/$(ARCH) -I$(EFIINC)/protocol -DCONFIG_$(ARCH) OPTIMFLAGS = -O2 -fno-strict-aliasing DEBUGFLAGS = -Wall -CFLAGS = $(OPTIMFLAGS) -mcpu=i386 -fpic -fshort-wchar $(DEBUGFLAGS) +CFLAGS = $(ARCH3264) $(OPTIMFLAGS) -fpic -fshort-wchar $(DEBUGFLAGS) +ASFLAGS = $(ARCH3264) LDFLAGS = -nostdlib -znocombreloc prefix = /usr/bin/ @@ -30,6 +32,31 @@ CFLAGS += -frename-registers -mfixed-range=f32-f127 endif +ifeq ($(ARCH),x86_64) + CFLAGS += -DEFI_FUNCTION_WRAPPER -mno-red-zone + CPPFLAGS += -DEFIX64 + + ifeq ($(HOSTARCH),ia32) + ARCH3264 = -m64 + + GNUEFILIB := $(GNUEFILIB)64 + EFILIB := $(EFILIB)64 + EFICRT0 := $(EFICRT0)64 + endif +endif + +ifeq ($(ARCH),ia32) + CPPFLAGS += -DEFI32 + + ifeq ($(HOSTARCH),x86_64) + ARCH3264 = -m32 + + GNUEFILIB := $(GNUEFILIB)32 + EFILIB := $(EFILIB)32 + EFICRT0 := $(EFICRT0)32 + endif +endif + CRTOBJS = $(EFICRT0)/crt0-efi-$(ARCH).o @@ -44,7 +71,7 @@ endif LDFLAGS += -T $(LDSCRIPT) -shared -Bsymbolic -L$(EFILIB) -L$(GNUEFILIB) $(CRTOBJS) -LIBS = -lefi -lgnuefi $(shell $(CC) -print-libgcc-file-name) +LIBS = -lefi -lgnuefi $(shell $(CC) $(ARCH3264) -print-libgcc-file-name) FORMAT = efi-app-$(ARCH) Index: refit-0.14/gptsync/Makefile.gnuefi =================================================================== --- refit-0.14.orig/gptsync/Makefile.gnuefi 2010-04-19 18:31:25.483932034 +0200 +++ refit-0.14/gptsync/Makefile.gnuefi 2010-04-19 18:31:23.763931557 +0200 @@ -3,7 +3,11 @@ # Build control file for the gptsync tool # -LOCAL_CPPFLAGS = -I. -I../include -DEFI32 +SRCDIR = . + +VPATH = $(SRCDIR) + +LOCAL_CPPFLAGS = -I$(SRCDIR) -I$(SRCDIR)/../include LOCAL_LDFLAGS = LOCAL_LIBS = @@ -12,6 +16,6 @@ all: $(TARGET) -include ../Make.common +include $(SRCDIR)/../Make.common # EOF Index: refit-0.14/gptsync/Makefile.unix =================================================================== --- refit-0.14.orig/gptsync/Makefile.unix 2010-04-19 18:31:25.537931666 +0200 +++ refit-0.14/gptsync/Makefile.unix 2010-04-19 18:31:23.763931557 +0200 @@ -2,6 +2,10 @@ # Makefile for gptsync on Unix platforms # +SRCDIR = . + +VPATH = $(SRCDIR) + RM = rm -f CC = gcc @@ -11,7 +15,7 @@ SHOWPART_TARGET = showpart SHOWPART_OBJS = showpart.unix.o lib.unix.o os_unix.showpart.o -CPPFLAGS = -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I../include +CPPFLAGS = -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I$(SRCDIR)/../include CFLAGS = -Wall LDFLAGS = LIBS = Index: refit-0.14/libeg/Makefile =================================================================== --- refit-0.14.orig/libeg/Makefile 2010-04-19 18:31:25.587932151 +0200 +++ refit-0.14/libeg/Makefile 2010-04-19 18:31:23.763931557 +0200 @@ -3,13 +3,17 @@ # Build control file for the libeg library # -LOCAL_CPPFLAGS = -I. +SRCDIR = . + +VPATH = $(SRCDIR) + +LOCAL_CPPFLAGS = -I$(SRCDIR) OBJS = screen.o image.o text.o load_bmp.o load_icns.o TARGET = libeg.a all: $(TARGET) -include ../Make.common +include $(SRCDIR)/../Make.common # EOF Index: refit-0.14/refit/Makefile =================================================================== --- refit-0.14.orig/refit/Makefile 2010-04-19 18:31:25.680931776 +0200 +++ refit-0.14/refit/Makefile 2010-04-19 18:31:23.764932024 +0200 @@ -3,8 +3,20 @@ # Build control file for the rEFIt boot menu # -LOCAL_CPPFLAGS = -I. -I../include -I../libeg -LOCAL_LDFLAGS = -L../libeg +SRCDIR = . + +VPATH = $(SRCDIR) + +ifeq ($(ARCH),ia32) + LIBEG = build32 +endif + +ifeq ($(ARCH),x86_64) + LIBEG = build64 +endif + +LOCAL_CPPFLAGS = -I$(SRCDIR) -I$(SRCDIR)/../include -I$(SRCDIR)/../libeg +LOCAL_LDFLAGS = -L$(SRCDIR)/../libeg/$(LIBEG) LOCAL_LIBS = -leg OBJS = main.o config.o menu.o screen.o icns.o lib.o @@ -12,6 +24,6 @@ all: $(TARGET) -include ../Make.common +include $(SRCDIR)/../Make.common # EOF debian/patches/gptsync_biosboot.patch0000644000000000000000000000274111455320607015234 0ustar Description: Map GPT "BIOS Boot Partition" type to MBR type 0xda ("Non-FS data") This partition type is used by GRUB2 to install some parts of GRUB2. Bug-Debian: http://bugs.debian.org/545190 Author: Julien BLACHE Index: refit-0.14/gptsync/lib.c =================================================================== --- refit-0.14.orig/gptsync/lib.c 2010-04-19 18:37:22.933931755 +0200 +++ refit-0.14/gptsync/lib.c 2010-04-19 18:37:19.182590539 +0200 @@ -83,6 +83,7 @@ { 0xaf, STR("Mac OS X HFS+") }, { 0xbe, STR("Solaris Boot") }, { 0xbf, STR("Solaris") }, + { 0xda, STR("Non-FS data") }, { 0xeb, STR("BeOS") }, { 0xee, STR("EFI Protective") }, { 0xef, STR("EFI System (FAT)") }, @@ -109,7 +110,7 @@ // From Wikipedia { "\x39\x33\xA6\x8D\x07\x00\xC0\x60\xC4\x36\x08\x3A\xC8\x23\x09\x08", 0x00, STR("Linux Reserved"), GPT_KIND_SYSTEM }, // From grub2 repository, grub/include/grub/gpt_partition.h - { "\x48\x61\x68\x21\x49\x64\x6F\x6E\x74\x4E\x65\x65\x64\x45\x46\x49", 0x00, STR("GRUB2 BIOS Boot"), GPT_KIND_SYSTEM }, + { "\x48\x61\x68\x21\x49\x64\x6F\x6E\x74\x4E\x65\x65\x64\x45\x46\x49", 0xda, STR("BIOS Boot Partition"), GPT_KIND_SYSTEM }, // From FreeBSD repository, sys/sys/gpt.h { "\xB4\x7C\x6E\x51\xCF\x6E\xD6\x11\x8F\xF8\x00\x02\x2D\x09\x71\x2B", 0xa5, STR("FreeBSD Data"), GPT_KIND_DATA }, { "\xB5\x7C\x6E\x51\xCF\x6E\xD6\x11\x8F\xF8\x00\x02\x2D\x09\x71\x2B", 0x00, STR("FreeBSD Swap"), GPT_KIND_SYSTEM }, debian/patches/gptsync_manpage.patch0000644000000000000000000000336511455320607015027 0ustar Description: Rewrite parts of the manpage Better explain what gptsync is, why it's needed. Author: Julien BLACHE Index: refit-0.14/gptsync/gptsync.8 =================================================================== --- refit-0.14.orig/gptsync/gptsync.8 2010-04-19 18:33:34.024931691 +0200 +++ refit-0.14/gptsync/gptsync.8 2010-04-19 18:33:32.938931385 +0200 @@ -1,4 +1,4 @@ -.TH "gptsync" 8 "2008 May 23" "Debian" "rEFIt" +.TH "gptsync" 8 "2008 July 24" "Debian" "rEFIt" .SH NAME gptsync \- GPT partition table to MBR partition table synchronisation @@ -7,11 +7,14 @@ [\fI\-q\fR] \fIdevice\fR .SH DESCRIPTION -Reads the GPT partition table on the device and synchronise content of -MBR partition table on the device. Useful for situations (as in -mactel linux) where legacy operating systems require MBR partition -table to function properly, while most other operating systems can -work with GPT. +.B gptsync +reads the GPT partition table on \fIdevice\fR and synchronises the legacy +MBR partition table with the GPT partition table. The MBR partition table +can hold only 4 partitions. +.PP +Legacy bootloaders or operating systems that do not support GPT require an +MBR partition table; this is typically the case when using GRUB or LILO on +an Intel-based Apple machine. .SH OPTIONS .TP @@ -19,6 +22,9 @@ Do not print any message, do not prompt to modify the MBR. .SH AUTHOR -Written by Christoph Pfisterer. This manual page contributed for Debian by -Junichi Uekawa , but may be used for others. +\fBgptsync\fR was written by Christoph Pfisterer. + +This manual page was written by Junichi Uekawa and +Julien BLACHE , for the Debian Project (but may be used +by others). debian/patches/no_stack_protector.patch0000644000000000000000000000125411455320607015545 0ustar Description: Build with -fno-stack-protector Ubuntu's toolchain builds with -fstack-protector by default, which is not very friendly to standalone (libc-less) binaries. Author: Colin Watson Index: b/Make.common =================================================================== --- a/Make.common +++ b/Make.common @@ -15,7 +15,7 @@ OPTIMFLAGS = -O2 -fno-strict-aliasing DEBUGFLAGS = -Wall -CFLAGS = $(ARCH3264) $(OPTIMFLAGS) -fpic -fshort-wchar $(DEBUGFLAGS) +CFLAGS = $(ARCH3264) $(OPTIMFLAGS) -fpic -fshort-wchar -fno-stack-protector $(DEBUGFLAGS) ASFLAGS = $(ARCH3264) LDFLAGS = -nostdlib -znocombreloc debian/patches/series0000644000000000000000000000061311455320607012035 0ustar gptsync_64bit_fix.patch gptsync_nom_nom_nom_newline.patch kfreebsd.patch fat_binaries_build.patch debian_version_string.patch gptsync_quiet_mode.patch gptsync_manpage.patch gptsync_dont_truncate.patch gptsync_biosboot.patch disable_EFI110_features.patch efi_call_wrappers.patch gptsync_uefi_call_wrapper.patch refit_uefi_call_wrapper.patch libeg_uefi_call_wrapper.patch no_stack_protector.patch debian/patches/gptsync_64bit_fix.patch0000644000000000000000000000236711455320607015216 0ustar Description: Fix type issues on 64bit platforms Causes runtime failure of gptsync, for obvious reasons. Author: Julien BLACHE Index: refit-0.14/gptsync/gptsync.h =================================================================== --- refit-0.14.orig/gptsync/gptsync.h 2010-04-19 18:29:15.591930983 +0200 +++ refit-0.14/gptsync/gptsync.h 2010-04-19 18:29:50.255932164 +0200 @@ -77,7 +77,7 @@ typedef unsigned int UINTN; typedef unsigned char UINT8; typedef unsigned short UINT16; -typedef unsigned long UINT32; +typedef unsigned int UINT32; typedef unsigned long long UINT64; typedef void VOID; Index: refit-0.14/gptsync/lib.c =================================================================== --- refit-0.14.orig/gptsync/lib.c 2010-04-19 18:29:15.606932040 +0200 +++ refit-0.14/gptsync/lib.c 2010-04-19 18:29:50.255932164 +0200 @@ -268,7 +268,7 @@ Print(L" No GPT partition table present!\n"); return 0; } - if (header->spec_revision != 0x00010000UL) { + if (header->spec_revision != 0x00010000) { Print(L" Warning: Unknown GPT spec revision 0x%08x\n", header->spec_revision); } if ((512 % header->entry_size) > 0 || header->entry_size > 512) { debian/patches/kfreebsd.patch0000644000000000000000000000221711455320607013430 0ustar Description: Select appropriate linker script for kFreeBSD-amd64 Enable building rEFIt on kfreebsd-amd64. Author: Julien BLACHE Index: refit-0.14/Make.common =================================================================== --- refit-0.14.orig/Make.common 2010-04-19 18:30:56.377932378 +0200 +++ refit-0.14/Make.common 2010-04-19 18:30:52.542932839 +0200 @@ -9,6 +9,7 @@ EFICRT0 = /usr/lib ARCH = $(shell uname -m | sed s,i[3456789]86,ia32,) +OS = $(shell uname -s) CPPFLAGS = -I$(EFIINC) -I$(EFIINC)/$(ARCH) -I$(EFIINC)/protocol -DCONFIG_$(ARCH) OPTIMFLAGS = -O2 -fno-strict-aliasing @@ -31,7 +32,16 @@ CRTOBJS = $(EFICRT0)/crt0-efi-$(ARCH).o -LDSCRIPT = $(EFICRT0)/elf_$(ARCH)_efi.lds + +ifneq (,$(findstring FreeBSD,$(OS))) + ifeq ($(ARCH),x86_64) + LDSCRIPT = $(EFICRT0)/elf_$(ARCH)_fbsd_efi.lds + else + LDSCRIPT = $(EFICRT0)/elf_$(ARCH)_efi.lds + endif +else + LDSCRIPT = $(EFICRT0)/elf_$(ARCH)_efi.lds +endif LDFLAGS += -T $(LDSCRIPT) -shared -Bsymbolic -L$(EFILIB) -L$(GNUEFILIB) $(CRTOBJS) LIBS = -lefi -lgnuefi $(shell $(CC) -print-libgcc-file-name) debian/copyright0000644000000000000000000001267711455320607011141 0ustar This package was originally debianized by Junichi Uekawa on Sat, 1 Jul 2006 09:04:40 +0000. It has been repackaged by Julien BLACHE on Sun, 18 May 2008 17:24:00 +0200. It was downloaded from: Upstream Author: Christoph Pfisterer Copyright: Copyright (c) 2006-2009 Christoph Pfisterer Copyright (c) 2004, Intel Corporation License: Copyright (c) 2006 Christoph Pfisterer All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of Christoph Pfisterer nor the names of the contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. The Debian packaging is Copyright (C) 2006 Junichi Uekawa Copyright (C) 2008-2009 Julien BLACHE and is licensed under the GPL, see `/usr/share/common-licenses/GPL'. Copyright information for specific files: ----------------------------------------- Files: include/efiConsoleControl.h, libeg/efiConsoleControl.h, libeg/efiUgaDraw.h, libeg/efiGraphicsOutput.h Copyright (c) 2004, Intel Corporation All rights reserved. This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at http://opensource.org/licenses/bsd-license.php THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. File: fsw/fsw_core.h Copyright (c) 2006 Christoph Pfisterer Portions Copyright (c) The Regents of the University of California. Portions Copyright (c) UNIX System Laboratories, Inc. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of Christoph Pfisterer nor the names of the contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. Files: fsw/fsw_ext2_disk.h, fsw/fsw_reiserfs_disk.h Copyright (c) 2006 Christoph Pfisterer Portions Copyright (c) 1991-2006 by various Linux kernel contributors 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 On Debian systems, the full text of the GPLv2 can be found in the file /usr/share/common-licenses/GPL-2. debian/gptsync.manpages0000644000000000000000000000004511455320607012374 0ustar gptsync/gptsync.8 debian/showpart.8