<feed xmlns='http://www.w3.org/2005/Atom'>
<title>mtk-20170518/package/base-files/files/lib/functions.sh, branch reboot</title>
<subtitle>MTK 20170518 : Mediatek SDK based on OpenWRT Barrier Breaker</subtitle>
<link rel='alternate' type='text/html' href='http://www.chd.sx/cgit/mtk-20170518/'/>
<entry>
<title>base-files: refactor default_postinst()</title>
<updated>2015-09-16T08:43:58+00:00</updated>
<author>
<name>Jo-Philipp Wich</name>
<email>jow@openwrt.org</email>
</author>
<published>2015-09-16T08:43:58+00:00</published>
<link rel='alternate' type='text/html' href='http://www.chd.sx/cgit/mtk-20170518/commit/?id=33b3594332924b15015a036b5e9b64982d5f15d1'/>
<id>33b3594332924b15015a036b5e9b64982d5f15d1</id>
<content type='text'>
 - Simplify user spec parsing code
 - Alias IPKG_INSTROOT to shorten code
 - Quote variables where appropriate
 - Remove a useless-use-of-cat instance
 - Suppress errors in case control or list files are missing

Signed-off-by: Jo-Philipp Wich &lt;jow@openwrt.org&gt;

SVN-Revision: 46975
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
 - Simplify user spec parsing code
 - Alias IPKG_INSTROOT to shorten code
 - Quote variables where appropriate
 - Remove a useless-use-of-cat instance
 - Suppress errors in case control or list files are missing

Signed-off-by: Jo-Philipp Wich &lt;jow@openwrt.org&gt;

SVN-Revision: 46975
</pre>
</div>
</content>
</entry>
<entry>
<title>base-files: default_postinst: propagate the real postinst return code</title>
<updated>2015-08-17T06:17:23+00:00</updated>
<author>
<name>John Crispin</name>
<email>john@openwrt.org</email>
</author>
<published>2015-08-17T06:17:23+00:00</published>
<link rel='alternate' type='text/html' href='http://www.chd.sx/cgit/mtk-20170518/commit/?id=e83643d31c2364166f411e7a1bb8c183489705c0'/>
<id>e83643d31c2364166f411e7a1bb8c183489705c0</id>
<content type='text'>
Using the postinst script for sanity checks and expecting opkg to fail
if the postinst didn't return 0 was possible in Barrier Breaker, propagate
the real postinst return code through default_postinst to restore this
behaviour.

Signed-off-by: Matthias Schiffer &lt;mschiffer@universe-factory.net&gt;

SVN-Revision: 46653
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Using the postinst script for sanity checks and expecting opkg to fail
if the postinst didn't return 0 was possible in Barrier Breaker, propagate
the real postinst return code through default_postinst to restore this
behaviour.

Signed-off-by: Matthias Schiffer &lt;mschiffer@universe-factory.net&gt;

SVN-Revision: 46653
</pre>
</div>
</content>
</entry>
<entry>
<title>base-files: fix default pre-/postrm for packages with a dot</title>
<updated>2015-05-19T09:13:17+00:00</updated>
<author>
<name>Jonas Gorski</name>
<email>jogo@openwrt.org</email>
</author>
<published>2015-05-19T09:13:17+00:00</published>
<link rel='alternate' type='text/html' href='http://www.chd.sx/cgit/mtk-20170518/commit/?id=d0af85c9a5ea546aa8f7322d52c8d256c2895902'/>
<id>d0af85c9a5ea546aa8f7322d52c8d256c2895902</id>
<content type='text'>
Instead of stripping everything after the first dot, strip everything
after the last dot.
This fixes pre-/postrm actions for packages with a dot in their name,
like libusb-1.0.

Fixes #19668.

Signed-off-by: Jonas Gorski &lt;jogo@openwrt.org&gt;

SVN-Revision: 45702
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Instead of stripping everything after the first dot, strip everything
after the last dot.
This fixes pre-/postrm actions for packages with a dot in their name,
like libusb-1.0.

Fixes #19668.

Signed-off-by: Jonas Gorski &lt;jogo@openwrt.org&gt;

SVN-Revision: 45702
</pre>
</div>
</content>
</entry>
<entry>
<title>modules: fix postinst generation for kernel modules</title>
<updated>2015-04-10T20:39:44+00:00</updated>
<author>
<name>John Crispin</name>
<email>john@openwrt.org</email>
</author>
<published>2015-04-10T20:39:44+00:00</published>
<link rel='alternate' type='text/html' href='http://www.chd.sx/cgit/mtk-20170518/commit/?id=bbad3f360e955403a0a38fb0919e52e7874476b9'/>
<id>bbad3f360e955403a0a38fb0919e52e7874476b9</id>
<content type='text'>
Fixes ticket #19352.

Signed-off-by: Yousong Zhou &lt;yszhou4tech@gmail.com&gt;
Signed-off-by: John Crispin &lt;blogic@openwrt.org&gt;

SVN-Revision: 45367
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fixes ticket #19352.

Signed-off-by: Yousong Zhou &lt;yszhou4tech@gmail.com&gt;
Signed-off-by: John Crispin &lt;blogic@openwrt.org&gt;

SVN-Revision: 45367
</pre>
</div>
</content>
</entry>
<entry>
<title>base-files: default_postinst() fix variable colision</title>
<updated>2015-02-04T06:10:06+00:00</updated>
<author>
<name>John Crispin</name>
<email>john@openwrt.org</email>
</author>
<published>2015-02-04T06:10:06+00:00</published>
<link rel='alternate' type='text/html' href='http://www.chd.sx/cgit/mtk-20170518/commit/?id=5cd8a482f3108f4b81e143ded6d8bf7128c8608f'/>
<id>5cd8a482f3108f4b81e143ded6d8bf7128c8608f</id>
<content type='text'>
The name variable contains at first the package name,
and after the last group name.
This patch fixes /etc/rc.d symlink creation (at least).

Change name in pkgname, change the other name in ugname
(user group name), and id in ugid (user group id)

Signed-off-by: Etienne CHAMPETIER &lt;champetier.etienne@gmail.com&gt;

SVN-Revision: 44253
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The name variable contains at first the package name,
and after the last group name.
This patch fixes /etc/rc.d symlink creation (at least).

Change name in pkgname, change the other name in ugname
(user group name), and id in ugid (user group id)

Signed-off-by: Etienne CHAMPETIER &lt;champetier.etienne@gmail.com&gt;

SVN-Revision: 44253
</pre>
</div>
</content>
</entry>
<entry>
<title>base-files: default_postinst() - create user:group first (resend)</title>
<updated>2014-12-01T16:15:13+00:00</updated>
<author>
<name>John Crispin</name>
<email>john@openwrt.org</email>
</author>
<published>2014-12-01T16:15:13+00:00</published>
<link rel='alternate' type='text/html' href='http://www.chd.sx/cgit/mtk-20170518/commit/?id=b0d2a9e77aa35b92bb03cf1bd9036a3c13ee5130'/>
<id>b0d2a9e77aa35b92bb03cf1bd9036a3c13ee5130</id>
<content type='text'>
create user:group before running postinst-pkg. the postinst hook might require
the user:group to already exist.

Signed-off-by: Christian Schoenebeck &lt;christian.schoenebeck@gmail.com&gt;

SVN-Revision: 43472
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
create user:group before running postinst-pkg. the postinst hook might require
the user:group to already exist.

Signed-off-by: Christian Schoenebeck &lt;christian.schoenebeck@gmail.com&gt;

SVN-Revision: 43472
</pre>
</div>
</content>
</entry>
<entry>
<title>default_postinst() fix wrong call of group_add</title>
<updated>2014-10-15T17:55:13+00:00</updated>
<author>
<name>John Crispin</name>
<email>john@openwrt.org</email>
</author>
<published>2014-10-15T17:55:13+00:00</published>
<link rel='alternate' type='text/html' href='http://www.chd.sx/cgit/mtk-20170518/commit/?id=666659fb3159412915f828ff10c1d88673d4ef71'/>
<id>666659fb3159412915f828ff10c1d88673d4ef71</id>
<content type='text'>
[base-files] default_postinst() fix wrong call of group_add
after 12bae65d07d29854204715cebc1ef1eae237fd9b group_add is
always called. shell scripting can be tricky...

wrong call:
[ -n "$gid" ] &amp;&amp; group_exists $name || group_add $name $gid

this leads to a call of 'group_add' when $gid is emtpy, proof:

root@box:~ functionA() { echo A; }
root@box:~ functionB() { echo B; }
root@box:~ VAR=
root@box:~ [ -n "$VAR" ] &amp;&amp; functionA || functionB
B
root@box:~ # functionB was called, but VAR is not filled
root@box:~ VAR=filled
root@box:~ [ -n "$VAR" ] &amp;&amp; functionA || functionB
A

Signed-off-by: Bastian Bittorf &lt;bittorf@bluebottle.com&gt;

SVN-Revision: 42926
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[base-files] default_postinst() fix wrong call of group_add
after 12bae65d07d29854204715cebc1ef1eae237fd9b group_add is
always called. shell scripting can be tricky...

wrong call:
[ -n "$gid" ] &amp;&amp; group_exists $name || group_add $name $gid

this leads to a call of 'group_add' when $gid is emtpy, proof:

root@box:~ functionA() { echo A; }
root@box:~ functionB() { echo B; }
root@box:~ VAR=
root@box:~ [ -n "$VAR" ] &amp;&amp; functionA || functionB
B
root@box:~ # functionB was called, but VAR is not filled
root@box:~ VAR=filled
root@box:~ [ -n "$VAR" ] &amp;&amp; functionA || functionB
A

Signed-off-by: Bastian Bittorf &lt;bittorf@bluebottle.com&gt;

SVN-Revision: 42926
</pre>
</div>
</content>
</entry>
<entry>
<title>base-files: default_postinst() force clear luci-indexcache</title>
<updated>2014-10-14T19:01:30+00:00</updated>
<author>
<name>John Crispin</name>
<email>john@openwrt.org</email>
</author>
<published>2014-10-14T19:01:30+00:00</published>
<link rel='alternate' type='text/html' href='http://www.chd.sx/cgit/mtk-20170518/commit/?id=d099a349806f2f6a4945c382ab8b7ed47228bac4'/>
<id>d099a349806f2f6a4945c382ab8b7ed47228bac4</id>
<content type='text'>
Inside every LuCI package you need to clear luci-indexcache and
sometimes when installing non LuCI pacakges it's also needed to clear
it. Easier put it into default_postinst().

Signed-off-by: Christian Schoenebeck &lt;christian.schoenebeck@gmail.com&gt;

SVN-Revision: 42923
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Inside every LuCI package you need to clear luci-indexcache and
sometimes when installing non LuCI pacakges it's also needed to clear
it. Easier put it into default_postinst().

Signed-off-by: Christian Schoenebeck &lt;christian.schoenebeck@gmail.com&gt;

SVN-Revision: 42923
</pre>
</div>
</content>
</entry>
<entry>
<title>base-files: the USERID code path did not check for duplicate groups</title>
<updated>2014-10-14T19:01:05+00:00</updated>
<author>
<name>John Crispin</name>
<email>john@openwrt.org</email>
</author>
<published>2014-10-14T19:01:05+00:00</published>
<link rel='alternate' type='text/html' href='http://www.chd.sx/cgit/mtk-20170518/commit/?id=5efe2e5e3c2110ece5f19cc21cc3b4b31442b29a'/>
<id>5efe2e5e3c2110ece5f19cc21cc3b4b31442b29a</id>
<content type='text'>
Signed-off-by: John Crispin &lt;blogic@openwrt.org&gt;

SVN-Revision: 42919
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: John Crispin &lt;blogic@openwrt.org&gt;

SVN-Revision: 42919
</pre>
</div>
</content>
</entry>
<entry>
<title>base-files: extend USERID:=syntax</title>
<updated>2014-10-08T08:01:28+00:00</updated>
<author>
<name>John Crispin</name>
<email>john@openwrt.org</email>
</author>
<published>2014-10-08T08:01:28+00:00</published>
<link rel='alternate' type='text/html' href='http://www.chd.sx/cgit/mtk-20170518/commit/?id=a3bf98495a46796a0bb09c8a4fce4fc8516c4605'/>
<id>a3bf98495a46796a0bb09c8a4fce4fc8516c4605</id>
<content type='text'>
it is now possible to inlie the uid and gid in the syntax

USERID:=username=uid:group=gid:group2=gid2:...

Signed-off-by: John Crispin &lt;blogic@openwrt.org&gt;

SVN-Revision: 42838
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
it is now possible to inlie the uid and gid in the syntax

USERID:=username=uid:group=gid:group2=gid2:...

Signed-off-by: John Crispin &lt;blogic@openwrt.org&gt;

SVN-Revision: 42838
</pre>
</div>
</content>
</entry>
</feed>
