473,779 Members | 2,058 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

'import dl' on AMD64 platform

Hi all

I have a tricky situation that's preventing my Python/SWIG/C
application from running on the Debian Etch AMD64 platform.

It seems that the 'dl' module is not available on that platform. The
only reason I need the 'dl' module, however, is for the values of
RTLD_LAZY etc, which I use with sys.setdlopenfl ags() in order to make
my imported SWIG module share its symbols correctly with more deeply-
nested plugin modiles in my C-code layer.

I wonder if there is a workaround for this -- perhaps another way to
access the values of those RTLD flags?

Cheers
JP

Feb 18 '07 #1
6 2001
John Pye <jo******@gmail .comwrote:
I have a tricky situation that's preventing my Python/SWIG/C
application from running on the Debian Etch AMD64 platform.

It seems that the 'dl' module is not available on that platform. The
only reason I need the 'dl' module, however, is for the values of
RTLD_LAZY etc, which I use with sys.setdlopenfl ags() in order to make
my imported SWIG module share its symbols correctly with more deeply-
nested plugin modiles in my C-code layer.

I wonder if there is a workaround for this -- perhaps another way to
access the values of those RTLD flags?
Read stuff out of /usr/include/bits/dlfcn.h ?

It seems to be a constant 1 anyway

#define RTLD_LAZY 0x00001

You could try compiling the dl module by hand.

--
Nick Craig-Wood <ni**@craig-wood.com-- http://www.craig-wood.com/nick
Feb 18 '07 #2
python help,

I'm testing on xpPro

I have a simple module that sends text files to a
printer. Then, it moves the file to the 'Fprtd'
directory. The module contains the following
code;
#####

for n in PrtList:
os.system('type '+n+ ' prn'
os.system('move '+n+ ' Fprtd')

#####

os.system opens and closes a window for each file
it sends to the printer and again for each time
it moves a file to the Fprtd directory. If there
were only a few files, this wouldn't be so bad.
But, when the files number 300 to 400 it becomes
objectionable.

Is there any way to supress the flashing window.

xp no longer allows the 'ctty' command.
jim-on-linux
Feb 18 '07 #3
En Sun, 18 Feb 2007 18:09:23 -0300, jim-on-linux <in*****@verizo n.net>
escribió:
I have a simple module that sends text files to a
printer. Then, it moves the file to the 'Fprtd'
directory. The module contains the following
code;
#####

for n in PrtList:
os.system('type '+n+ ' prn'
os.system('move '+n+ ' Fprtd')

#####

os.system opens and closes a window for each file
it sends to the printer and again for each time
it moves a file to the Fprtd directory. If there
were only a few files, this wouldn't be so bad.
But, when the files number 300 to 400 it becomes
objectionable.
Just code the above in Python itself.
type xxx prn == copy xxx prn == shutil.copyfile (xxx,prn)
move xxx Fprtd == shutil.move(xxx , Fprtd)

--
Gabriel Genellina

Feb 18 '07 #4
On Sunday 18 February 2007 17:27, Gabriel
Genellina wrote:
En Sun, 18 Feb 2007 18:09:23 -0300,
jim-on-linux <in*****@verizo n.net>

escribió:
I have a simple module that sends text files
to a printer. Then, it moves the file to the
'Fprtd' directory. The module contains the
following code;
#####

for n in PrtList:
os.system('type '+n+ ' prn'
os.system('move '+n+ ' Fprtd')
Thanks Geneilina,
It works fine.
shutil.copyfile (xxx,prn)
jim-on-linux

#####

os.system opens and closes a window for each
file it sends to the printer and again for
each time it moves a file to the Fprtd
directory. If there were only a few files,
this wouldn't be so bad. But, when the files
number 300 to 400 it becomes objectionable.

Just code the above in Python itself.
type xxx prn == copy xxx prn ==
shutil.copyfile (xxx,prn) move xxx Fprtd ==
shutil.move(xxx , Fprtd)

--
Gabriel Genellina
Feb 18 '07 #5
On Feb 19, 6:30 am, Nick Craig-Wood <n...@craig-wood.comwrote:
John Pye <john....@gmail .comwrote:
application from running on the Debian Etch AMD64 platform.
It seems that the 'dl' module is not available on that platform. The
only reason I need the 'dl' module, however, is for the values of
RTLD_LAZY etc, which I use with sys.setdlopenfl ags() in order to make
my imported SWIG module share its symbols correctly with more deeply-
nested plugin modiles in my C-code layer.
I wonder if there is a workaround for this -- perhaps another way to
access the values of those RTLD flags?

Read stuff out of /usr/include/bits/dlfcn.h ?

It seems to be a constant 1 anyway

#define RTLD_LAZY 0x00001

You could try compiling the dl module by hand.
Well yes, and that's the workaround I came up with: for systems that
don't provide the 'dl' module, I just default to the values I found on
my linux (ubuntu) system. This is a nasty hack however.

I wonder if anyone could say why the Debian people left out this
important module from their AMD64 platform?

Cheers
JP

Feb 19 '07 #6
John Pye <jo******@gmail .comwrote:
On Feb 19, 6:30 am, Nick Craig-Wood <n...@craig-wood.comwrote:
John Pye <john....@gmail .comwrote:
application from running on the Debian Etch AMD64 platform.
It seems that the 'dl' module is not available on that platform. The
only reason I need the 'dl' module, however, is for the values of
RTLD_LAZY etc, which I use with sys.setdlopenfl ags() in order to make
my imported SWIG module share its symbols correctly with more deeply-
nested plugin modiles in my C-code layer.
I wonder if there is a workaround for this -- perhaps another way to
access the values of those RTLD flags?
Read stuff out of /usr/include/bits/dlfcn.h ?

It seems to be a constant 1 anyway

#define RTLD_LAZY 0x00001

You could try compiling the dl module by hand.

Well yes, and that's the workaround I came up with: for systems that
don't provide the 'dl' module, I just default to the values I found on
my linux (ubuntu) system. This is a nasty hack however.

I wonder if anyone could say why the Debian people left out this
important module from their AMD64 platform?
There is a note (from a 2002) in the changelog about

* Always build the dl module. Failure in case of
sizeof(int)!=si zeof(long)!=siz eof(void*)
is delayed until dl.open is called. Closes: #141681.

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=141681

so maybe it doesn't build properly on amd64. That, or it violating
the free software guidelines (unlikely in this case) are the two major
reasons for missing features in debian.

The normal procedure would be to try the package from unstable.

If that doesn't work then report a bug. (Easiest with the reportbug
package.)

I don't have an amd64 machine to try otherwise I'd try it for you!

I looked in the latest packages for python2.4 & python2.5 for amd64
and /usr/lib/python2.4/lib-dynload/dl.so doesn't appear to be there.

http://packages.debian.org/cgi-bin/s...ge=9&number=50

--
Nick Craig-Wood <ni**@craig-wood.com-- http://www.craig-wood.com/nick
Feb 20 '07 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
519
by: Plymouth Acclaim | last post by:
Hi guys, We have a problem with Dual AMD64 Opteron/MySQL 4.0.18/Mandrake 10 for a very high volume site. We are evaluating the performance on our new server AMD64 and it seems it's slow compared to Dual Xeon/MySQL 4.0.15/RedHat8 and Dual Xeon/MySQL 4.0.18/Mandrake 10. And it seems there are zombie threads. 570 threads in 1 hour and we didn't even use JDBC connection pooling at all. These threads are supposed to be gone within 60...
4
1360
by: Ilya | last post by:
Are there any compilers for AMD64 target available besides GNU, PGI? What about Microsoft VC++? Thank you in advance!
6
1762
by: codefixer | last post by:
Hi, I don't understand why DELL is unwilling to sell AMD64 products. Steve Felice, VP @ DELl says their is no customers demand for AMD64. Suck to be Steve. From various Linux flavors to BSD, the OS rocks on AMD64 macs. I have seen conformance test suite benhcmarks which are better on AMD64 than on f**ing Itanium. I feel this is a ridiculous policy @ DELL not to sell AMD products. Anyone in FTC listening ?
10
1984
by: magneticlemur | last post by:
Hi, Does anyone know of an available downloader for an amd64 bit build of (a modern) python? I've done my due diligence search of python docs and mailing archives, and I'm somewhat mystified by the lack of info on this topic. I'm embedding python in a native 64 bit application so python32 using WOW64
3
1722
by: Allcomp | last post by:
Hello, I would like to know if it is (or will) be possible to compile a VB.NET project for AMD64. Actually, I can only see informations to compile a C++ (.NET) project for AMD64, but I can't see anything about VB.NET (or C#). I have also seen the it is possible to compile a C++ (Version 6) project for AMD64. Is there the same for VB6? In fact, I will soon begin a new project, and as there are a lot of
3
1452
by: RossettoeCioccolato | last post by:
The version of dumpbin that ships with VC8 will disassemble x86 code. Is there a version of dumpbin that ships with VC8 that is able to disassemble AMD64 object code? Or is there some other solution. I have compiled both x86 and x64 versions of a binary using VC8 and I need to see, in both cases, whether the resulting object code is what I expected. Regards, George.
3
1802
by: Robin Becker | last post by:
Does anyone know if it's possible to run python as a 32 bit app on AMD64's? One of our host providers AMD Athlon 64 3000+ and we are currently using a celeron which is real slow. The problem is that this machine would be a backup for another which is 32 pentium 4. If I have to recompile/debug all the extensions etc etc for another architecture it might not seem so attractive. -not ready for 64bitly yrs- Robin Becker
43
1894
by: jimenezrick | last post by:
- Code compiled by GCC: int main(void) { char a = "123"; char b = "abc"; printf("%p %p\n", a, b); return 0;
3
2777
by: stuntgoat | last post by:
import zlib works in Python 2.4 (debian etch AMD64 - default python version for that distro) I built python 2.5 from source; zlib is not importable. I am trying to compile MySQLdb. any clues about how to get zlib able to be imported in 2.5? -sg
0
9636
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9474
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
10074
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9930
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8961
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5373
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4037
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3632
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2869
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.