Commit e31cf068 authored by Vitaly Lipatov's avatar Vitaly Lipatov

epm play: add lithium support

parent cd579f1e
#!/bin/sh
pkgtype=$(epm print info -p)
case $pkgtype in
rpm)
PKGNAME=lithium_ecad
;;
*)
PKGNAME=lithium-ecad
;;
esac
SUPPORTEDARCHES="x86_64"
DESCRIPTION="CAD of printed circuit boards"
. $(dirname $0)/common.sh
case $pkgtype in
rpm)
mask="$PKGNAME-*.x86_64.rpm"
;;
*)
mask="$PKGNAME_*_amd64.deb"
;;
esac
repack=''
case $(epm print info -s) in
alt)
repack="--repack"
esac
# https://www.lecad.ru/?download=&kcccount=https://www.lecad.ru/wp-content/uploads/lithium-ecad_1.7.5_amd64.deb
# https://www.lecad.ru/?download=&kcccount=https://www.lecad.ru/wp-content/uploads/lithium_ecad-1.7.5-0.x86_64.rpm
PKGURL="$(eget --list --latest https://www.lecad.ru/actual-version/ "$mask")"
epm $repack install "$PKGURL"
#!/bin/sh -x
# It will run with two args: buildroot spec
BUILDROOT="$1"
SPEC="$2"
PREINSTALL_PACKAGES="glib2 libdbus libEGL fontconfig libfreetype libGL libGLU libICE libjasper libSM libX11 libxcb libXext libXi libXrender zlib"
. $(dirname $0)/common.sh
move_to_opt "/opt/lithium*" || fatal "can't move to $PRODUCTDIR"
add_bin_link_command $PRODUCT $PRODUCTDIR/launcher.sh
#subst '1iAutoReq:no' $SPEC
subst '1iAutoProv:no' $SPEC
cd $BUILDROOT$PRODUCTDIR || fatal
if epm assure patchelf ; then
for i in bin/{launcher,libraryCreator,projectCreator} ; do
a= patchelf --set-rpath '$ORIGIN' $i || continue
done
for i in bin/{*.so,*.so.*} ; do
a= patchelf --set-rpath '$ORIGIN' $i || continue
done
for i in bin/plugins/*/*.so ; do
a= patchelf --set-rpath '$ORIGIN/../../' $i || continue
done
fi
# missed with other soname
ln -s /usr/lib64/libjasper.so.4 bin/libjasper.so.1
pack_file $PRODUCTDIR/bin/libjasper.so.1
install_file lithium-ecad.desktop /usr/share/applications/$PRODUCT.desktop
fix_desktop_file "/opt/lithium_ecad-.*/launcher.sh" $PRODUCT
fix_desktop_file "/opt/lithium_ecad-.*/lithium-ecad.png" $PRODUCT
install_file lithium-ecad.png /usr/share/pixmaps/$PRODUCT.png
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment