linux

How to load a shared library without loading its dependencies?

Say I have a library libfoo.so.1, which depends (according to ldd) on libbar.so.1. However, libbar.so.1 is not available at the moment. My app needs to call a function in libfoo.so.1 which doesn't require libbar.so.1 at all. Is there a way to load libfoo.so.1, resolve the function symbol and then call it without having libbar.so.1 to sa...

Python multiprocessing: Permission denied

Hi guys, I'm getting an error when trying to execute python program that uses multiprocessing package: File "/usr/local/lib/python2.6/multiprocessing/__init__.py", line 178, in RLock return RLock() File "/usr/local/lib/python2.6/multiprocessing/synchronize.py", line 142, in __init__ SemLock.__init__(self, RECURSIVE_MUTEX, 1,...

Unable to merge coverage data using genhtml

Hi all: I'm using genhtml (in Windows under cygwin) to generate a unit test coverage report from 2 coverage data files. They are all coverage data from the same unit test source file. However, when I entered the following command: perl genhtml /home/administrator/coverage1.dat /home/administrator/coverage2.dat I got the following o...

Get remote MAC address using Python and Linux

How do I get the MAC address of a remote host on my LAN? I'm using Python and Linux. ...

Java with Drupal-6/PHP

I really dislike PHP, but am pretty comfortable in Java. I have a stable Drupal installation that has been deployed to an Apache/Linux server. I don't know if the server currently supports Java. (What does it take to do that? I have programming in desktop apps for Java but never online before.) For developing new modules for my site, is...

Recreate an RPM from an installed RPM on linux

All, How to recreate an rpm which is already installed on a system on linux. Thanks.... ...

PHP and CHMOD question

Hi, I want my PHP software to be able to auto update. For this to work, I need PHP to be able to write into files both existing and non-existing (create). Will it always work if I just CHMOD the target files to be 0777 and then write into it? Or does the PHP/Apache/wtvr process need to be the owner of the file? Sometimes when people up...

gdb causes sem_wait() to fail with EINTR error

After switching from Ubuntu to CentOS 5.4 we came across a strange GDB behavior. Running application in debugger causes sem_wait() to return several (5-10) times with EINTR error. I installed the latest GDB version but it did not solve the problem. I suppose this is cause by some signal sent by GDB but I could not get any info in signal ...

I need a list of Async-Signal-Safe Functions from glibc.

Non syscall's wrappers but something like snprintf(), dprintf() ...

[Eclipse] Where is the "update site" list stored in the filesystem?

Updated2: Where is the list of software sites stored in the filesystem? I am after the file where this information is stored. Eclipse Galileo 3.5 won't let me delete broken software site repositories from the list. E.g. I am trying to get rid of the Bazaar Update Site. ...

Send and Recive file in socket programming in Linux with C/C++ (GCC)

I have a Server Client structure , both server and client can send and receive file. how to send and receive file in socket programming. one solution that I think is partition the file and send one by one segment, is there any library for file send and receive in Linux and C/C++? ...

How to force Java/awt to use a specific toolkit (qt)?

I am working on an embedded Linux device that has only qt. For some reason, Java decides to use gnu.java.awt.peer.gtk.GtkToolkit. How can I force it to use gnu.java.awt.peer.qt.QtToolkit instead (or change the default behavior)? ...

Installer/packager for a Java application for Ubuntu and SuSE

I have a Java application complied to a collection of jars that I want to make installable on Ubuntu and SuSE. I Want the installer to be able to check for the JRE, register a file association and be able to load a website on un-install. I understand Ubuntu and SuSE are based on different architectures, so is there a consistent way to d...

Bash: Recursively remove files

Does anyone have a solution to remove those pesky ._ and .DS_Store files that one gets after moving files from a Mac to A Linux Server? specify a start directory and let it go? like /var/www/html/ down... ...

Fast periodic tasks in RT Linux

What is the shortest interval at which RT Linux can execute a (real-time) periodic task? I'm investigating hardware vs. software solutions for a scientific data acquisition app. The requirements include real-time feedback control of physiological processes at approximately 40kHz. There are hardware solutions (using programable DSP chips...

Cygwin/Xming : Running Java application with drag and drop support in x-server

I have a Java application using jTree with 'drag and drop' support. When I run it on a SuSE box (Server details below ) and redirect the GUI interface using xming x-server (version details below) to a windows box , the drag and drop functionality in jTree stops working. After analyzing a bit I found that X-server is able to recognize th...

Using threads, how should I deal with something which ideally should happen in sequential order?

I have an image generator which would benefit from running in threads. I am intending to use POSIX threads, and have written some mock up code based on https://computing.llnl.gov/tutorials/pthreads/#ConVarSignal to test things out. In the intended program, when the GUI is in use, I want the generated lines to appear from the top to the ...

imagemagick unable to load remote images

Hi I have a php script, which downloads, rescales and stores an image using the following command: exec('convert -sample 100x100 http://someurl.com/pic.jpg images/somename.jpg'); It all worked fine until I put it on a different server (this one's gentoo, if that makes any difference. Apparently convert won't grab remote images, and i...

Linux+Language for video capture & Display

Hi all, Very soon we are going to work on a project with open source s/w that does many things and one of the modules concerns with capturing live feed from a usb based camera for upto 48 hours and overwriting it in a nonstop loop. This would be going on in parallel with other operations in the application. We also have to display the c...

Where can C debugger tutorials be found?

Is there any tutorial about using debuggers, when doing C programming on Linux (console mode)? ...