##// END OF EJS Templates
no mention os setup.py install
Matthias Bussonnier -
Show More
@@ -1,74 +1,74 b''
1 # Set this prefix to where you want to install the plugin
1 # Set this prefix to where you want to install the plugin
2 PREFIX=/usr/local
2 PREFIX=/usr/local
3
3
4 NOSE0=nosetests -vs --with-doctest --doctest-tests --detailed-errors
4 NOSE0=nosetests -vs --with-doctest --doctest-tests --detailed-errors
5 NOSE=nosetests -vvs --with-ipdoctest --doctest-tests --doctest-extension=txt \
5 NOSE=nosetests -vvs --with-ipdoctest --doctest-tests --doctest-extension=txt \
6 --detailed-errors
6 --detailed-errors
7
7
8 SRC=ipdoctest.py setup.py ../decorators.py
8 SRC=ipdoctest.py setup.py ../decorators.py
9
9
10 # Default target for clean 'make'
10 # Default target for clean 'make'
11 default: interactiveshell
11 default: interactiveshell
12
12
13 # The actual plugin installation
13 # The actual plugin installation
14 plugin: IPython_doctest_plugin.egg-info
14 plugin: IPython_doctest_plugin.egg-info
15
15
16 # Simple targets that test one thing
16 # Simple targets that test one thing
17 simple: plugin simple.py
17 simple: plugin simple.py
18 $(NOSE) simple.py
18 $(NOSE) simple.py
19
19
20 dtest: plugin dtexample.py
20 dtest: plugin dtexample.py
21 $(NOSE) dtexample.py
21 $(NOSE) dtexample.py
22
22
23 rtest: plugin test_refs.py
23 rtest: plugin test_refs.py
24 $(NOSE) test_refs.py
24 $(NOSE) test_refs.py
25
25
26 test: plugin dtexample.py
26 test: plugin dtexample.py
27 $(NOSE) dtexample.py test*.py test*.txt
27 $(NOSE) dtexample.py test*.py test*.txt
28
28
29 deb: plugin dtexample.py
29 deb: plugin dtexample.py
30 $(NOSE) test_combo.txt
30 $(NOSE) test_combo.txt
31
31
32 # IPython tests
32 # IPython tests
33 deco:
33 deco:
34 $(NOSE0) IPython.testing.decorators
34 $(NOSE0) IPython.testing.decorators
35
35
36 magic: plugin
36 magic: plugin
37 $(NOSE) IPython.core.magic
37 $(NOSE) IPython.core.magic
38
38
39 excolors: plugin
39 excolors: plugin
40 $(NOSE) IPython.core.excolors
40 $(NOSE) IPython.core.excolors
41
41
42 interactiveshell: plugin
42 interactiveshell: plugin
43 $(NOSE) IPython.core.interactiveshell
43 $(NOSE) IPython.core.interactiveshell
44
44
45 strd: plugin
45 strd: plugin
46 $(NOSE) IPython.core.strdispatch
46 $(NOSE) IPython.core.strdispatch
47
47
48 engine: plugin
48 engine: plugin
49 $(NOSE) IPython.kernel
49 $(NOSE) IPython.kernel
50
50
51 tf: plugin
51 tf: plugin
52 $(NOSE) IPython.config.traitlets
52 $(NOSE) IPython.config.traitlets
53
53
54 # All of ipython itself
54 # All of ipython itself
55 ipython: plugin
55 ipython: plugin
56 $(NOSE) IPython
56 $(NOSE) IPython
57
57
58
58
59 # Combined targets
59 # Combined targets
60 sr: rtest strd
60 sr: rtest strd
61
61
62 base: dtest rtest test strd deco
62 base: dtest rtest test strd deco
63
63
64 quick: base interactiveshell ipipe
64 quick: base interactiveshell ipipe
65
65
66 all: base ipython
66 all: base ipython
67
67
68 # Main plugin and cleanup
68 # Main plugin and cleanup
69 IPython_doctest_plugin.egg-info: $(SRC)
69 IPython_doctest_plugin.egg-info: $(SRC)
70 python setup.py install --prefix=$(PREFIX)
70 pip install . --prefix=$(PREFIX)
71 touch $@
71 touch $@
72
72
73 clean:
73 clean:
74 rm -rf IPython_doctest_plugin.egg-info *~ *pyc build/ dist/
74 rm -rf IPython_doctest_plugin.egg-info *~ *pyc build/ dist/
@@ -1,39 +1,34 b''
1 =======================================================
1 =======================================================
2 Nose plugin with IPython and extension module support
2 Nose plugin with IPython and extension module support
3 =======================================================
3 =======================================================
4
4
5 This directory provides the key functionality for test support that IPython
5 This directory provides the key functionality for test support that IPython
6 needs as a nose plugin, which can be installed for use in projects other than
6 needs as a nose plugin, which can be installed for use in projects other than
7 IPython.
7 IPython.
8
8
9 The presence of a Makefile here is mostly for development and debugging
9 The presence of a Makefile here is mostly for development and debugging
10 purposes as it only provides a few shorthand commands. You can manually
10 purposes as it only provides a few shorthand commands. You can manually
11 install the plugin by using standard Python procedures (``setup.py install``
11 install the plugin by using standard Python procedures (``setup.py install``
12 with appropriate arguments).
12 with appropriate arguments).
13
13
14 To install the plugin using the Makefile, edit its first line to reflect where
14 To install the plugin using the Makefile, edit its first line to reflect where
15 you'd like the installation. If you want it system-wide, you may want to edit
15 you'd like the installation.
16 the install line in the plugin target to use sudo and no prefix::
17
18 sudo python setup.py install
19
20 instead of the code using `--prefix` that's in there.
21
16
22 Once you've set the prefix, simply build/install the plugin with::
17 Once you've set the prefix, simply build/install the plugin with::
23
18
24 make
19 make
25
20
26 and run the tests with::
21 and run the tests with::
27
22
28 make test
23 make test
29
24
30 You should see output similar to::
25 You should see output similar to::
31
26
32 maqroll[plugin]> make test
27 maqroll[plugin]> make test
33 nosetests -s --with-ipdoctest --doctest-tests dtexample.py
28 nosetests -s --with-ipdoctest --doctest-tests dtexample.py
34 ..
29 ..
35 ----------------------------------------------------------------------
30 ----------------------------------------------------------------------
36 Ran 2 tests in 0.016s
31 Ran 2 tests in 0.016s
37
32
38 OK
33 OK
39
34
@@ -1,109 +1,109 b''
1 ===========================================================
1 ===========================================================
2 Self-contained IPython installation with all dependencies
2 Self-contained IPython installation with all dependencies
3 ===========================================================
3 ===========================================================
4
4
5 This is a self-contained source distribution of IPython with all its
5 This is a self-contained source distribution of IPython with all its
6 *non-graphical* dependencies, that installs in a single ``make`` call to your
6 *non-graphical* dependencies, that installs in a single ``make`` call to your
7 home directory (by default) or any location of your choice.
7 home directory (by default) or any location of your choice.
8
8
9 This distribution is meant for developer-type usage in Unix environments, it is
9 This distribution is meant for developer-type usage in Unix environments, it is
10 *not* an easy way to get IPython working on Windows, since it assumes the
10 *not* an easy way to get IPython working on Windows, since it assumes the
11 presence of a working compiler and development tools.
11 presence of a working compiler and development tools.
12
12
13 Currently, the distribution contains::
13 Currently, the distribution contains::
14
14
15 ipython-0.9.1.tar.gz
15 ipython-0.9.1.tar.gz
16 pyOpenSSL-0.6.tar.gz
16 pyOpenSSL-0.6.tar.gz
17 zope.interface-3.4.1.tar.gz
17 zope.interface-3.4.1.tar.gz
18 Twisted-8.1.0.tar.bz2
18 Twisted-8.1.0.tar.bz2
19 foolscap-0.3.1.tar.gz
19 foolscap-0.3.1.tar.gz
20 nose-0.10.3.tar.gz
20 nose-0.10.3.tar.gz
21
21
22
22
23 Usage
23 Usage
24 =====
24 =====
25
25
26 Download the single tarball where this README file lives and unpack it. If
26 Download the single tarball where this README file lives and unpack it. If
27 your system is already configured as described below, these lines will do the
27 your system is already configured as described below, these lines will do the
28 whole job::
28 whole job::
29
29
30 wget http://ipython.scipy.org/dist/alldeps/ipython-alldeps-0.9.1.tar
30 wget http://ipython.scipy.org/dist/alldeps/ipython-alldeps-0.9.1.tar
31 tar xf ipython-alldeps-0.9.1.tar
31 tar xf ipython-alldeps-0.9.1.tar
32 cd ipython-alldeps-0.9.1
32 cd ipython-alldeps-0.9.1
33 make
33 make
34
34
35 If all goes well, then just type::
35 If all goes well, then just type::
36
36
37 iptest
37 iptest
38
38
39 to run IPython's test suite.
39 to run IPython's test suite.
40
40
41
41
42 It is meant to be used in an environment where you have your ``$PATH``,
42 It is meant to be used in an environment where you have your ``$PATH``,
43 ``$PYTHONPATH``, etc variables properly configured, so that the installation of
43 ``$PYTHONPATH``, etc variables properly configured, so that the installation of
44 packages can be made with (using ``~/usr/local`` as an example)::
44 packages can be made with (using ``~/usr/local`` as an example)::
45
45
46 python setup.py install --prefix=~/usr/local
46 pip install . --prefix=~/usr/local
47
47
48 For an explanation of how to do this, see below.
48 For an explanation of how to do this, see below.
49
49
50 You can configure the default prefix used by editing the file
50 You can configure the default prefix used by editing the file
51 ``pkginstall.cfg``, where you can also override the python version used for the
51 ``pkginstall.cfg``, where you can also override the python version used for the
52 process. If your system is configured in this manner, you can simply type::
52 process. If your system is configured in this manner, you can simply type::
53
53
54 make
54 make
55
55
56 and this will build and install all of IPython's non-graphical dependencies on
56 and this will build and install all of IPython's non-graphical dependencies on
57 your system, assuming you have Python, a compiler, the Python headers and the
57 your system, assuming you have Python, a compiler, the Python headers and the
58 SSL headers available.
58 SSL headers available.
59
59
60
60
61 .. _environment_configuration:
61 .. _environment_configuration:
62
62
63 Environment configuration
63 Environment configuration
64 =========================
64 =========================
65
65
66 Below is an example of what to put in your ``~/.bashrc`` file to configure your
66 Below is an example of what to put in your ``~/.bashrc`` file to configure your
67 environment as described in this document, in a reasonably portable manner that
67 environment as described in this document, in a reasonably portable manner that
68 takes 64-bit operating systems into account::
68 takes 64-bit operating systems into account::
69
69
70 # For processor dependent config
70 # For processor dependent config
71 MACHINE=$(uname -m)
71 MACHINE=$(uname -m)
72
72
73 # Python version information
73 # Python version information
74 PYVER=$(python -ESV 2>&1)
74 PYVER=$(python -ESV 2>&1)
75 PYVER_MINOR=${PYVER#Python }
75 PYVER_MINOR=${PYVER#Python }
76 PYVER_MAJOR=${PYVER_MINOR:0:3}
76 PYVER_MAJOR=${PYVER_MINOR:0:3}
77
77
78 function export_paths {
78 function export_paths {
79 # Export useful paths based on a common prefix
79 # Export useful paths based on a common prefix
80
80
81 # Input: a path prefix
81 # Input: a path prefix
82
82
83 local prefix=$1
83 local prefix=$1
84 local pp
84 local pp
85 local lp
85 local lp
86 local pypath=python${PYVER_MAJOR}/site-packages
86 local pypath=python${PYVER_MAJOR}/site-packages
87
87
88 # Compute paths with 64-bit specifics
88 # Compute paths with 64-bit specifics
89 if [[ $MACHINE == "x86_64" ]]; then
89 if [[ $MACHINE == "x86_64" ]]; then
90 lp=$prefix/lib64:$prefix/lib
90 lp=$prefix/lib64:$prefix/lib
91 pp=$prefix/lib64/$pypath:$prefix/lib/$pypath
91 pp=$prefix/lib64/$pypath:$prefix/lib/$pypath
92 else
92 else
93 lp=$prefix/lib
93 lp=$prefix/lib
94 pp=$prefix/lib/$pypath
94 pp=$prefix/lib/$pypath
95 fi
95 fi
96
96
97 # Set paths based on given prefix
97 # Set paths based on given prefix
98 export PATH=$prefix/bin:$PATH
98 export PATH=$prefix/bin:$PATH
99 export CPATH=$prefix/include:$CPATH
99 export CPATH=$prefix/include:$CPATH
100 export LD_LIBRARY_PATH=$lp:$LD_LIBRARY_PATH
100 export LD_LIBRARY_PATH=$lp:$LD_LIBRARY_PATH
101 export LIBRARY_PATH=$lp:$LIBRARY_PATH
101 export LIBRARY_PATH=$lp:$LIBRARY_PATH
102 export PYTHONPATH=$pp:$PYTHONPATH
102 export PYTHONPATH=$pp:$PYTHONPATH
103 }
103 }
104
104
105 # Actually call the export function to set the paths. If you want more than
105 # Actually call the export function to set the paths. If you want more than
106 # one such prefix, note that the call *prepends* the new prefix to the
106 # one such prefix, note that the call *prepends* the new prefix to the
107 # existing paths, so later calls take priority.
107 # existing paths, so later calls take priority.
108
108
109 export_paths $HOME/usr/local
109 export_paths $HOME/usr/local
General Comments 0
You need to be logged in to leave comments. Login now