Running from Source (Windows)

So you want to run from source, do you?

Foolish mortal. Read on.

This page describes how to set up and run fpdb from source on 64-bit Windows.
The instructions were compiled on 64-bit Windows 10 pro using python 2.7.13

Requirements

  • A 64-bit version of Windows.
    • This should include W7, 8 or 10. Sorry, XP-64 won't cut it.
    • To check your system use one of the following methods
      • At a command line type:
        • systeminfo | findstr "OS Type"
        • You should now see "x64 based PC" in the output.
      • Press Windows-Break on the keyboard
        • You should see "64-bit Operating System" in the screenful of info that results
  • A 64-bit version of python 2
    • It is critical to have a clean installation of the 64-bit python. Do NOT install the 64-bit version over top the 32-bit one. Doing so will ensure that architecture-dependent packages fail miserably
    • If you have the 32-bit version installed do one of the following
      • Install the 64-bit version into its own directory
      • Completely uninstall the 32-bit version before installing the 64-bit version into the original directory
        • If you choose to uninstall, use Add/Remove programs to uninstall any packages first before uninstalling python.
    • Once you have the 64-bit version installed, check your system path. There should be two items there:
      • c:\python27_64;c:\python27_64\Scripts
      • Your directory name may differ, but it must be the directory that contains the 64-bit version
      • If the wrong folders are there, you can follow these instructions to set them right.

Python for Windows can be downloaded from:
https://www.python.org/downloads/windows/

Packages to install

Order is unlikely important — however this order tested successfully.
Where more than one package exists, choose to download the one that matches your Python version (2.7) and system architecture (64-bit)
Package Location Comment
MySQLdb http://www.codegood.com/archives/129 Only needed if you're going to use MySQL as your database
pywin https://sourceforge.net/projects/pywin32/files/pywin32/Build%20221/ may include winpaths
winpaths https://pypi.python.org/pypi/winpaths/ before downloading try to import winpaths. If it works, you can skip this step
numpy https://pypi.python.org/pypi/numpy As before, be certain to match Python version and architecture
pytz https://pypi.python.org/pypi/pytz#downloads architecture independent
matplotlib https://pypi.python.org/pypi/matplotlib/ Incorporates PyLab
PyQt5 https://github.com/pyqt/python-qt5 Download and unzip this package, then install using the third method below. There are detailed instructions here https://github.com/pyqt/python-qt5/wiki/Installation
sqlite3 https://pypi.python.org/pypi/pysqlite I did not install this at all, yet database access seems to work just fine. If needed, it is platform-independent, but requires python 2

Installation instructions

Installation methods for various package types
Type Instructions
.exe Just run 'em. Check that they're being installed into the 64-bit directory
.whl Open an elevated command prompt on the directory holding the .whl file. The command is: pip install <fullname.whl>
other Open an elevated command prompt on the directory holding the file 'setup.py' — if there isn't one, you're in the wrong directory. Enter the command: python setup.py install

running from fpdb source

Download the source from https://github.com/chazdazzle/fpdb-chaz
Extract it to a folder, then open a command prompt at the folder.
Type

c:\test>python run_fpdb.py

fpdb should run, creating the folder in %appdata%\fpdb — and further creating a database and log folder under it.

troubleshooting

Open a command prompt and type

c:\test>Python

You should see:
Python 2.7.13 (v2.7.13:a06454b1afa1, Dec 17 2016, 20:53:40) [MSC v.1500 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>>

try all of the following:

>>> import MySQLdb
>>> import pywin
>>> import winpaths
>>> import numpy
>>> import pytz
>>> import  matplotlib
>>> import PyQt5
>>> import sqlite3

If any other than MySQLdb fail, then you'll need to ensure that you have the correct package installed.

License

Trademarks of third parties have been used under Fair Use or similar laws.

Copyright 2008 Steffen Jobbagy-Felso
Permission is granted to copy, distribute and/or modify this
document under the terms of the GNU Free Documentation License,
Version 1.2 as published by the Free Software Foundation; with
no Invariant Sections, no Front-Cover Texts, and with no Back-Cover
Texts. A copy of the license can be found in fdl-1.2.txt

The program itself is licensed under AGPLv3, see agpl-3.0.txt

web analytics

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License