473,320 Members | 2,080 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Installation Problem

I am trying to install python, but am having problems. I did what the
README file said, and it created an executible code in the current
directory as it said it would when I typed "make". It seemed to say to
copy the executable over to the /usr/local directory, which I did.

If I type ./python in the directory I did the make in I get:

execonn# ./python
Python 2.4.3 (#1, May 31 2006, 07:50:04)
[GCC 2.95.4 20020320 [FreeBSD]] on freebsd4
Type "help", "copyright", "credits" or "license" for more information.

Which is I believe correct.

But if I type /usr/local/python I get:

Python 2.4.3 (#1, May 31 2006, 07:50:04)
[GCC 2.95.4 20020320 [FreeBSD]] on freebsd4
Type "help", "copyright", "credits" or "license" for more information. execonn# /usr/local/python
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
'import site' failed; use -v for traceback
Python 2.4.3 (#1, May 31 2006, 07:50:04)
[GCC 2.95.4 20020320 [FreeBSD]] on freebsd4
Type "help", "copyright", "credits" or "license" for more information.


So nothing that tries to use it works.

Any assistance would be appreciated.

Thanks,

Marshall

Jun 4 '06 #1
9 1398
Marshall Dudley wrote:
I am trying to install python, but am having problems. I did what the
README file said, and it created an executible code in the current
directory as it said it would when I typed "make".
"make" doesn't install the interpreter by itself; you're supposed to use
"make install" (or "make altinstall") to do that.

just copying the interpreter binary around won't give you a complete
install.
It seemed to say to copy the executable over to the /usr/local
directory, which I did.


the README says:

To start building right away (on UNIX): type "./configure" in the
current directory and when it finishes, type "make". This creates an
executable "./python"; to install in /usr/local, first do "su root"
and then "make install".

the detailed installation section says:

To install the Python binary, library modules, shared library modules
(see below), include files, configuration files, and the manual page,
just type

make install

/.../

</F>

Jun 4 '06 #2
Sorry, this is a FreeBSD system 4.8-RELEASE

I found another set of documents that say to use the following to
install::

python setup.py install

but after running it, I still have the same problem.

Marshall

Marshall Dudley wrote:
I am trying to install python, but am having problems. I did what the
README file said, and it created an executible code in the current
directory as it said it would when I typed "make". It seemed to say to
copy the executable over to the /usr/local directory, which I did.

If I type ./python in the directory I did the make in I get:

execonn# ./python
Python 2.4.3 (#1, May 31 2006, 07:50:04)
[GCC 2.95.4 20020320 [FreeBSD]] on freebsd4
Type "help", "copyright", "credits" or "license" for more information.

Which is I believe correct.

But if I type /usr/local/python I get:

Python 2.4.3 (#1, May 31 2006, 07:50:04)
[GCC 2.95.4 20020320 [FreeBSD]] on freebsd4
Type "help", "copyright", "credits" or "license" for more information. execonn# /usr/local/python
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
'import site' failed; use -v for traceback
Python 2.4.3 (#1, May 31 2006, 07:50:04)
[GCC 2.95.4 20020320 [FreeBSD]] on freebsd4
Type "help", "copyright", "credits" or "license" for more information.


So nothing that tries to use it works.

Any assistance would be appreciated.

Thanks,

Marshall


Jun 4 '06 #3
Fredrik Lundh wrote:
Marshall Dudley wrote:
I am trying to install python, but am having problems. I did what the
README file said, and it created an executible code in the current
directory as it said it would when I typed "make".
"make" doesn't install the interpreter by itself; you're supposed to use
"make install" (or "make altinstall") to do that.

just copying the interpreter binary around won't give you a complete
install.
> It seemed to say to copy the executable over to the /usr/local
> directory, which I did.


the README says:

To start building right away (on UNIX): type "./configure" in the
current directory and when it finishes, type "make". This creates an
executable "./python"; to install in /usr/local, first do "su root"
and then "make install".


Yes, that is what I did. Since I ended up with no executable in /usr/local,
or /usr/local/bin and it said " This creates an
executable "./python" (which it did); to install in /usr/local" I copied
the one it created over to /usr/local, then later /usr/local/bin


the detailed installation section says:

To install the Python binary, library modules, shared library modules
(see below), include files, configuration files, and the manual page,
just type

make install

/.../

</F>


Yes, I typed "make install". But nothing gets put into /usr/local or
/usr/local/bin without me copying it over. And if I run python it in the
directory I unpacked it in, it works, but if I run the copy in /usr/local or
/usr/local/bin it does not.

I also tried the instuctions on their web site:

"python setup.py install"

But get the same result, but it copies and puts the following 3 files in the
/usr/local/bin dir.

-rwxr-xr-x 1 root wheel 96 May 31 07:50 idle
-rwxr-xr-x 1 root wheel 81 May 31 07:50 pydoc
-rwxr-xr-x 1 root wheel 18017 May 31 07:50 smtpd.py

Marshall

Jun 4 '06 #4
Marshall Dudley <md*****@king-cart.com> wrote:
Sorry, this is a FreeBSD system 4.8-RELEASE

I found another set of documents that say to use the following to
install::

python setup.py install

but after running it, I still have the same problem.


[top-posting trimmed, please don't do that]

Doesn't the port work for 4.8? It does work on FreeBSD 4.11, but there
may have been changes to the ports system since 4.8. (You should
consider updating to 4.11.)

There are several patch files in the FreeBSD port, including
one to setup.py.

The easiest way is to cvsup your ports tree and then

cd /usr/ports/lang/python
make
make install
make clean

--
Warren Block * Rapid City, South Dakota * USA
Jun 4 '06 #5
Warren Block wrote:
Marshall Dudley <md*****@king-cart.com> wrote:
Sorry, this is a FreeBSD system 4.8-RELEASE

I found another set of documents that say to use the following to
install::

python setup.py install

but after running it, I still have the same problem.


[top-posting trimmed, please don't do that]

Doesn't the port work for 4.8? It does work on FreeBSD 4.11, but there
may have been changes to the ports system since 4.8. (You should
consider updating to 4.11.)

There are several patch files in the FreeBSD port, including
one to setup.py.

The easiest way is to cvsup your ports tree and then

cd /usr/ports/lang/python
make
make install
make clean

--
Warren Block * Rapid City, South Dakota * USA


Now I have a python that runs, but the application I want to run it on
"denyhosts" gives me the following error:

Python >= 2.3 required. You are using: 2.2.2 (#1, Jun 4 2006, 16:29:13)
[GCC 2.95.4 20020320 [FreeBSD]]

################################################## ####################

Visit http://www.python.org and download a more recent version of
Python.

You should install this version in addition to your current version
(rather than upgrading your current version) because your system might
depend on the current version. After installing the newer version, for
instance version 2.4, simply invoke DenyHosts explicitly with the new
version of python, eg:

$ python2.4 ./denyhosts.py

################################################## ####################

Is it not possible to install the latest version of python on my FreeBSD
system? Upgrading the FreeBSD is not an option since this is a production
system and everything else is working fine.

Marshall

Jun 4 '06 #6
Marshall Dudley wrote:
Is it not possible to install the latest version of python on my FreeBSD
system? Upgrading the FreeBSD is not an option since this is a production
system and everything else is working fine.
that's really a FreeBSD question, isn't it?
You are using: 2.2.2 (#1, Jun 4 2006, 16:29:13)


Python 2.2.2 was originally released in 2002, but your copy was built
yesterday? did the FreeBSD source kit you got really contain a four
year old release? heck, it's not even the 2.2 release in the 2.2
series, and there's been two major releases since then.

are you sure you cannot get a *prebuilt* newer version from some FreeBSD
repository?

or if that's not possible, use the *standard* python.org source kit?
after all, it's known to build and install on virtually any modern Unix
or Unix-like system (and most non-Unix systems too), and you're free to
install it everywhere you want (and the default on Unix is /usr/local,
so you don't even have to read the README; just make sure you use the
real thing, instead of some botched FreeBSD-specific source kit).

</F>

Jun 5 '06 #7
Fredrik Lundh wrote:
Marshall Dudley wrote:
Is it not possible to install the latest version of python on my FreeBSD
system? Upgrading the FreeBSD is not an option since this is a production
system and everything else is working fine.
that's really a FreeBSD question, isn't it?
> You are using: 2.2.2 (#1, Jun 4 2006, 16:29:13)


Python 2.2.2 was originally released in 2002, but your copy was built
yesterday? did the FreeBSD source kit you got really contain a four
year old release? heck, it's not even the 2.2 release in the 2.2
series, and there's been two major releases since then.


No, there was no copy on the system. When I did the make the last time as
directed in the previous message, it downloaded it from the python site, then
compiled and installed it. The 2.2.2 release is what it downloaded.


are you sure you cannot get a *prebuilt* newer version from some FreeBSD
repository?
I did compile a new copy originally, and it worked fine in the directory that I
compiled it in, but when moved to the /usr/local/bin directory where it should
have installed, it complains that it cannot find it's library. It may just be a
matter of what directory I should put the sources into and compile from, but I
can find nowhere that this information is provided, everything I see indicates I
can compile it in any directory.


or if that's not possible, use the *standard* python.org source kit?
after all, it's known to build and install on virtually any modern Unix
or Unix-like system (and most non-Unix systems too), and you're free to
install it everywhere you want (and the default on Unix is /usr/local,
so you don't even have to read the README; just make sure you use the
real thing, instead of some botched FreeBSD-specific source kit).
That is what I did originally, downloaded the latest version from the main
python site. I compiled by the README file instructions, and I compiled by the
instructions on the python url which are different, but both gave identical
results, compiles fine, runs fine from the directory I compiled in, but will
error out when I move the executible code to and run it from the /usr/local/bin
or the /usr/local directory.

Marshall


</F>


Jun 5 '06 #8
Marshall Dudley wrote:
That is what I did originally, downloaded the latest version from the main
python site. I compiled by the README file instructions, and I compiled by the
instructions on the python url which are different, but both gave identical
results, compiles fine, runs fine from the directory I compiled in, but will
error out when I move the executible code to and run it from the /usr/local/bin
or the /usr/local directory.


deep sigh. alright, one more attempt:

DO NOT copy any binaries yourself, DO NOT use any bogus FreeBSD source
distribution, DO NOT download 2.2.2 if you need Python 2.3 or newer, DO
NOT type random commands into the shell when logged in as root. etc.

just follow these instructions:

1) go fetch a the latest source code kit from python.org. I recommend
getting Python-2.4.3.tgz:

$ wget http://www.python.org/ftp/python/2.4.3/Python-2.4.3.tgz

2) unpack the file to a local temporary directory

$ tar xvfz Python-2.4.3.tar.gz
$ cd Python-2.4.3

3) in that directory, type the following commands:

$ ./configure
$ make
$ ./python

4) verify that the ./python command prints the following:

Python 2.4.3 [followed by some number, and today's date]
Type "help", "copyright", "credits" or "license" ...


5) press control-D to leave the interpreter

6) login as root, and type

# make install

(or use sudo, or whatever mechanism you usually do to run a command as root)

7) log out from root. that's it. python is now installed as
"/usr/local/bin/python", *and* as "/usr/local/bin/python2.4". support
libraries and other files are installed under /usr/local/lib/python2.4
and /usr/local/include/python2.4.

</F>

Jun 5 '06 #9
Fredrik Lundh wrote:
Marshall Dudley wrote:
That is what I did originally, downloaded the latest version from the main
python site. I compiled by the README file instructions, and I compiled by the
instructions on the python url which are different, but both gave identical
results, compiles fine, runs fine from the directory I compiled in, but will
error out when I move the executible code to and run it from the /usr/local/bin
or the /usr/local directory.
deep sigh. alright, one more attempt:

DO NOT copy any binaries yourself, DO NOT use any bogus FreeBSD source
distribution, DO NOT download 2.2.2 if you need Python 2.3 or newer, DO
NOT type random commands into the shell when logged in as root. etc.

just follow these instructions:

1) go fetch a the latest source code kit from python.org. I recommend
getting Python-2.4.3.tgz:

$ wget http://www.python.org/ftp/python/2.4.3/Python-2.4.3.tgz


OK, did that again.


2) unpack the file to a local temporary directory

$ tar xvfz Python-2.4.3.tar.gz
$ cd Python-2.4.3
did that again.

3) in that directory, type the following commands:

$ ./configure
$ make
$ ./python

OK, did that, got:

Python 2.4.3 (#2, Jun 5 2006, 11:15:03)
[GCC 2.95.4 20020320 [FreeBSD]] on freebsd4
Type "help", "copyright", "credits" or "license" for more information.

4) verify that the ./python command prints the following:

Python 2.4.3 [followed by some number, and today's date]
Type "help", "copyright", "credits" or "license" ... >>>

5) press control-D to leave the interpreter


Ok, did that.


6) login as root, and type

# make install
OK, did that again.

(or use sudo, or whatever mechanism you usually do to run a command as root)

7) log out from root. that's it. python is now installed as
"/usr/local/bin/python", *and* as "/usr/local/bin/python2.4". support
libraries and other files are installed under /usr/local/lib/python2.4
and /usr/local/include/python2.4.

</F>


OK, that is exactly what I had done previously, but this time there IS a copy of
python in the /usr/local/bin directory, and this time it DOES work. Don't know why
the previous times it put in the /usr/local/bin/pydoc, /usr/local/bin/idle and
/usr/local/bin/smtpd.py files, but not the python executable one.

Thanks,

Marshall
Jun 5 '06 #10

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

Similar topics

3
by: Rob Brown | last post by:
I put together an installation program and it works great the first time. The problem I have is that we want the users to be able to rerun the installation without needing to uninstall the older...
0
by: Michał Januszczyk | last post by:
Hello. I've got the following problem: I created a windows installer project that installs my application. The application works with some files. I want to include some example files with the...
1
by: 3f | last post by:
Hello; We have made a web application that people can download from our web site and installed on: Windows XP Windows 2000 Professional Windows 2003 Server Windows 2000 Server
2
by: mb12036 | last post by:
All- Having a problem installing a DB2 client on a machine running AIX version 5.0. Client appeared to install one time succesfully, then was uninstalled and a reinstall was attempted. For...
2
by: news.symantec.com | last post by:
Hi All, I'm trying to install DB2 Enterprise Edition 8.1 (partitioned installation) onto a clean Win 2k SP4 advanced server box. The problem is the partitioned installation requires a "Domain...
4
by: Will Honea | last post by:
Wanting to look at V9, I attempted to install Db2 Express-C on a Suse Linux box I use as a sandbox. Since I was less that thorough when removing previous installations of V8 and V7, the...
4
by: James | last post by:
I am going to install DB2 version 9 on Windows XP workstation. But I can not continue the installation after I issue the command "setup /i en". System shows me that "A major error occoured while...
2
by: =?Utf-8?B?R3JlZw==?= | last post by:
I have no idea where to post this question, or even if its appropriate for me to post it here. I don't know if installing a VB.Net program has caused the problem I'm having or not. All I know is I...
0
by: Now You Know | last post by:
Best Christmas Lights Decoration Sale Installation in Los Angeles 818-386-1022 (These types of Innovative lights will definetly add to your Christmas decor) Here are the tips to use: The most...
0
by: Now You Know | last post by:
Best Christmas Lights Decoration Sale Installation in Los Angeles 818-386-1022 (These types of Innovative lights will definetly add to your Christmas decor) Here are the tips to use: The most...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.