[521] | 1 | # use udev feature until things go right... |
---|
| 2 | %define with_hal 0 |
---|
| 3 | |
---|
| 4 | Summary: Firmware extraction tools for Apple Built-in iSight camera |
---|
| 5 | Summary(ja): Apple 内蔵 iSight カメラ用ファームウェア抽出プログラム |
---|
| 6 | Name: isight-firmware-tools |
---|
| 7 | Version: 1.4.1 |
---|
[1086] | 8 | Release: 2%{?_dist_release} |
---|
[521] | 9 | License: GPLv2+ |
---|
| 10 | Group: System Environment/Base |
---|
| 11 | URL: http://bersace03.free.fr/ift/ |
---|
| 12 | Source0: %{name}-%{version}.tar.gz |
---|
| 13 | Source10: %{name}-1.2_ja.po |
---|
| 14 | |
---|
| 15 | BuildRoot: %{_tmppath}/%{name}-%{version}-%{release} |
---|
| 16 | |
---|
| 17 | %if %{with_hal} |
---|
| 18 | Requires: hal |
---|
| 19 | %else |
---|
| 20 | Requires: udev |
---|
| 21 | %endif |
---|
| 22 | Requires(post): /sbin/install-info |
---|
| 23 | Requires(preun): /sbin/install-info |
---|
| 24 | |
---|
| 25 | BuildRequires: gettext |
---|
| 26 | BuildRequires: glib2-devel |
---|
| 27 | BuildRequires: libgcrypt-devel |
---|
| 28 | BuildRequires: libusb-devel |
---|
| 29 | %if %{with_hal} |
---|
| 30 | BuildRequires: hal-devel |
---|
| 31 | %else |
---|
| 32 | BuildRequires: udev |
---|
| 33 | %endif |
---|
| 34 | BuildRequires: perl(XML::Parser) |
---|
| 35 | |
---|
[1087] | 36 | Vendor: Project Vine |
---|
| 37 | Distribution: Vine Linux |
---|
| 38 | Packager: shaolin |
---|
[521] | 39 | |
---|
[1087] | 40 | |
---|
[521] | 41 | %description |
---|
| 42 | iSight Firmware Tools provide tools to manipulate firmware for Built-in iSight |
---|
| 43 | cameras found on Apple machines since iMac G5 (November 2005). |
---|
| 44 | |
---|
| 45 | Before using Built-in iSight on Linux, you will need to extract the |
---|
| 46 | firmware to /lib/firmware/isight.fw as: |
---|
| 47 | |
---|
| 48 | sudo ift-extract --apple-driver /path/to/AppleUSBVideoSupport |
---|
| 49 | |
---|
| 50 | AppleUSBVideoSupport driver file should be located in |
---|
| 51 | |
---|
| 52 | /System/Library/Extensions/IOUSBFamily.kext/Contents/PlugIns/AppleUSBVideoSupport.kext/Contents/MacOS/AppleUSBVideoSupport |
---|
| 53 | |
---|
| 54 | on your Mac OS X root partition. |
---|
| 55 | |
---|
| 56 | |
---|
| 57 | %description -l ja |
---|
| 58 | iSight Firmware Tools を使って、2005年11月発売の iMac G5 以降の |
---|
| 59 | Apple 社製コンピュータに内蔵されている iSight カメラ用のファームウェアを |
---|
| 60 | 操作することができます。 |
---|
| 61 | |
---|
| 62 | Linux で内蔵 iSight を使う前に、 |
---|
| 63 | |
---|
| 64 | sudo ift-extract --apple-driver /path/to/AppleUSBVideoSupport |
---|
| 65 | |
---|
| 66 | という風に実行してファームウェアを /lib/firmware/isight.fw として |
---|
| 67 | 取り出す必要があります。この AppleUSBVideoSupport ドライバファイルは |
---|
| 68 | 通常 Mac OS X ルートパーティションの |
---|
| 69 | |
---|
| 70 | /System/Library/Extensions/IOUSBFamily.kext/Contents/PlugIns/AppleUSBVideoSupport.kext/Contents/MacOS/AppleUSBVideoSupport |
---|
| 71 | |
---|
| 72 | に存在しているはずです。 |
---|
| 73 | |
---|
| 74 | |
---|
| 75 | %prep |
---|
| 76 | %setup -q |
---|
| 77 | |
---|
| 78 | install -m 644 %{SOURCE10} po/ja.po |
---|
| 79 | echo "ja" >> po/LINGUAS |
---|
| 80 | |
---|
[1086] | 81 | sed -i -e 's|@udevdir@|%{_libdir}/udev|g' src/isight.rules.in.in |
---|
| 82 | sed -i -e 's|SYSFS|ATTRS|g' src/isight.rules.in.in |
---|
[521] | 83 | |
---|
| 84 | |
---|
| 85 | %build |
---|
| 86 | %if %{with_hal} |
---|
| 87 | %configure --enable-hal --disable-udev |
---|
| 88 | %else |
---|
| 89 | %configure --disable-hal --enable-udev |
---|
| 90 | %endif |
---|
| 91 | make %{?_smp_mflags} |
---|
| 92 | |
---|
| 93 | |
---|
| 94 | %install |
---|
| 95 | rm -rf $RPM_BUILD_ROOT |
---|
| 96 | |
---|
| 97 | make install INSTALL="%{__install} -p" DESTDIR=$RPM_BUILD_ROOT |
---|
| 98 | |
---|
| 99 | rm -f $RPM_BUILD_ROOT%{_infodir}/dir |
---|
| 100 | |
---|
| 101 | # Use %doc instead. |
---|
| 102 | rm -rf $RPM_BUILD_ROOT%{_docdir}/%{name} |
---|
| 103 | |
---|
| 104 | %find_lang %{name} |
---|
| 105 | |
---|
| 106 | |
---|
| 107 | %clean |
---|
| 108 | rm -rf $RPM_BUILD_ROOT |
---|
| 109 | |
---|
| 110 | |
---|
| 111 | %post |
---|
| 112 | /sbin/install-info %{_infodir}/ift-export.info %{_infodir}/dir || : |
---|
| 113 | /sbin/install-info %{_infodir}/ift-extract.info %{_infodir}/dir || : |
---|
| 114 | |
---|
| 115 | |
---|
| 116 | %preun |
---|
| 117 | if [ $1 = 0 ]; then |
---|
| 118 | /sbin/install-info --delete %{_infodir}/ift-export.info %{_infodir}/dir || : |
---|
| 119 | /sbin/install-info --delete %{_infodir}/ift-extract.info %{_infodir}/dir || : |
---|
| 120 | fi |
---|
| 121 | |
---|
| 122 | |
---|
| 123 | %files -f %{name}.lang |
---|
| 124 | %defattr(-,root,root,-) |
---|
| 125 | %doc AUTHORS ChangeLog COPYING HOWTO NEWS README |
---|
| 126 | %{_bindir}/ift-export |
---|
| 127 | %{_bindir}/ift-extract |
---|
| 128 | %{_infodir}/ift-export.info.gz |
---|
| 129 | %{_infodir}/ift-extract.info.gz |
---|
| 130 | %if %{with_hal} |
---|
| 131 | %{_libdir}/hal/ift-callout |
---|
| 132 | %{_datadir}/hal/fdi/preprobe/20thirdparty/50-isight-firmware.fdi |
---|
| 133 | %else |
---|
| 134 | %{_libdir}/udev/ift-load |
---|
| 135 | %{_sysconfdir}/udev/rules.d/isight.rules |
---|
| 136 | %endif |
---|
| 137 | %{_mandir}/man1/ift-export.1.gz |
---|
| 138 | %{_mandir}/man1/ift-extract.1.gz |
---|
| 139 | |
---|
| 140 | |
---|
| 141 | %changelog |
---|
[1086] | 142 | * Sat May 29 2010 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 1.4.1-2 |
---|
| 143 | - replace SYSFS{} with ATTRS{} in the udev file to avoid warning |
---|
| 144 | |
---|
[521] | 145 | * Sat May 30 2009 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 1.4.1-1 |
---|
| 146 | - new upstream release |
---|
| 147 | |
---|
| 148 | * Thu Dec 4 2008 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 1.4-2 |
---|
| 149 | - switch back to udev support, until hal support gets stable |
---|
| 150 | |
---|
| 151 | * Thu Dec 4 2008 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 1.4-1 |
---|
| 152 | - new upstream release |
---|
| 153 | |
---|
| 154 | * Thu Sep 18 2008 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 1.2-4 |
---|
| 155 | - now enable hal support; disable udev support |
---|
| 156 | |
---|
| 157 | * Fri May 30 2008 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 1.2-3 |
---|
| 158 | - fix broken path in isight.rules |
---|
| 159 | |
---|
| 160 | * Mon May 26 2008 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 1.2-2 |
---|
| 161 | - enable udev / disable hal (until Vine's udev gets updated enough) |
---|
| 162 | - import Patch10 (for MacBookAir) and Source10 (ja.po) from Debian package |
---|
| 163 | |
---|
| 164 | * Fri May 23 2008 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 1.2-1 |
---|
| 165 | - initial build for Vine Linux |
---|
| 166 | - spec in UTF-8 |
---|