Name: owncloud Version: 4.5.0 Release: 0.1.beta2%{?dist} Summary: Private file sync and share server License: AGPLv3 and MIT URL: http://owncloud.org Source0: http://owncloud.org/releases/%{name}-%{version}-beta2.tar.bz2 Source1: %{name}.conf Source2: %{name}-config.php Patch0: %{name}-fedora-phpfixes.patch BuildArch: noarch Requires: httpd # PHP dependencies Requires: php php-gd php-mbstring php-pdo php-posix php-xml # PHP PEAR dependencies Requires: php-pear php-pear-Crypt-Blowfish php-pear-MDB2-Driver-mysqli Requires: php-pear-MDB2-Driver-pgsql php-pear-MDB2-Driver-sqlite Requires: php-pear-MDB2-Schema php-pear-Net-Curl php-pear-XML-Parser # SabreDAV Requires: php-sabredav-Sabre_CalDAV php-sabredav-Sabre_CardDAV # Other PHP dependencies Requires: php-cloudfiles php-phpass php-PHPMailer php-simpletest Requires: php-smb4php php-When php-dropbox-php-Dropbox # TODO # Amazon AWS PHP SDK (packaging ongoing) #Requires: php-aws-sdk # 3rdparty/Google is special. The code comes from # https://code.google.com/p/gdata-samples/source/browse/trunk/oauth_playground/ # but contains a bundled OAuth library from # https://code.google.com/p/oauth #Requires: php-oauth # 3rdparty/mediawiki contains two files picked from the mediawiki distribution # Fedora packages mediawiki but not in a way that it's files would be reusable # (i.e. the package doesn't contain the files itself but the tarball + deployment # script) # This needs to be downgraded to 1.9 (production release) # as 2.0 (that we have in Fedora atm) is not actively developed anymore #Requires: php-getid3 # http://siege.org/projects/phpMyID # abandoned since 2008 #Requires: php-phpMyId # http://roosenmaallen.com/2008/03/20/simpleopenid-for-php/ # one shot release of an OpenID implementation which basically is a modified # version of another class taken from phpclasses.org *sigh* #Requires: php-simpleOpenID # Bundled 3rdparty libs missing in Fedora ## JS (mainly jQuery plugins) ## currently it is unclear how this is handled in Fedora (no best practice yet) # https://github.com/harvesthq/chosen/ # http://fgelinas.com/code/timepicker # http://arshaw.com/fullcalendar/ # https://github.com/claviska/jquery-miniColors/ %description ownCloud Server provides you a private file sync and share cloud. Host this server to easily sync business or private documents across all your devices, and share those documents with other users of your ownCloud server on their devices. %prep %setup -q -n %{name} %patch0 -p1 %build # Nothing to build %install rm -rf $RPM_BUILD_ROOT install -dm 755 $RPM_BUILD_ROOT%{_datadir}/%{name} # Strip bundled libraries # Folders rm -rf 3rdparty/Archive 3rdparty/Console 3rdparty/Crypt_Blowfish 3rdparty/Dropbox \ 3rdparty/MDB2 \ 3rdparty/OS 3rdparty/PEAR 3rdparty/php-cloudfiles 3rdparty/phpass \ 3rdparty/Sabre 3rdparty/simpletest 3rdparty/smb4php 3rdparty/when \ 3rdparty/XML # we're not removing lib/MDB2 as this is an ownCloud internal sqlite3 driver # that isn't actually a PEAR package (although it looks like one) # Files rm -f 3rdparty/class.phpmailer.php 3rdparty/class.smtp.php 3rdparty/MDB2.php \ 3rdparty/PEAR.php 3rdparty/PEAR5.php 3rdparty/PEAR-LICENSE \ 3rdparty/Sabre.includes.php 3rdparty/System.php # Remove bundled webodf sources rm -rf apps/files_odfviewer/src # Remove l10n development files rm -f l10n/init.sh l10n/l10n.pl # move apps to core-apps folder # we'll be symlinking them back in later in order to facilitate for writeable # apps folder in _localstatedir mv apps core-apps # Copy all content cp -pr * $RPM_BUILD_ROOT%{_datadir}/%{name} # create apps and data dir install -dm 755 $RPM_BUILD_ROOT%{_localstatedir}/lib/%{name}/apps install -dm 755 $RPM_BUILD_ROOT%{_localstatedir}/lib/%{name}/data # symlink config dir rm -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/config ln -sf %{_sysconfdir}/%{name} $RPM_BUILD_ROOT%{_datadir}/%{name}/config # move and symlink back internal apps # this is probably one of the ugliest things ever to have happened in a spec # file :( pushd core-apps for app in *; do ln -sf %{_datadir}/%{name}/core-apps/${app} $RPM_BUILD_ROOT%{_localstatedir}/lib/%{name}/apps/${app} done popd ln -sf %{_localstatedir}/lib/%{name}/apps $RPM_BUILD_ROOT%{_datadir}/%{name}/apps # install dummy logfile install -dm 755 $RPM_BUILD_ROOT%{_localstatedir}/log touch $RPM_BUILD_ROOT%{_localstatedir}/log/%{name}.log # Install initial config file # This file contains the defaults (most importantly the filesystem locations) # needed for installation on Fedora systems install -Dpm 644 %{SOURCE2} \ $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/config.php install -Dpm 644 %{SOURCE1} \ $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d/%{name}.conf %files %doc AUTHORS COPYING-AGPL COPYING-README README %dir %attr(0750,apache,apache) %{_sysconfdir}/%{name} # config file needs to be writeable by apache as it's written after every change # from within the admin web interface %config(noreplace) %attr(0644,apache,apache) %{_sysconfdir}/%{name}/config.php %config(noreplace) %{_sysconfdir}/httpd/conf.d/%{name}.conf %{_datadir}/%{name} %dir %{_localstatedir}/lib/%{name} %dir %attr(0750,apache,apache) %{_localstatedir}/lib/%{name}/data %dir %attr(0750,apache,apache) %{_localstatedir}/lib/%{name}/apps %{_localstatedir}/lib/%{name}/apps/* %ghost %attr(0750,apache,apache) %{_localstatedir}/log/%{name}.log %changelog * Tue Sep 11 2012 Felix Kaechele - 4.5-0.1.beta2 - update to 4.5 beta2 * Mon Sep 03 2012 Felix Kaechele - 4.0.7-1 - update to 4.0.7 * Fri Apr 06 2012 Felix Kaechele - 3.0.1-1 - initial package