linux

In a Linux user space process what is the address of the vsyscall page?

I would like to acquire the address of the vsyscall page for my own uses. I only have two ideas here: alter the compiler to store this information in some known location after it is given to __start, or read /proc/[pid]/maps. I really don't want to read /proc/ as that is slow and shouldn't be necessary. I also don't want to make compi...

Linking against multiple shared libraries that all linked against a common static library

Say you have 2 share libraries, lib1.so and lib2.so, that both have libcommon.a statically linked into them. Would the compiler complain about ambiguous symbol reference if you were to dynamically link both lib1.so and lib2.so? Or would be the compiler be smart enough to know libcommon symbols are shared between lib1 and lib2 and allow y...

Attach/Detach to a remote instance of Eclipse

When using Eclipse over X-Windows on a remote shell (X port forwarding), is there a way to simply detach my X connection and come back to the process later. For a little more clarity, I'm on a Windows machine and have to reboot. I'd like to keep Eclipse running and come back where I left off. Eclipse is running on my Windows machine t...

Compile e text editor on Linux

Final Edit: show me how to compile e text editor on Ubuntu (32 bit Karmic) and you get the bounty ...

Run Xcode in Linux?

Is there such a thing? Mac OS X was based on BSD Unix so is it possible? Or from what I have heard, there is a MonoDevelop plugin that has an iPhone sim. ...

What is libg2c library?

I have found the code which links against of 'g2c' library. Why do I need it? Just would like to understand why it might be important and what it does in general. Thanks! ...

Linux kernel scheduling

Hi, I wish to know how Old Linux scheduling algorithm SJF (shortest job first) calculates the process runtime ? ...

running a parallel port controlling program through php.

I have a program that is interacting with hardware via parallel port programming. i had compiled it and using its object file to interact with the hardware (a simple led). when i execute it directly on the shell it serves the purpose of glowing the LED but when i execute it using shell_exec() in php the command is executed but unable to ...

Skip all databases and run only specific one

I have a sql file generated by "mysqldump --all-databases" . There are many databases in it. What I want to do is to update my local database but only a specific one, not all. I tried to use "mysql -database=db_name < file.sql" but it updated all databases. Is there a way to skip all databases except the one that I want. ...

kupdated slows down voice transmission

Hi I'm working on a device which primarily serves as a VoIP terminal. Currently I wrote an application whose main purpose is to record sound from the enlightened sound daemon v0.2.38 ( and to do some magic with it ). The problem is, that writing of the recorded data to disk ( or even calling rename to move a file ) causes kupdated daem...

Good book for C programming on linux

Possible Duplicate: Good book on Programming C in Unix environment? Can you suggest me some books for C programming on linux... ...

Struct timeval to printable format

Could you please help me how to format a struct timeval instance to human readable format like "2010-01-01 15:35:10.0001"? ...

Stream data into a file in a linux device driver

I am rather new to Linux device driver programmring, but for debugging purposes, I would like to write a stream of data directly to a file. Or maybe I should aks the question differently: I have a system-on-chip, where one module provides a data stream. The module has to be initlized with a write address. Instead of writing the data int...

Creating software for Linux with Qt: distros, desktop environments and other decisions

Hi, I want to start working on a personal project and I want to make it cross-platform. All of my Linux work was done for business customers, so the target distro was specified in advance, but this is different. The project will be open source and use Qt. Here's what I'm wondering: Is it enough if I do my dev + testing on one distro...

Compiling LAMP from source - apache2 error "no MPM package installed"

Hi, I've compiled LAMP from source on a Ubuntu VPS. I had to remove a previously installed version of Apache then I manually compiled all the packages, which seems to have worked up unto a point - when I try to run commands like "/etc/init.d/apache2 restart" I get the following error - No apache MPM package installed. I have deliberately...

Can 'connect' call on socket return sucessfully without server calling 'accept'?

Server has created a socket and bound to a port and started a thread which is in loop to accept the connection. Sometime later loop exited due to an exception resulting in thread exit but socket is still bounded to port. Now if client does a 'connect' to this server, it is succeeding. How is it possible? If I understand correctly, 'conne...

a sufficient way to show logs in a graphical interface using whiptail in bash

hello I'm trying to represent log files via the whiptail's infobox. The only setback is that I don't want to scroll down through hundreds of log lines. Is there a way to make the scroll bar go to the end of the box automatically? Thanks for the help. ...

A signalling thread problem

Hello - I am attempting to get a thread running which will be responsible for detecting a signal from any other thread within the same process. sigset_t sigset; sigfillset(&sigset); pthread_sigmask( SIG_BLOCK, &sigset, &old ); Once i've done this, I then daemonize the process: m_child = fork(); if (m_child == 0) { // Start t...

Running the shell scripts in Background

Hello, I would to give the user the feature to run the shell script in background. My shell program instantiates a number of other shell scripts. Here is a small code snippet of my script ./main.sh # Main script in main.sh I call preprocessing.sh create_dir.sh handle_file.sh post_processing.sh report_generation.sh I would like t...

Look for function calls in a bunch of templates by using a script

Hi all, I have a load of php templates which uses a custom translate function "__", i.e. <?php echo __("Hello"); ?> I need to write a script which will look for all these function calls (there are about 200 templates). I.e. it will find __("Hello") and add it to a sentences to be translated array. For example it will find: $senten...