diff options
author | Remi Collet <fedora@famillecollet.com> | 2014-04-25 16:15:19 +0200 |
---|---|---|
committer | Remi Collet <fedora@famillecollet.com> | 2014-04-25 16:15:19 +0200 |
commit | d5f00255ef409b2d036d930f3ca20864e4163007 (patch) | |
tree | e907f97c8ac8433aa9639bc7dc2cd108c9349a7e |
phar-gui 1.0/edbd631 - New package
-rw-r--r-- | Makefile | 4 | ||||
-rw-r--r-- | phar-gui.spec | 100 |
2 files changed, 104 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..1e65467 --- /dev/null +++ b/Makefile @@ -0,0 +1,4 @@ +SRCDIR := $(shell pwd) +NAME := $(shell basename $(SRCDIR)) +include ../common/Makefile + diff --git a/phar-gui.spec b/phar-gui.spec new file mode 100644 index 0000000..042bc5e --- /dev/null +++ b/phar-gui.spec @@ -0,0 +1,100 @@ +# spec file for phar-gui +# +# Copyright (c) 2014 Remi Collet +# License: CC-BY-SA +# http://creativecommons.org/licenses/by-sa/3.0/ +# +# Please, preserve the changelog entries +# +%global gh_commit edbd631f37630839e6d05cf5e0adc4503a02cbb1 +%global gh_short %(c=%{gh_commit}; echo ${c:0:7}) +%global gh_date 20140417 +%global gh_owner jgmdev +%global gh_project phar-gui + +Name: %{gh_project} +Summary: A graphical user interface for phar files +Version: 1.0 +%if 0%{?gh_date} +Release: 0.1.%{gh_date}git%{gh_short}%{?dist} +%else +Release: 1%{?dist} +%endif +License: MIT +Group: Development/Libraries + +URL: https://github.com/%{gh_owner}/%{gh_project} +Source0: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{gh_project}-%{gh_commit}.tar.gz + +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) +BuildArch: noarch +# To ensure we are not going to build where extension is missing +BuildRequires: php-pecl(wxwidgets) + +Requires: php-cli +Requires: php-phar +Requires: php-spl +Requires: php-pecl(wxwidgets) + + +%description +A graphical user interface developed with wxPHP to manage, extract and +view the content of PHP phar files. + +The interface of the application was developed with wxFormBuilder and its +source code can serve as an example of how to integrate graphical user +interfaces designed with wxFormBuilder in your code. + +Features: +- Create phar files +- View the content of a phar +- Extract all the content of a phar file +- Extract single files in the phar +- Add empty directories to a phar file +- Add external files to a phar +- Delete files from a phar +- Modify phar file stub +- Modify phar file alias +- View the code of php files inside the phar by double clicking them. + + +%prep +%setup -q -n %{gh_project}-%{gh_commit} + +# Not usable as a launcher +chmod -x main.php +sed -e '/^#!/d' -i main.php + +# Create the launcher +cat <<EOF | tee phar-gui +#!/bin/sh +exec %{_bindir}/php \ + -d extension=wxwidgets.so \ + -d phar.readonly=0 \ + %{_datadir}/%{name}/main.php "$@" +EOF + + +%build +# nothing to build + + +%install +rm -rf %{buildroot} +mkdir -p %{buildroot}%{_datadir}/%{name} + +cp -pr main.php resources.php lib images %{buildroot}%{_datadir}/%{name} + +install -D -m 755 %{name} %{buildroot}%{_bindir}/%{name} + + +%files +%defattr(-,root,root,-) +%doc LICENSE.txt README.md +%{_datadir}/%{name} +%{_bindir}/%{name} + + +%changelog +* Fri Apr 25 2014 Remi Collet <remi@fedoraproject.org> - 1.0.0-0.1.20140417gitedbd631 +- Initial packaging
\ No newline at end of file |