Archive for WinDev

Course revamp startup — Windows 2003, IIS, ASP

This year I am revamping both Web development and robotics courses to use Microsoft technologies: ASP.Net 3.5, IronPython/Dynamic Language Runtime, Robotics Studio.

 As a first step I am trying to port over the course website, or at least some sample code, to IIS. Apache has its headaches with long config files, but the IIS setup is even more confusing, since not everything is accessible in one file.

  1.  The first stumbling block was I couldnt get a simple Default.aspx file recognized by IIS to serve when I went to http://localhost.
    • Solution: register ASP.Net 2.0 (3.5) with IIS
    • In the c:\Windows\Microsoft.NET\framework\v2.0.50727 directory run the command aspnet_regiis -i
  2. Note that ASP.Net 3.5 is really ASP.Net 2.0 with some extensions.

  3. Second step was to add SSL (Secure Socket Layer) support, ie allow https:// access. This was surprisingly easy from the IIS perspective! The only hard part was to generate the Certificate Authority and Server certificates.
    • solution: Look at this page
    • Be sure to open up the firewall with port 443!
    • Install the server certificate in the IIS manager
    • To remove the annoying warnings on the client browser, install the certificate authority certificate on the client machine.
  4. NFS mounting. The students will be given accounts on the unix (really linux) systems with their own directories. We want to allow students to log onto the Windows 2003 server (cygwin sshd) using their unix username/password (ActiveDirectory/LDAP, to be discussed below) and mount their NFS directories. This will aid in “uploading” web site code to the server.
    • This site has very good information on setting up Windows Services for Unix (SFU) for Windows Server 2003

Comments off

Compiling Python 2.5.1 from scratch using MS Visual Studio 2005

I usually use prepackaged binaries to install Python on Windows machines. Lately I have been trying to get back into using Intel’s open source vision library, OpenCV. To do that it appears I need to compile extension modules to be able to use Python, which in turn requires that I have the source and be able to build from it.

The build process has been relatively smooth, the MSVS 2005 solution file is located in the PCBuild8 directory. The biggest hiccup has been to get the sqlite3 extension module compiled, the instructions say I need to download the source distribution for sqlite3 from the svn.python.org SVN repository, but it has not been available today so far. Building sqlite3 from sources available at the sqlite site is a hassle, as it appears to require Mingw. I can of course do this, but I don’t have the time I used to.

A shortcut is to download the binary/DLL files from the sqlite website. This zip file contains both sqlite3.dll and the DEF file. However, the python solution requires a sqlite3.lib file, which is usually generated when one compiles and links the source files.

A little bit of googling led me to the def2lib.exe tool which converts DEF files to LIB files. The tool is located here.

Comments off