yocto: build linux, boot it via syslinux - yocto

I am desperately searching for two weeks at least now on how to build any linux using yocto and boot it via syslinux afterwards.
My current approach is to build the core-image-minimal-initramfs, I am using the bzImage as the kernel and the rootfs as the initramfs.
So after bitbaking it is something like this:
KERNEL bzImage.bin
APPEND initrd=rootfs.cpio.gz
Unfortunately, it doesn't work like this. I got a ton of different errors on all my approaches. The kernel is always loaded correctly, but I am having a lot of issues using the initramfs. Sometimes it is just not loading it, sometimed it is complaining about a missing rootfs.img on \dev\sda1,...
Is there anyone that could explain to me how this kind of thing works? At best by giving a working example to start somewhere.
The Yocto community seems not to be very engaged helping newbies.

Related

Adding python internal modules (cgi.py) to yocto image

I am trying to add some python libraries to my custom image.
So far, I successfully added some libraries.
Some others, like sqlalchemy, was requiring some python internal module named “dummy_threading” and thus producing some error output stating "No module named ‘dummy_threading’ ".
I found out you can solve this issue by adding ‘python-threading’ to the image.
Unfortunately, I came across a similar issue with the ‘python-requests’ library, which cannot be imported throwing 'No module named ‘cgi’ ".
cgi.py seems to be a python internal module, much like ‘dummy_threading’, but I can’t find a way to include it to my image.
I already tried to add 'python-cgi' with no success.
Does anyone have a solution to this ?
Lucas
Additionnal info:
Yocto 1.7 (I cannot upgrade it to the newest)
Python 2.7.3
Despite poky already contains maybe all what you need regarding python, as you mention, there are some internal parts of python which are provided in a different way.
A good idea to find out how to get what you miss is to inspect the manifest files. Such files can be found in your layers (basically poky and openembedded-core). For example, in poky is located in:
poky/meta/recipes-devtools/python/python-x.y-manifest.inc
If I check inside mine I can see:
FILES_${PN}-netserver="${libdir}/python2.7/cgi.* ${libdir}/python2.7/*HTTPServer.* ${libdir}/python2.7/SocketServer.* "
Notice the cgi. and the FILES_${PN}-netserver.
Finally that would mean that the package you need is actually "python-netserver".

MassTransit first run

I'm trying out MassTransit. I wrote a small console application as showed in documentation (http://docs.masstransit-project.com/en/latest/configuration/quickstart.html).
What I first ran the app, it opened another console windows, and did something that looked like an installation proccess, or some kind of file copy. I remember seeing something done in the windows directory, but it was too fast to read and understand what exactly it did.
I couldn't find any information about it. I tried starting a new .NET project and running the same code - it did not repeat.
Does MassTransit install something on the system at first run? does someone knows what exactly happens on first tun?
Thanks
I've written a post explaining how to get a quick hello world Mass Transit application up and running.
It uses RabbitMQ, but the same principles apply to MSMQ.
http://nodogmablog.bryanhogan.net/2015/04/mass-transit-with-rabbitmq-hello-world/
If you included the call to the method VerifyMsmqConfiguration() as in the quick start, then MassTransit initates any required MSMQ component installation.
The required MSMQ components are Core, LocalStorage, and Multicast.

spine.js hem server, hem build FAQ for Windows

I'm trying to mimic some basic functionality of the Todos example. After reading spinejs.com, many articles, and taking a few attempts and not getting off the ground, I do need to ask and get some help here. I wish this was more clear-cut, and I'd like to help others as well. I'm on Windows7 and I'm using spine.app to create my app, controllers, models - also using jQuery.tmpl
I'm using CS, but pretty new to it.
I'm not really sure where I need to use require (if at all) - I'm using an modules.exports = .... statement on all M, C
so index.coffee should be able to find, I assume
Maybe this is not the case - I see even though controllers/contacts used a modules.exports statement, the index still used a require.
Is index.coffee just particular about visibility ?
I see Contacts uses Contact without any require statement.
I've seen the main.App Controller be instantiated, from CS, as in Todos
or in the jQuery() script in the html, as in Contacts.
I'm assuming you should either
-build the whole thing and include application.js OR
-use the jQuery() function to create your App via javascript.
If this does compile, will it end up in public/application.js ??
I'm getting a nasty parse error,
and yes, I'm aware you consistently have to use spaces (no tabs)
That being out of the way, I'm getting hung up on the 1st require line
require('lib/setup')
Am I going to need some Cygwin stuff ? I can get it if it helps.
and I've seen the Google Groups, guillaume86's comments, contrib and CS irc channel.
I'm not sure what (date) version of hem I have
but I did try the minify: false, option and a few other things, to try to debug this.
The good news: I'm pretty stubborn and will get this to work, if I can get a little help here.
More to come, but I'm going to close at this point.
Thanks in advance for your suggestions.
I don't think this will help the OP too much, but thought I'd write this up to help anyone else who is looking to get started with these awesome tools.
Before you go further: I've rewritten this with updates at How to manage client-side JavaScript dependencies?
Here's a basic list for getting set up with a Spine, hem, coffeescript app. I only develop on Linux, so I'm not sure if some of these steps would have problems on windows, namely npm commands. Should work fine on Mac; I know other who use the same toolchain.
Install NPM: curl http://npmjs.org/install.sh | sh on a *nix system. I'll assume it's available from the command line.
npm install -g spine.app will make spine available as a global command
spine app folder will make a Spine project called app in folder, generating the right directory structure and a bunch of skeleton files to get started.
cd to folder and edit dependencies.json for the libraries you need. Add them to slug.json so that hem knows where to find them as well. You can install hem globally (npm install -g hem) or locally, as in the next step.
npm install . to download all the dependencies you just entered in, including hem.
If you take a look at the default spine config, there is a app/lib/setup.coffee where you require all the libraries you need from your dependencies. Examples:
# Spine.app had these as dependencies by default
require('json2ify')
require('es5-shimify')
require('jqueryify')
require('spine')
require('spine/lib/local')
require('spine/lib/ajax')
require('spine/lib/manager')
require('spine/lib/route')
# d3 was installed via dependencies.json
require 'd3/d3.v2'
In index.coffee, you just require lib/setup and load the main controller for your app. In addition, you need to require any other classes in those other controllers.
The default generated index.html will usually be fine for loading your app, but modify as necessary.
From folder, run node_modules/hem/bin/hem server to start a hem server, and navigate to localhost:9294 to see your app. If you installed hem globally (npm install -g hem), then hem server by itself may work, but sometimes it gets confused about the path.
Build the rest of your app using proper MVC techniques, and use stylus for CSS and eco for views.
One more thing: normally, hem server will update automatically as you update your code and save files, which makes it a cinch to debug. Running hem build will compile your app into two files, application.js, which is minified and application.css. If you run hem server after this, it will use those files and no longer update automatically. So don't hem build until you actually need a minified version of your app for deployment.
See this other thread about that: Spine.js & hem getting started
Windows is supported (there were concerns in the past, but they have been resolved). There is actually a branch of hem that being more actively developed, since the original branch is no longer being maintained by the developer. You can check out branches version0_2 or version0_3 which have been getting updates and may eventually get windows support.
HTH.

Using user-defined ADD_EXECUTABLE in CMake with KDevelop 4

We have defined our own ADD_EXECUTABLE macro (TDS_ADD_EXECUTABLE) for our cmake files which handles some nice internal functionality for us.
The problem is, when I load up our project in KDevelop 4 (linux) while it finds and builds our entire system, it does not add any of the executables to the Project Targets list for configuring the launches. This makes it a real management nightmare to do any work in KDevelop since we have to manually add all of our executables.
Is there a way to tell KDevelop our TDS_ADD_EXECUTABLE performs an ADD_EXECUTABLE... or something like this? I was actually surprised it was unable to fathom this on it's own since it's all scripted.
Any help is appreciated, thank you!
Do I understand this correctly - TDS_ADD_EXECUTABLE is just a macro around ADD_EXECUTABLE? If so, KDevelop should figure that out automagically. Post a small testcase to the correct place: http://bugs.kde.org

Eclipse Configuration Problems

Lately, I am trying to use Eclipse more often, but so far I have shied away from it because I found it so difficult to install new packages. Whenever I find and try to install a new package, the errors panel flashes a batch of configuration errors. It requires this or that package to install this one. And when I find that package, it turns out that package requires another one that I don't have...and it's been a daunting problem for me.
These days I've been running into these configuration errors:
The current configuration contains errors and this operation can have
unpredictable results.
JST Web Core Patches requires feature "org.eclipse.jst.web_core.feature ".
WST Server Core Patches requires feature "org.eclipse.wst.server_core.feature".
Specifically, I'm looking for help to figure out how to get around these errors. (There aren't any informative pages in Google for "org.eclipse.jst.web_core.feature.")
More generally, though, I am wondering what alternatives I have to the internal package management system of Eclipse? (If I'm doing it wrong and the internal system is not as difficult as it seems to me, let me know of that as well!) I've heard of Pulse, but haven't used that much.
are you using 3.4 Ganymede? .. the dependencies should be figured out and selected for you .. in 3.1 there is a 'Select Required' button in the Updates window which is supposed to locate and select for you all the dependencies