In the last 2-3 weeks, I have run into some issues on my ARM board.
1) The first one was the udev-dhclient issue. The basic rootfs from the Fedora-ARM page worked fine for me. But, when I installed some packages, the board refused to reboot. It used to freeze on "Starting udev". After tinkering around a lot with udev, I finally decided debugging udev wasn't my thing. So instead tried to determine which package was causing the problem. After some brute-force and binary search, realised that dhclient was the culprit. After installing dhclient, the board hung at "Starting udev" on the next reboot. Weird. For now, I have just refrained from installing dhclient and everything is working fine. Any one have any ideas about this? (Probably dhclient gets the lease calculation wrong because udev accesses the hardware clock at the same time?)
2) Now firstboot. Its weirder! So, after I installed X and Gnome package group and restarted the board, it used to hang on the login prompt (run level 3). I could key in characters using the keyboard, but hitting return gave no response whatsoever. I couldn't even ssh into the board. At first, I thought it was a system freeze, but I enabled autologin on tty3 and wrote an infinite loop in .bash_profile and it worked fine. Finally, after 1-2 days of wandering off in different directions, the only option that remained was: the keyboard input is losing its way somewhere. So, copied my i386 system's /etc/sysconfig/keyboard to ARM's rootfs. And the system now responded fine to the keyboard input. But, it hung on "password:" prompt. Damn! Finally, realised that I need to run firstboot, so that it configures keyboard and authentication (using pam.d). (Now, as I didn't have a console on this rfs, took the basic working rfs, ran firstboot there and copied the generated configs on the new rfs.) Now things worked fine! firstboot!
3) hald. I still havn't been able to resolve this one. Its been 3 days and I have no headway. Problem is, whenever I start hald, the system just freezes. No I/O, no ssh nothing. A quick infinte loop in .bash_profile suggests that the system has crashed. I have posted the logs and lshal outputs to the mailing lists. Waiting for a reply. Without HAL, my USB mouse and keyboard aren't working in Gnome.
Do leave a message if you face a problem trying something out with your setup ...
Friday, July 31, 2009
Steps for getting X-Gnome working...
1) Make sure you have your kernel compiled with atleast the following options enabled:
2) With my card, I had to add the following kernel commandline so that the driver initialised my video card at init : "video=matroxfb:init,vesa:0x11B" (I have a Matrox G550 card)
With the above two steps done, you should be able to see a console on the monitor.
3) Now, install the Gnome and X server package groups (atleast the packages listed under "mandatory".
Gnome:
PolicyKit-gnome
control-center
fedora-gnome-theme
gnome-applets
gnome-panel
gnome-session
gnome-terminal
gvfs-fuse
metacity
nautilus
yelp
gdm
X:
bitmap-fonts
desktop-backgrounds-basic
xorg-x11-drivers
xorg-x11-server-Xorg
xorg-x11-xauth
xorg-x11-xinit
)
4) Now, install the "system-config-display" package and run "system-config-display --reconfig" as root to generate xorg.conf. It generates this configuration file as some temporary file, so, copy it to /etc/X11/xorg.conf. It usually contains only generic stuff. So you might want to edit it. Eg. My xorg.conf was trying to use the fbdev driver (since, I had Matrox's fbdev support enabled in the kernel). So, I edited Xorg.conf to use the "mga" driver (Matrox driver). etc
5) Install "firstboot" and run it manually so that it configures your keyboard and authentication. Optionally add a user using useradd. Make sure that /etc/sysconfig/keyboard and /etc/pam.d/* files are generated.
6) Now just run startx or init 5. Things should just work.
(you'd probably have to start HAL daemon manually and tinker with stuff here and there. But, this is the essence of what is required to get X up)
Also, you might want to edit inittab so that the next you reboot, you are presented with a graphical interface.
Let me know if you succeed in getting it working or have some issues :)
- Device Drivers -> Graphics support -> Direct Rendering Manager
- Device Drivers -> Graphics support -> Display Device Support
- Device Drivers -> Graphics support ->
- PCI (graphics card is usually on the PCI bus)
2) With my card, I had to add the following kernel commandline so that the driver initialised my video card at init : "video=matroxfb:init,vesa:0x11B" (I have a Matrox G550 card)
With the above two steps done, you should be able to see a console on the monitor.
3) Now, install the Gnome and X server package groups (atleast the packages listed under "mandatory".
Gnome:
PolicyKit-gnome
control-center
fedora-gnome-theme
gnome-applets
gnome-panel
gnome-session
gnome-terminal
gvfs-fuse
metacity
nautilus
yelp
gdm
X:
bitmap-fonts
desktop-backgrounds-basic
xorg-x11-drivers
xorg-x11-server-Xorg
xorg-x11-xauth
xorg-x11-xinit
)
4) Now, install the "system-config-display" package and run "system-config-display --reconfig" as root to generate xorg.conf. It generates this configuration file as some temporary file, so, copy it to /etc/X11/xorg.conf. It usually contains only generic stuff. So you might want to edit it. Eg. My xorg.conf was trying to use the fbdev driver (since, I had Matrox's fbdev support enabled in the kernel). So, I edited Xorg.conf to use the "mga" driver (Matrox driver). etc
5) Install "firstboot" and run it manually so that it configures your keyboard and authentication. Optionally add a user using useradd. Make sure that /etc/sysconfig/keyboard and /etc/pam.d/* files are generated.
6) Now just run startx or init 5. Things should just work.
(you'd probably have to start HAL daemon manually and tinker with stuff here and there. But, this is the essence of what is required to get X up)
Also, you might want to edit inittab so that the next you reboot, you are presented with a graphical interface.
Let me know if you succeed in getting it working or have some issues :)
Wednesday, July 22, 2009
Fedora-ARM goes graphical ...
A picture speaks more than a 1000 words... Here is a screenshot ...
And here is the setup:
The graphics card is Matrox 550 attached to the PCI-E slot of the Kirkwood DB board.
The packages required for getting X and Gnome up aren't yet in the repos. Hopefully, I'll mash out a repo by the end of this week so that you can try it out on your boards!
yay!
And here is the setup:
The graphics card is Matrox 550 attached to the PCI-E slot of the Kirkwood DB board.
The packages required for getting X and Gnome up aren't yet in the repos. Hopefully, I'll mash out a repo by the end of this week so that you can try it out on your boards!
yay!
Tuesday, July 14, 2009
Java Bootstrap:Part 4
Ok, the sinjdoc/xml-commons-apis dependencies is causing a real problem in build packages. Let me rebuild ant with bootstrap, and include these two in its install dependencies. Done.
Built packages antlr, jakarta-oro in koji.
Manyally built packages werken-xpath and wsdl4j in my setup (they needed xalan-j2 and ant-junit respectively) which is copied from x86 in my buildroot.
Ok, mx4j seems to be quite a critical packages, and its set of dependencies is huggeeee. I am just going the copy-x86 route with this package and build other packages. Built geronimo-specs manually based on this. It used the java-1.6.0 openjdk compiler (Just wondering whether it should have used java-1.5.0-gcj). I guess we'll find out...
Now built log4j which required jms (geronimo-specs)
Now velocity and bcel have a circular dependency. I am going to copy velocity build bcel, and then rebuild velocity. And additional there is avalon-logkit dependency in there. The avalon-logkit fails to compile. It gives up on some HTML syntax mentiond in a comment. Probably the 1.5.0 javac should be used here instead of the 1.6.0. I can't fire a build on koji yet as mx4j is not completely there. Let me copy teh jars and proceed with the bcel and velocity bootstrap.
built both of them. And now for xalan-j2.
Boyyy, I think eventually, for all the packages that I manually built, we should just run an automated script which bumps up the release sensibly (so as not to conflict with newer upstream releases) and rebuild.
xalan-j2 is now ready.
Build classpath-jaf. I can't still build avalon-logkit on koji because of missing mx4j. And in my chroot the build is failing.
Ok, in order to build mx4j, xjavadoc and xdoclet are the biggies in the sense of build dependencies. And xdoclet needs struts, which has further more deps... Lets first get to xjavadoc.
Built javacc, jrefactory deps. Now build xjavadoc. Done. Also build classpath-jaf and saxon in koji, all their buildreqs are now satisfied.
Now I plan to do a mass build of all the packages in the java-development group within dist-f11-build-javabs tag. Many of them will fail, but there will be a lot of successes I hope.
Built packages antlr, jakarta-oro in koji.
Manyally built packages werken-xpath and wsdl4j in my setup (they needed xalan-j2 and ant-junit respectively) which is copied from x86 in my buildroot.
Ok, mx4j seems to be quite a critical packages, and its set of dependencies is huggeeee. I am just going the copy-x86 route with this package and build other packages. Built geronimo-specs manually based on this. It used the java-1.6.0 openjdk compiler (Just wondering whether it should have used java-1.5.0-gcj). I guess we'll find out...
Now built log4j which required jms (geronimo-specs)
Now velocity and bcel have a circular dependency. I am going to copy velocity build bcel, and then rebuild velocity. And additional there is avalon-logkit dependency in there. The avalon-logkit fails to compile. It gives up on some HTML syntax mentiond in a comment. Probably the 1.5.0 javac should be used here instead of the 1.6.0. I can't fire a build on koji yet as mx4j is not completely there. Let me copy teh jars and proceed with the bcel and velocity bootstrap.
built both of them. And now for xalan-j2.
Boyyy, I think eventually, for all the packages that I manually built, we should just run an automated script which bumps up the release sensibly (so as not to conflict with newer upstream releases) and rebuild.
xalan-j2 is now ready.
Build classpath-jaf. I can't still build avalon-logkit on koji because of missing mx4j. And in my chroot the build is failing.
Ok, in order to build mx4j, xjavadoc and xdoclet are the biggies in the sense of build dependencies. And xdoclet needs struts, which has further more deps... Lets first get to xjavadoc.
Built javacc, jrefactory deps. Now build xjavadoc. Done. Also build classpath-jaf and saxon in koji, all their buildreqs are now satisfied.
Now I plan to do a mass build of all the packages in the java-development group within dist-f11-build-javabs tag. Many of them will fail, but there will be a lot of successes I hope.
Friday, July 10, 2009
Java Bootstrap:Part 3
After about ~36 hours of build time, java-1.6.0-openjdk rpms were finally built :-) albeit in bootstrap mode.
http://arm.koji.fedoraproject.org/koji/buildinfo?buildID=13704
Trying to build avalon-framework. That needs avalon-logkit, which again needs avalon-framework. Pick the logkit jars from x86 and build avalon-framework.
Turns out the add-group-pkg thing that I had done with xml-commons-apis and sinjdoc (discussed in Part2) didn't go quite well. The way koji performs chroot setup is
1. install default build pkg group
2. init mock user by keeping mock uid/gid constant in the builder and the chroot.
3. install BuildRequires deps.
My adding these two packages in the default group, pulled in a few other packages which install user/group in the chroot in step 1 above. Thus in step 2 when mock tried to create mock uid/gid, the identifiers clashed with those already setup, thus failing the chroot setup itself.
Ok, so I took these packages out of the default package group, and included it explicitly in failing pkgs's BuildRequires.
With this I could build clean packages: java_cup, xml_commons_resolver, jlex, junit and regexp cleanly with only the BuildRequires included.
Now quite a few pkgs required jdom. It depends on xalan-j2. Copy from x86, and rebuild. worked.
Ok, now try to build classpathx-jaf. It failed with some error. Looks like the failed symbols are provided by classpathx-jaf itself. Copied the jars and trying to rebuild again. No luck.
There were some links to /etc/alternatives, that I was not copying which should have been done. Let me try that, probably that is why xerces-j2 was not getting built.
Great! that worked.
Somehow that didn't quite fix the problem of classpathx-jaf
Let me try classpathx-mail. That did work.
Now jakarta-commons-collections is needed by quite a few other things, but that BuildRequires ant-junit, which is something I don't have yet. I'll build with nodeps, lets see where it goes... Didn't quite work.. I thought so.. Hmm.. I'll probably have to rebuild ant such that it includes junit. But before that, lets see if the copying of contents of the x86 ant-junit rpm works... Did. Great!
http://arm.koji.fedoraproject.org/koji/buildinfo?buildID=13704
Trying to build avalon-framework. That needs avalon-logkit, which again needs avalon-framework. Pick the logkit jars from x86 and build avalon-framework.
Turns out the add-group-pkg thing that I had done with xml-commons-apis and sinjdoc (discussed in Part2) didn't go quite well. The way koji performs chroot setup is
1. install default build pkg group
2. init mock user by keeping mock uid/gid constant in the builder and the chroot.
3. install BuildRequires deps.
My adding these two packages in the default group, pulled in a few other packages which install user/group in the chroot in step 1 above. Thus in step 2 when mock tried to create mock uid/gid, the identifiers clashed with those already setup, thus failing the chroot setup itself.
Ok, so I took these packages out of the default package group, and included it explicitly in failing pkgs's BuildRequires.
With this I could build clean packages: java_cup, xml_commons_resolver, jlex, junit and regexp cleanly with only the BuildRequires included.
Now quite a few pkgs required jdom. It depends on xalan-j2. Copy from x86, and rebuild. worked.
Ok, now try to build classpathx-jaf. It failed with some error. Looks like the failed symbols are provided by classpathx-jaf itself. Copied the jars and trying to rebuild again. No luck.
There were some links to /etc/alternatives, that I was not copying which should have been done. Let me try that, probably that is why xerces-j2 was not getting built.
Great! that worked.
Somehow that didn't quite fix the problem of classpathx-jaf
Let me try classpathx-mail. That did work.
Now jakarta-commons-collections is needed by quite a few other things, but that BuildRequires ant-junit, which is something I don't have yet. I'll build with nodeps, lets see where it goes... Didn't quite work.. I thought so.. Hmm.. I'll probably have to rebuild ant such that it includes junit. But before that, lets see if the copying of contents of the x86 ant-junit rpm works... Did. Great!
Friday, July 3, 2009
Java Bootstrap: Part2
ant required xml-common-apis to be installed else it dumped something like this:
+ ant
/usr/bin/build-classpath: error: Could not find xml-commons-apis Java extension for this JVM
/usr/bin/build-classpath: error: Some specified jars were not found
So build xml-commons-apis, but that again uses ant, which needs xml-common-apis...
Hmm... If it is only looking for jars lets try to copy the jars from x86. I am assuming they are arch-agnostic.
And try to rebuild xml-common-apis again.
Ok, that error went away, but I can't seem to build "javadoc" files. Some search tells me I need sinjdoc to build these. sinjdoc in turn depends on java_cup.
Build java_cup
But java_cup itself builds javadoc. Disable javadoc for now.
Build sinjdoc
Import these in koji.
Ok, now rebuild sinjdoc in koji, java_cup and xml-common-apis properly in koji without any patches. This can be tagged back to dist-f11.
Hmm... Now the bootstrapped "ant" doesn't get all the packages into its dependency list, particularly sinjdoc and xml-commons-apis, thus causing builds to break.
koji add-group-pkg dist-f11-build-javabs sinjdoc xml-commons-apis
That works...
Ok, now let me try to build java-openjdk. It has a lot of dependencies, but I am hoping all of them can be built using the gcjbootstrap option.
Build xml-commons-resolver with "nodeps" (it was looking for java-1.6.0-devel). This got built cleanly.
Ok, now let me try and compile java-1.6.0-openjdk with the current set. For xalan-2 and xerces-j2, I have copied the contents into /usr/share/java. There are a few additional dependencies like netbeans and jakarta-commons-logging, but the spec file says that these are needed only for visual-vm. Let me try to disable visualvm (there is an --enable-visualvm option passed) and see if openjdk gets built.
+ ant
/usr/bin/build-classpath: error: Could not find xml-commons-apis Java extension for this JVM
/usr/bin/build-classpath: error: Some specified jars were not found
So build xml-commons-apis, but that again uses ant, which needs xml-common-apis...
Hmm... If it is only looking for jars lets try to copy the jars from x86. I am assuming they are arch-agnostic.
# mkdir /tmp/a
# rpm -ivh xml-common-apis.rpm --root /tmp/a --nodeps --ignorearch
# cp /tmp/a/usr/share/java/* /usr/share/java -a
And try to rebuild xml-common-apis again.
Ok, that error went away, but I can't seem to build "javadoc" files. Some search tells me I need sinjdoc to build these. sinjdoc in turn depends on java_cup.
Build java_cup
But java_cup itself builds javadoc. Disable javadoc for now.
Build sinjdoc
Import these in koji.
Ok, now rebuild sinjdoc in koji, java_cup and xml-common-apis properly in koji without any patches. This can be tagged back to dist-f11.
Hmm... Now the bootstrapped "ant" doesn't get all the packages into its dependency list, particularly sinjdoc and xml-commons-apis, thus causing builds to break.
koji add-group-pkg dist-f11-build-javabs sinjdoc xml-commons-apis
That works...
Ok, now let me try to build java-openjdk. It has a lot of dependencies, but I am hoping all of them can be built using the gcjbootstrap option.
Build xml-commons-resolver with "nodeps" (it was looking for java-1.6.0-devel). This got built cleanly.
Ok, now let me try and compile java-1.6.0-openjdk with the current set. For xalan-2 and xerces-j2, I have copied the contents into /usr/share/java. There are a few additional dependencies like netbeans and jakarta-commons-logging, but the spec file says that these are needed only for visual-vm. Let me try to disable visualvm (there is an --enable-visualvm option passed) and see if openjdk gets built.
Java Bootstrap: Part1
This will be a document of the exact set of steps that I have taken for Java Bootstrapping.
(Thoughts,mistakes,curses all included...) So that I could look back at anything that I have done when something goes wrong later...
Bootstrap java-1.5.0-gcj
with bootstrap=1 option in the spec file.
Forcibly install java-1.5.0-gcj-devel (it has a missing deps on eclipse-ecj)
Build ecj with gcjbootstrap=1 (when it doesn't need ant) (because ant needs ecj again)
Now that you have ecj, build "ant". Ant still needs jaxp_transform_impl, but let me see what happens if I build with 'nodeps'. This is also being built with bootstrap=1. Sigh, the gcj is a really really time consuming task...
Woohoo, that is now done tooo :-) I hope all of this works later...
In the meanwhile, created a separate tag dist-f11-build-javabs in koji which inherits from the dist-f11-build-bs tag. All the rpms that have been "bootstrapped" built "with nodeps" etc. will be imported in this tag, thus not affecting the rest of the system. Once we reach a stage where rpms can be built OOB, then we'll put them in dist-f11. Imported all these rpms in that tag.
(Thoughts,mistakes,curses all included...) So that I could look back at anything that I have done when something goes wrong later...
Bootstrap java-1.5.0-gcj
with bootstrap=1 option in the spec file.
Forcibly install java-1.5.0-gcj-devel (it has a missing deps on eclipse-ecj)
Build ecj with gcjbootstrap=1 (when it doesn't need ant) (because ant needs ecj again)
Now that you have ecj, build "ant". Ant still needs jaxp_transform_impl, but let me see what happens if I build with 'nodeps'. This is also being built with bootstrap=1. Sigh, the gcj is a really really time consuming task...
Woohoo, that is now done tooo :-) I hope all of this works later...
In the meanwhile, created a separate tag dist-f11-build-javabs in koji which inherits from the dist-f11-build-bs tag. All the rpms that have been "bootstrapped" built "with nodeps" etc. will be imported in this tag, thus not affecting the rest of the system. Once we reach a stage where rpms can be built OOB, then we'll put them in dist-f11. Imported all these rpms in that tag.
Thursday, July 2, 2009
The gcc-java rpm
Wrote: /root/rpmbuild/RPMS/armv5tel/gcc-java-4.4.0-0.34.fa3.armv5tel.rpm :-)
That was good.. And now for the bootstrapping of the java subsystem packages. From what I hear it is HARD...!
irc.freenode.net:#fedora-arm
Sounds like fun ! :-)
That was good.. And now for the bootstrapping of the java subsystem packages. From what I hear it is HARD...!
irc.freenode.net:#fedora-arm
lennert> kedars: okay, so then java bootstrapping is next
lennert> kedars: that should be fun, with all the circular build deps
kedars> lennert: you bet, I guess most of them have some bootstrap option or the other :)
lennert> kedars: yeah, which have rotten and don't work :)
lennert> kedars: e.g. ant is a lot of fun
lennert> kedars: it needs 3 or 4 passes or so
kedars> oh!
kedars> rpmbuild -ba --define 'with_bootstrap 1' /root/rpmbuild/SPECS/ant.spec
kedars> error: Failed build dependencies:
kedars> :)
lennert> don't think it'll be easy! :)
sharkcz> we were bootstrapping the java stuff on s390x recently and I can tell you it's a nightmare :-)
* kedars shudders
sharkcz> everything is in https://s390.koji.fedoraproject.org/koji/builds so you can use it as a reference
Sounds like fun ! :-)
Subscribe to:
Posts (Atom)