diff options
| author | CoprDistGit <infra@openeuler.org> | 2023-05-15 07:29:27 +0000 |
|---|---|---|
| committer | CoprDistGit <infra@openeuler.org> | 2023-05-15 07:29:27 +0000 |
| commit | 681cf81db3b4d3ecf5c283137daa8f4893174591 (patch) | |
| tree | df2d6cd5a823574683d40769bc23382706296351 | |
| parent | c8cce850efcc62a9f21fcf1109f7efac2d247247 (diff) | |
automatic import of python-etherbase-predeployed
| -rw-r--r-- | .gitignore | 1 | ||||
| -rw-r--r-- | python-etherbase-predeployed.spec | 181 | ||||
| -rw-r--r-- | sources | 1 |
3 files changed, 183 insertions, 0 deletions
@@ -0,0 +1 @@ +/etherbase-predeployed-1.0.0.tar.gz diff --git a/python-etherbase-predeployed.spec b/python-etherbase-predeployed.spec new file mode 100644 index 0000000..06731d5 --- /dev/null +++ b/python-etherbase-predeployed.spec @@ -0,0 +1,181 @@ +%global _empty_manifest_terminate_build 0 +Name: python-etherbase-predeployed +Version: 1.0.0 +Release: 1 +Summary: A tool for generating predeployed etherbase smart contract +License: GNU Affero General Public License v3 +URL: https://github.com/skalenetwork/etherbase +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/e7/2c/88076f2a83b6a46648e1ead274125100193a195c45847c2006bbecb2e251/etherbase-predeployed-1.0.0.tar.gz +BuildArch: noarch + +Requires: python3-predeployed-generator + +%description +# etherbase-predeployed + +## Description + +A tool for generating predeployed etherbase smart contract + +## Installation + +```console +pip install etherbase-predeployed +``` + +## Usage example + +```python +from etherbase_predeployed import UpgradeableEtherbaseUpgradeableGenerator, ETHERBASE_ADDRESS, ETHERBASE_IMPLEMENTATION_ADDRESS + +OWNER_ADDRESS = '0xd200000000000000000000000000000000000000' +PROXY_ADMIN_ADDRESS = '0xd200000000000000000000000000000000000001' + +etherbase_generator = UpgradeableEtherbaseUpgradeableGenerator() + +genesis = { + # genesis block parameters + 'alloc': { + **etherbase_generator.generate_allocation( + contract_address=ETHERBASE_ADDRESS, + implementation_address=ETHERBASE_IMPLEMENTATION_ADDRESS, + schain_owner=OWNER_ADDRESS, + proxy_admin_address=PROXY_ADMIN_ADDRESS + ) + } +} + +``` + + + +%package -n python3-etherbase-predeployed +Summary: A tool for generating predeployed etherbase smart contract +Provides: python-etherbase-predeployed +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-etherbase-predeployed +# etherbase-predeployed + +## Description + +A tool for generating predeployed etherbase smart contract + +## Installation + +```console +pip install etherbase-predeployed +``` + +## Usage example + +```python +from etherbase_predeployed import UpgradeableEtherbaseUpgradeableGenerator, ETHERBASE_ADDRESS, ETHERBASE_IMPLEMENTATION_ADDRESS + +OWNER_ADDRESS = '0xd200000000000000000000000000000000000000' +PROXY_ADMIN_ADDRESS = '0xd200000000000000000000000000000000000001' + +etherbase_generator = UpgradeableEtherbaseUpgradeableGenerator() + +genesis = { + # genesis block parameters + 'alloc': { + **etherbase_generator.generate_allocation( + contract_address=ETHERBASE_ADDRESS, + implementation_address=ETHERBASE_IMPLEMENTATION_ADDRESS, + schain_owner=OWNER_ADDRESS, + proxy_admin_address=PROXY_ADMIN_ADDRESS + ) + } +} + +``` + + + +%package help +Summary: Development documents and examples for etherbase-predeployed +Provides: python3-etherbase-predeployed-doc +%description help +# etherbase-predeployed + +## Description + +A tool for generating predeployed etherbase smart contract + +## Installation + +```console +pip install etherbase-predeployed +``` + +## Usage example + +```python +from etherbase_predeployed import UpgradeableEtherbaseUpgradeableGenerator, ETHERBASE_ADDRESS, ETHERBASE_IMPLEMENTATION_ADDRESS + +OWNER_ADDRESS = '0xd200000000000000000000000000000000000000' +PROXY_ADMIN_ADDRESS = '0xd200000000000000000000000000000000000001' + +etherbase_generator = UpgradeableEtherbaseUpgradeableGenerator() + +genesis = { + # genesis block parameters + 'alloc': { + **etherbase_generator.generate_allocation( + contract_address=ETHERBASE_ADDRESS, + implementation_address=ETHERBASE_IMPLEMENTATION_ADDRESS, + schain_owner=OWNER_ADDRESS, + proxy_admin_address=PROXY_ADMIN_ADDRESS + ) + } +} + +``` + + + +%prep +%autosetup -n etherbase-predeployed-1.0.0 + +%build +%py3_build + +%install +%py3_install +install -d -m755 %{buildroot}/%{_pkgdocdir} +if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi +if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi +if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi +if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi +pushd %{buildroot} +if [ -d usr/lib ]; then + find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/lib64 ]; then + find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/bin ]; then + find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/sbin ]; then + find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst +fi +touch doclist.lst +if [ -d usr/share/man ]; then + find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst +fi +popd +mv %{buildroot}/filelist.lst . +mv %{buildroot}/doclist.lst . + +%files -n python3-etherbase-predeployed -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Mon May 15 2023 Python_Bot <Python_Bot@openeuler.org> - 1.0.0-1 +- Package Spec generated @@ -0,0 +1 @@ +6a302f039ebc70b92d314d0a363da2db etherbase-predeployed-1.0.0.tar.gz |
