New: XDA launches forum for app developers. Discuss coding, tools, marketing, and more.
XDA Developers Android and Mobile Development Forum
Forgot your password?
 
Post Reply+
Tip us?
 
surdu_petru
Old
(Last edited by surdu_petru; 6th March 2012 at 10:50 PM.)
#1  
surdu_petru's Avatar
Recognized Contributor - OP
Thanks Meter 3307
Posts: 2,206
Join Date: Feb 2010
Location: Paris

 
DONATE TO ME
Thumbs up [DEV] How Enabled Archos Gen9 To Run Scripts Into init.d

HI !

As you noticed , Archos didn't enabled run scripts into init.d directory !

Of course, there init.d directory into /system/etc/init.d with two scripts , but unfortunately never runs !

I found a way can be activated init.d directory allows scripts to automatically .

I know there are other ways for do this , but I really kept to run all script into init.d directory , and not elsewhere.

For this mechanism to work , device need to be rooted and busybox to be installed.

Now is very simple to add the following command :

> /system/bin/logwrapper /system/xbin/busybox run-parts /system/etc/init.d , that will allow scripts to run in directory init.d !

This command must be placed in your system initialization file !

regard,
surdu_petru
The Following User Says Thank You to surdu_petru For This Useful Post: [ Click to Expand ]
 
gen_scheisskopf
Old
(Last edited by gen_scheisskopf; 6th March 2012 at 10:06 PM.)
#2  
gen_scheisskopf's Avatar
Senior Member
Thanks Meter 231
Posts: 1,050
Join Date: Feb 2009
Location: Poznań
Quote:
Originally Posted by surdu_petru View Post
Now is very simple to add the following command :

> /system/bin/logwrapper /system/xbin/busybox run-parts /system/etc/init.d , that will allow scripts to run in directory init.d !
Better way would be to enable init.d in kernel- sources are available- but I don't know if init.d also needs in-system support (sorry, I don't have time to play with sources, even no time to fix modded Desire kernel).

Quote:
Originally Posted by surdu_petru View Post
This command must be placed in your system initialization file !

regard,
surdu_petru
In init.rc to be exact, putting it in initramfs won't do anything.

EDIT:
So only "standard" recovery and update.zip flashing is missing?
Code:
setprop persist.world.domination 1
Twitter
 
surdu_petru
Old
#3  
surdu_petru's Avatar
Recognized Contributor - OP
Thanks Meter 3307
Posts: 2,206
Join Date: Feb 2010
Location: Paris

 
DONATE TO ME
Quote:
Originally Posted by gen_scheisskopf View Post
Better way would be to enable init.d in kernel- sources are available- but I don't know if init.d also needs in-system support (sorry, I don't have time to play with sources, even no time to fix modded Desire kernel).


In init.rc to be exact, putting it in initramfs won't do anything.

EDIT:
So only "standard" recovery and update.zip flashing is missing?
Hi!

For edit kernel work is almost "crazy"....have to be calm and have more free time.....it is not so easy .. many errors can occur during the process
I tried some time ago....but device just boot with custom boot animation , but that and nothing more !!!
I'll try in the future but I expect kernel version 3.x.y.z ICS....

Them as well so you say....we need just standard CWM Recovery for our devices !

Otherwise it looks good and beautiful !

Good Luck !
 
theguy
Old
#4  
Senior Member
Thanks Meter 42
Posts: 151
Join Date: Dec 2006

 
DONATE TO ME
Is it just a case of adding that line to the end of the Init.RC rile?
 
surdu_petru
Old
#5  
surdu_petru's Avatar
Recognized Contributor - OP
Thanks Meter 3307
Posts: 2,206
Join Date: Feb 2010
Location: Paris

 
DONATE TO ME
Quote:
Originally Posted by theguy View Post
Is it just a case of adding that line to the end of the Init.RC rile?
If you add this line as in init.rc, than the scripts in init.d will never run !!!

If you do not know how to use this command....then I think you don't need.....

Remember, this tutorial is the inscription [DEV] from developers !!!

Good luck !
 
surdu_petru
Old
(Last edited by surdu_petru; 7th March 2012 at 05:19 PM.)
#6  
surdu_petru's Avatar
Recognized Contributor - OP
Thanks Meter 3307
Posts: 2,206
Join Date: Feb 2010
Location: Paris

 
DONATE TO ME
Hi !

To help you, let me just say the next thing :

- putting this command in init.rc ( exec /system/bin/logrwapper /system/xbin/busybox run-parts /system/etc/init.d ) , normally expected to work ! , but unfortunately for me did not work. Well, now you must look for another initialization file system !!!

( Normally this command is part of a script recovery system and it was into

recovery.sh
.................................................. .................................................. ...........
#!/system/bin/sh
..........
..........
/system/bin/logwrapper /system/xbin/busybox run-parts /system/etc/init.d
.........
.........
.................................................. .................................................. ...........
@theguy.... I think you're happy now ....
 
gen_scheisskopf
Old
#7  
gen_scheisskopf's Avatar
Senior Member
Thanks Meter 231
Posts: 1,050
Join Date: Feb 2009
Location: Poznań
I've just took a closer look into ICS, it seems that init.d is enabled (take a look at /etc/init.d/rcS).
A little edit should enable all scripts to be used:
Code:
#!/bin/sh


# Start all init scripts in /etc/init.d
# executing them in numerical order.
#
for i in /etc/init.d/* ;do /* was:  /etc/init.d/S??* */

     # Ignore dangling symlinks (if any).
     [ ! -f "$i" ] && continue

     case "$i" in
	*.sh)
	    # Source shell script for speed.
	    (
		trap - INT QUIT TSTP
		set start
		. $i
	    )
	    ;;
	*)
	    # No sh extension, so fork subprocess.
	    $i start
	    ;;
    esac
done
Code:
setprop persist.world.domination 1
Twitter


XDA PORTAL POSTS

Expand Your Choice of Icons with Icon Themer

Icons are some of the most commonly themed elements of the Android UI, and there is certainly no … more

MicrowaveTimePicker Brings 4.2 TimePicker to 2.1+ Devices

It’s frustrating to see slick new features that you can’t use when … more

What’s Possible with CASUAL & How to Make Your Own CASUAL – XDA Developer TV

XDA Elite Recognized Developer AdamOutler is known … more

Pearl Chen to Talk NFC Development at XDA:DevCon 2013

From HTML to LEDs or Android to Arduino, Hardware Hacking is a pastime of many people … more