I have problem using gcc/g++ after I changed the machine I use, I installed gcc-4.9.2 in my previous machine, when I moved to the new machine, I copied gcc folder to the new machine. When I try to use I get this error : I have already checked this question : `GLIBC_2.11′ not found If it says right, the …
How to get the IP address of an LXC container?
I have started the lxc using lxc-start. Now, how I can get the IP address of the container? Answer Source
log4net cross platform XML config
I have a requirement to store my log files in a Logs sub folder. Normally you would do this my modifying the FileAppender in you App.config as follows: However this is not cross platform because if you run this on linux it will create a file called ‘LogsMyLog.log’ rather then a directory. This is …
How can I make my program compile without warning?
I should compile my program with spec flags to gcc. Then gcc complained about return values not taken care of. WhenI use variables to take the return values then gcc complains again: How can I resolve the warnings? My program is as follows. Answer Reading between the lines, I guess the original problem you we…
GTK/GDK Algorithm to take full screenshots of all monitors
I’m fairly new to the whole GTK game and want to create an algorithm to take screen shot of all monitors. I was thinking something along these lines: gdk_display_manager_list_displays each display can have multiple screens (screens means monitors?) so use gdk_display_get_n_screens to get monitors per di…
dev/ttyO0 used in AR Drone 2.0 – Reverse Enginnering
I read an interesting article about coding for the AR Drone 2.0 from Parrot. In this code they us nodeJS to talk to the drone. Therefore the code starts out with creating a Stream to /dev/ttyO0 I am starting out to learn more about the background of linux functionalities and would like to know: How do you ini…
How to add a name to namespace?
As I know, I can use the “clone” to create a process and a namespace, but the namespace created in this way has no name. For example, I create a network namespace with the parameter: CLONE_NEWNS, but in the command “ip netns list”, there is no namespace list because the namespace creat…
Android linux deploy (localhost LAMP server configuration)
Hello my fellow humans! I have two rooted android phones, each running a chroot environment using the “Linux Deploy” app (HTC desire 510 running Kali Linux and vodafone smart 4 mini running Ubuntu). On each device, I have installed LAMP using: When I start apache2 service, the server says that it …
sed – insert line after X lines after match
I have the following contents: Using sed, I want to insert line at the INSERT LINE HERE label. The easiest way should be: find text “function_1” skip 3 lines insert new line But none of the known sed options do the job. inserts new_text right after ‘function_1’ inserts new_text after e…
How to add poll function to the kernel module code?
As I know, to inform the user space from kernel space, one way is to using poll. That means kernel driver should provide poll method first. Below code is found from internet, and it really works! I can do like this to make it work: And then to see the result. But how to add poll method to it? I