Reply
Thread Tools
Schturman's Avatar
Posts: 5,339 | Thanked: 4,133 times | Joined on Jan 2010 @ Israel
#21
 
coderus's Avatar
Posts: 6,436 | Thanked: 12,699 times | Joined on Nov 2011 @ Ängelholm, Sweden
#22
Originally Posted by Schturman View Post
OK, you can do it like this..
1. Before packaging you need your_package.aegis file that include this:
Code:
<aegis>
    <request policy="add">
    <credential name="UID::root" />
    <credential name="GID::root" />
    <credential name="GRP::root" />

    <for path="/opt/mytheme/changer/script.sh" />
    </request>
</aegis>
2. The .desktop file should look like this:
Code:
[Desktop Entry]
Type=Application
Name=My Theme
Exec=/usr/bin/aegis-exec -s -u user -l "/opt/mytheme/changer/script.sh"
Icon=/opt/mytheme/icon/icon.png
X-Window-Icon=
X-HildonDesk-ShowInToolbar=true
X-Osso-Type=application/x-executable
oh, really, aegis-exec -s -u user ... ?
__________________
Telegram | Openrepos | GitHub | Revolut donations
 
coderus's Avatar
Posts: 6,436 | Thanked: 12,699 times | Joined on Nov 2011 @ Ängelholm, Sweden
#23
@flotron. how you packaging to geb? you can use aegis-deb-add to inject aegis manifest ot existing deb package.
__________________
Telegram | Openrepos | GitHub | Revolut donations
 

The Following 2 Users Say Thank You to coderus For This Useful Post:
peterleinchen's Avatar
Posts: 4,117 | Thanked: 8,901 times | Joined on Aug 2010 @ Ruhrgebiet, Germany
#24
A big SORRY from my side.
As soon as I stepped out and Schturmann stepped in, it was obvious that this imeant for N9. And all my guides of course only work for N900. Must have overread that in your first post.
__________________
SIM-Switcher, automated SIM switching with a Double (Dual) SIM adapter
--
Thank you all for voting me into the Community Council 2014-2016!

Please consider your membership / supporting Maemo e.V. and help to spread this by following/copying this link to your TMO signature:
[MC eV] Maemo Community eV membership application, http://talk.maemo.org/showthread.php?t=94257

editsignature, http://talk.maemo.org/profile.php?do=editsignature
 
Schturman's Avatar
Posts: 5,339 | Thanked: 4,133 times | Joined on Jan 2010 @ Israel
#25
Originally Posted by coderus View Post
oh, really, aegis-exec -s -u user ... ?
Exactly... You are right he can change it to "root" too.. But for me in N9QT it work with "user". If i change it to root, the version-auto-checker script, that run from n9qt script, not work correctly..
 
Schturman's Avatar
Posts: 5,339 | Thanked: 4,133 times | Joined on Jan 2010 @ Israel
#26
Originally Posted by coderus View Post
@flotron. how you packaging to geb? you can use aegis-deb-add to inject aegis manifest ot existing deb package.
Can you write please the full command how to do it? And first he need to create the aegis manifest file?
 
flotron's Avatar
Posts: 418 | Thanked: 506 times | Joined on Jan 2012 @ Argentina
#27
Originally Posted by Schturman View Post
Can you write please the full command how to do it? And first he need to create the aegis manifest file?
I package my debs with my n9 with this script

/home/user/MyDocs/makedeb.sh /home/user/mypackagefolder (inside folder: DEBIAN,opt,usr.. with control,postint,etc...)

Code:
#!/bin/sh

#create .deb files for packages (fremantle&harmattan)

if [ ! $1 ];then
 echo Create .deb files for fremantle and harmattan devices
 echo Usage: make-deb /path/to/package
 exit 0
fi

#step in package directory
chdir "$1"

#versionnumber and packagename from control file
packagename=`grep "Package: " DEBIAN/control | cut -d ' ' -f 2`
versionnumber=`grep "Version: " DEBIAN/control | cut -d ' ' -f 2`

#remove old md5 and digsig sums
rm -f DEBIAN/md5sums 2>/dev/null
rm -f DEBIAN/digsigsums 2>/dev/null

#list all folders except DEBIAN
find | grep -v "./DEBIAN" > ../md5

#get md5 and digsig sums to DEBIAN/
while read line
do
 if [ -f "$line" ]; then
  #cut "./" from beginning
  line=`echo "$line" | cut -c 3-`

  #get md5
  md5sum "$line" >> DEBIAN/md5sums

  #get sha1 for digital signatures
  echo S 15 com.nokia.maemo H 40 `sha1sum "$line" | cut -c -40` R `expr length "$line"` $line >> DEBIAN/digsigsums
 fi
done < "../md5"

#remove temp file list
rm -f ../md5

#package control.tar.gz and data.tar.gz
tar -cvzf ../control.tar.gz -C DEBIAN/ . >/dev/null
tar -cvzf ../data.tar.gz . --exclude=DEBIAN >/dev/null
echo 2.0>../debian-binary

#step outside package folder
cd ..

#create debian archive "package_version.deb"
ar -rcv $packagename"_"$versionnumber.deb debian-binary control.tar.gz data.tar.gz >/dev/null

#remove packaged files
rm -f debian-binary control.tar.gz data.tar.gz 2>/dev/null
 
Schturman's Avatar
Posts: 5,339 | Thanked: 4,133 times | Joined on Jan 2010 @ Israel
#28
Ok, thanks, but I meant to Coderus
I also want to learn how inject aegis manifest ot existing deb package
 

The Following User Says Thank You to Schturman For This Useful Post:
flotron's Avatar
Posts: 418 | Thanked: 506 times | Joined on Jan 2012 @ Argentina
#29
I tried yours Schturman (adding the aegis an rules files and modifyng the desktop file) but when i press the icon nothing happens.
The script only works in the postint or preinst, etc.. Not executing from icon

Last edited by flotron; 2013-03-23 at 20:24.
 
Schturman's Avatar
Posts: 5,339 | Thanked: 4,133 times | Joined on Jan 2010 @ Israel
#30
Packaging on n9 it's not really the same like packaging on the Linux pc via scratchbox. I don't know how to do it, we need to wait for Coderus that can explain how inject aegis manifest ot existing deb package.
Or another way, install scratchbox on Linux pc and i will try to help you crate this package..
 

The Following User Says Thank You to Schturman For This Useful Post:
Reply

Tags
chmod, debian, permission, script, theme

Thread Tools

 
Forum Jump


All times are GMT. The time now is 10:44.