Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
eepm
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
eepm
Commits
d4ed1c16
Commit
d4ed1c16
authored
Mar 26, 2022
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
epm play: rewrite geobra install
parent
8026f6e1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
65 additions
and
36 deletions
+65
-36
geogebra.sh
play.d/geogebra.sh
+31
-36
common-chromium-browser.sh
repack.d/common-chromium-browser.sh
+10
-0
geogebra-classic.sh
repack.d/geogebra-classic.sh
+24
-0
No files found.
play.d/geogebra.sh
View file @
d4ed1c16
#!/bin/sh
# TODO: common place
fatal
()
{
echo
"FATAL:
$*
"
>
&2
exit
1
}
PKGNAME
=
geogebra-classic
DESCRIPTION
=
"Geogebra 6 from the official site"
.
$(
dirname
$0
)
/common.sh
arch
=
$(
$DISTRVENDOR
--distro-arch
)
case
$arch
in
x86_64|amd64
)
arch
=
$arch
;;
i686|i586|i386
)
arch
=
i386
;;
*
)
fatal
"Unsupported arch
$arch
for
$(
$DISTRVENDOR
-d
)
"
esac
pkgtype
=
"
$(
$DISTRVENDOR
-p
)
"
repack
=
''
[
"
$(
$DISTRVENDOR
-d
)
"
=
"ALTLinux"
]
&&
repack
=
'--repack'
case
$pkgtype
in
deb
)
epm
install
"http://www.geogebra.net/linux/pool/main/g/geogebra-classic/(epm print constructname
$PKGNAME
"
*
")"
;;
rpm
)
epm
$repack
install
"http://www.geogebra.net/linux/rpm/
$arch
/
$(
epm print constructname
$PKGNAME
"*"
)
"
;;
*
)
fatal
"Unsupported
$pkgtype
"
;;
esac
PKGNAME
=
geogebra
if
[
"
$1
"
=
"--remove"
]
;
then
epm remove
$PKGNAME
exit
fi
[
"
$1
"
!=
"--run"
]
&&
echo
"Geogebra 6 from the official site"
&&
exit
[
"
$(
$DISTRVENDOR
-a
)
"
!=
"x86_64"
]
&&
echo
"Only x86_64 is supported"
&&
exit
1
# See also
arch
=
x86_64
pkgtype
=
rpm
pkgver
=
"6.0.666.0"
pkgrel
=
"202109211234"
epm
install
"http://www.geogebra.net/linux/rpm/x86_64/
$PKGNAME
-classic-
$pkgver
-
$pkgrel
.
$arch
.
$pkgtype
"
echo
echo
'
Setting SUID bit on /usr/share/geogebra-classic/chrome-sandbox to allow this crap to work...
'
chmod
4755 /usr/share/geogebra-classic/chrome-sandbox
echo
echo
'
Geogebra 6 successfully installed.
'
repack.d/common-chromium-browser.sh
View file @
d4ed1c16
...
...
@@ -113,6 +113,16 @@ add_bin_commands()
fi
}
move_to_opt
()
{
local
from
=
/usr/share/
$PRODUCT
mkdir
-p
$BUILDROOT$PRODUCTDIR
/
mv
$BUILDROOT
/
$from
/
*
$BUILDROOT$PRODUCTDIR
/
subst
"s|
$from
|
$PRODUCTDIR
|g"
$SPEC
}
fix_chrome_sandbox
()
{
local
sandbox
=
"
$1
"
...
...
repack.d/geogebra-classic.sh
0 → 100755
View file @
d4ed1c16
#!/bin/sh -x
# It will run with two args: buildroot spec
BUILDROOT
=
"
$1
"
SPEC
=
"
$2
"
PRODUCT
=
geogebra-classic
PRODUCTDIR
=
/opt/
$PRODUCT
.
$(
dirname
$0
)
/common-chromium-browser.sh
subst
'1iAutoReq:yes,noshell,nomonolib,nomono,nopython'
$SPEC
subst
'1iBuildRequires:rpm-build-python3'
$SPEC
subst
"1i%add_python3_path
$PRODUCTDIR
"
$SPEC
move_to_opt
subst
"s|/usr/share/
$PRODUCT
|
$PRODUCTDIR
|"
$BUILDROOT
/usr/bin/
$PRODUCT
cleanup
fix_chrome_sandbox
epm
install
--skip-installed
python3 rpm-build-python3
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment