Linkshare rotating banner
Showing posts with label windows. Show all posts
Showing posts with label windows. Show all posts

Monday, October 1, 2012

Bittorrent Info Hash Values for Windows 8 ISO

Windows 8 ISO files have the following BTIH hash values. Use them with my aria2 script to download Windows 8.




  1. en_windows_8_x86_dvd_915417.iso

    C5D92B32277685436DEDE9957B80083D26062C03
  2. en_windows_8_x64_dvd_915440.iso

    144C7E2B46103FF84F83A1E6A12D66B740F00CF6

Sunday, September 30, 2012

To Compile ndiswrapper 1.58rc1 for Linux 3.5.4

ndiswrapper allows Linux users to use Windows drivers for PCI/USB network adapters on Linux. If you own a network device for which Linux support is still absent or premature, then you need to compile ndiswrapper yourself and install Windows driver for your network device. Fortunately, today's Linux supports most network devices out-of-box, so most distributions don't bother to include ndiswrapper. However, I am compiling ndiswrapper believing that Windows NDIS drivers would outperform native Linux drivers.





To my surprise, building the latest version of ndiswrapper (1.58rc1) did not require any patch. After compiling Linux 3.5.4, I downloaded the ndiswrapper source from the sourceforge site. I chose the testing version because I thought it would work better with Linux 3.5.x. I unpacked the source.



tar xzvf ndiswrapper-1.58rc1.tar.gz
cd ndiswrapper-1.58rc1


I typed the following commands to compile and install ndiswrapper.



KVERS=3.5.4 make uninstall
KVERS=3.5.4 make
KVERS=3.5.4 make install


Then, I generated modules.* files again.



depmod -e -m -F /boot/System.map-3.5.4 3.5.4


The following files were installed by ndiswrapper.



/lib/modules/3.5.4/misc/ndiswrapper.ko
/sbin/loadndisdriver
/usr/sbin/ndiswrapper
/usr/sbin/ndiswrapper-buginfo
/usr/share/man/man8/loadndisdriver.8
/usr/share/man/man8/ndiswrapper.8


Also read:



Wednesday, September 19, 2012

Setting up MinGW64 with Cygwin

This is just another version of my previous post on Cygwin with focus on MinGW64. I hope this guide will more or less make it easy to install MinGW on Windows. After following this guide, you'll be ready to develop genuine Windows applications. Just download and run setup.exe from the Cygwin website and choose the following packages.




  • bison
  • gettext-devel
  • libtool
  • make
  • mingw64-i686-gcc-g++
  • mingw64-x86_64-gcc-g++
  • patch
  • pkg-config


To select a package for installation, type the name of the package in the Search box, expand the category by clicking the + sign, and click on the package until its version number shows up.



cygwin_setup_mingw64

When you see the Resolving Dependencies window, just accept and click Next.



cygwin_setup_dependencies

Mounting /mingw



If you're building 32-bit applications, add the following line to /etc/fstab so that /mingw is properly set up.


/usr/i686-w64-mingw32/sys-root/mingw /mingw none bind


If you're building 64-bit applications, add the following line to /etc/fstab instead.


/usr/x86_64-w64-mingw32/sys-root/mingw /mingw none bind


Creating Symbolic Links



Start the Cygwin terminal and create symbolic links to gcc and g++ in this manner.



ln -s /usr/bin/i686-w64-mingw32-gcc.exe /usr/i686-w64-mingw32/bin/gcc.exe
ln -s /usr/bin/i686-w64-mingw32-g++.exe /usr/i686-w64-mingw32/bin/g++.exe
ln -s /usr/bin/x86_64-w64-mingw32-gcc.exe /usr/x86_64-w64-mingw32/bin/gcc.exe
ln -s /usr/bin/x86_64-w64-mingw32-g++.exe /usr/x86_64-w64-mingw32/bin/g++.exe


Setting up environment variables



If you're building 32-bit applications, type the following commands or put them in ~/.profile:



export CC=/usr/bin/i686-w64-mingw32-gcc.exe
export CFLAGS="-mtune=pentium2 -mthreads -mms-bitfields -O2"
export CXXFLAGS="-mtune=pentium2 -mthreads -mms-bitfields -O2"
export CPPFLAGS="-I/mingw/include"
export LDFLAGS="-L/mingw/lib -Wl,--enable-auto-image-base -Wl,--enable-auto-import -Wl,--enable-runtime-pseudo-reloc"
export PATH=/mingw/bin:/usr/i686-w64-mingw32/bin:/usr/local/bin:/usr/bin
export PKG_CONFIG_PATH=/mingw/lib/pkgconfig


If you're building 64-bit applications, type the following or put in ~/.profile:



export CC=/usr/bin/x86_64-w64-mingw32-gcc.exe
export CFLAGS="-mtune=core2 -mthreads -mms-bitfields -O2"
export CXXFLAGS="-mtune=core2 -mthreads -mms-bitfields -O2"
export CPPFLAGS="-I/mingw/include"
export LDFLAGS="-L/mingw/lib -Wl,--enable-auto-image-base -Wl,--enable-auto-import -Wl,--enable-runtime-pseudo-reloc"
export PATH=/mingw/bin:/usr/x86_64-w64-mingw32/bin:/usr/local/bin:/usr/bin
export PKG_CONFIG_PATH=/mingw/lib/pkgconfig


For more information on possible -mtune values, look here.



Saturday, September 8, 2012

Building MPlayer and Mencoder for Windows

MPlayer logo

MPlayer is one of my favorite media players. It is used with a frontend like smplayer, gnome-mplayer and MPlayerGUI to provide a good alternative to Windows Media Player. Although there are already several Win32 builds of MPlayer on the net, I like to build MPlayer on my own using MinGW compiler because I want to optimize my build for my CPU. So I installed MinGW and compiled MPlayer as follows.





  1. Build ffmpeg statically or dynamically as shown in this post.



  2. (Optional) Compile the lzo library:

    ./configure --prefix=/mingw && make && make install


  3. (Optional) Fribidi is a rendering library for right-to-left scripts, such as Arabic and Hebrew. If you are a speaker of such right-to-left languages, compile fribidi statically as shown below:


    ./configure --prefix=/mingw --disable-shared --disable-debug
    make
    make install

    More information can be found here.



  4. Download JPEG source from ijg.org and complie JPEG:

    ./configure --prefix=/mingw --enable-static
    make
    make install


  5. Compile libPNG:

    ./configure --prefix=/mingw --disable-shared
    make
    make install


  6. Compile libiconv, Freetype, expat and fontconfig statically in that order:

    ./configure --prefix=/mingw --disable-shared
    make install


  7. Compile libdca:

    ./configure --prefix=/mingw
    make
    make install


  8. (Optional) Download DirectX headers from any of the following locations and unpack them in /mingw/include:



  9. Download the latest mplayer source (mplayer-export-snapshot.tar.bz2) and unpack it. (patch 1 and patch 2)

    tar xjvf mplayer-export-snapshot.tar.bz2
    cd mplayer-export-2010-02-07/

    Then, run ./configure:


    CPPFLAGS='-DFRIBIDI_ENTRY="" ' ./configure --prefix=/mingw --enable-runtime-cpudetection --enable-static --enable-theora --enable-fribidi --disable-ffmpeg_a --disable-gl --disable-vidix --yasm=/mingw/bin/yasm --extra-libs='-lfribidi'

    The CPPFLAGS value allows fribidi to be linked statically.



  10. Build Mplayer:

    make


    After successful build, strip the executables:


    strip m*.exe


    Optionally, compress the executables with upx:


    upx --best --strip-relocs=0 mplayer.exe
    upx --best --strip-relocs=0 mencoder.exe


  11. Download MPlayer codecs from here. The MPlayer codecs for Windows platform has a filename like windows-essential-20071007.zip. Extract the codecs package and you'll get a folder "windows-essential-20071007". Rename it as "codecs" and move the "codecs" folder inside where mplayer.exe file is located.



  12. Make sure that HOME environment variable is set to your personal folder(for example, C:\Users\Jocelyn). Upon the first run of mplayer, a new folder named mplayer will be created in your HOME folder. Copy codecs.conf to the mplayer folder. The "config" file stores default options for playing movie files. Open the "config" file and make changes as follows:


    # Write your default config options here!
    cdrom-device=D:
    dvd-device=D:
    ao=dsound
    vo=direct3d
    font=C:\WINDOWS\FONTS\MALGUN.TTF
    framedrop=yes
    subcp=cp949



My win32 build of mplayer can be downloaded from here. It is recommended that the zip archive should be extracted in C:\Program Files.



Running MPlayer


Now, let's try mplayer. First, get a movie file ready. In the Command Prompt, type a command in the following form:



mplayer mymoviefile.avi


Alternatively,



mplayer -vo direct3d -ao win32 -font C:\WINDOWS\FONTS\Tahoma.ttf -framedrop mymoviefile.avi


A new window will pop up with the movie playing inside it.



The next step is to get and set up SMPlayer.

Thursday, September 6, 2012

Building cdrtools under Cygwin


cdrtools is a powerful open-source CD/DVD/BD burning tool. It is used as backend software for free DVD-burning applications, such as Infrarecorder and cdrtfe. To build cdrtools for Windows, install Cygwin as shown in this post. Additionally, I installed the following Cygwin packages.




  • bison
  • gcc4-core
  • gcc4-g++
  • gettext-devel
  • libiconv
  • libtool
  • make
  • patch
  • pkg-config


I set up some environment variables before I started.


export CC=/usr/bin/gcc.exe
export CC_OPT="-O2"
export CFLAGS="-march=pentium2 -mtune=i586 -mthreads -mms-bitfields"
export LDFLAGS="-L/usr/lib -Wl,--enable-auto-image-base -Wl,--enable-auto-import -Wl,--enable-runtime-pseudo-reloc"


Then, I built smake.


cd smake-1.2
make
make INS_BASE=/usr install


Then, I built cdrtools.


smake
smake INS_BASE=/usr install


Using cdrtools


I tested my cdrtools build. To create an ISO file from a folder, I ran mkisofs:


mkisofs -J -R -hide-rr-moved ~/Downloads > dl.iso

To burn an ISO:


cdrecord -scanbus
cdrecord dev=0,0,0 speed=8 driveropts=burnfree dl.iso

To make a copy of a data CD:


readcd dev=0,0,0 f=dl2.iso speed=8 retries=16 -nocorr -noerror

To scan a music CD, I ran cdda2wav:


cdda2wav -scanbus
cdda2wav dev=0,0,0 cddb=1 -cddbp-server=freedb.freedb.org -cddbp-port=8880 -J -N

To rip the second track of the music CD:


cdda2wav dev=0,0,0 cddb=1 track=2 ~/Music/track2.wav



Download my cdrtools build for Windows


Here you can get my cdrtools build.




Free cdrtools Graphical Interfaces for Windows


If you don't want to deal with the command line, there are, of course, user-friendly GUI frontends for cdrtools.




Related Links



Tuesday, September 4, 2012

Using cdrtfe 1.5

cdrtfe is free CD/DVD/BD burning software for Windows. cdrtfe actually use the command-line program cdrtools as its burning engine. I have used cdrtools on Linux to create ISO images and burn or rip CD. I'd like to have cdrtools on Windows also. Fortunately, cdrtfe includes cdrtools Win32 binaries along with the nice-looking GUI application.



To install cdrtfe, I downloaded the cdrtfe zip archive (cdrtfe-1.5.zip) and unpacked the zip archive. Double-clicking on the cdrtfe file will start the cdrtfe program. (Warning: Running the Cygwin terminal and cdrtfe at the same time can cause a problem due to cygwin1.dll incompatibility, so close the Cygwin terminal before starting cdrtfe.)



So far, I have only tried ripping music CD's with cdrtfe. I will add more as I get to know more about cdrtfe.



Ripping Audio CD's


To rip a music CD, click on the DAE tab and click the Options button. Check to make sure the options are okay.


cdrtfe_dae_options_1
cdrtfe_dae_options_2

Back to the main window, click Read TOC to update the track list, check the Save tracks to folder, and click Start to begin ripping.


cdrtfe_dae

Sunday, September 2, 2012

Setting Up Cygwin For C/C++ Software Development on Windows

Cygwin provides a Unix-like environment for Windows users. Cygwin is useful for people who want to learn Unix or popular Linux without having to install Unix or Linux. Cygwin can also be used to port Linux applications to Windows or develop genuine Windows applications. To install Cygwin, download setup.exe from the Cygwin website and run it.



Cygwin Packages for Software Development


In addition to the default packages, select the following packages for common development environment:


  • bison
  • gettext-devel
  • libtool
  • make
  • patch
  • pkg-config


To select a package for installation, type the name of the package in the Search box, expand the categories by clicking a plus, and clicking on the package until its version number shows up.



cygwin_setup_mingw64

If you want to develop software applications that depend on cygwin1.dll (which emulates Unix on Windows), install one of the following packages. This is when you want to port Linux applications to Windows with little modification.


  • gcc-g++

    outdated version 3.4.4
  • gcc4-g++

    GCC 4.x that links applications with cygwin1.dll


If you want to develop pure Windows applications, install one of the following packages.


  • mingw-gcc-g++

    The original MinGW compiler from mingw.org can't build 64-bit applications.
  • mingw64-i686-gcc-g++

    New MinGW compiler from mingw-w64.sourceforge.net.
  • mingw64-x86_64-gcc-g++

    Install these to develop 64-bit Windows applications.


When you see the Resolving Dependencies window, just accept and click Next.


cygwin_setup_dependencies

Setting HOME Variable


Setting the environment variable %HOME% is useful for various reasons. First of all, it allows regular users to compile freely in their user folder without requiring access to C:\Cygwin. Secondly, it allows users to save user-specific configuration in their user folder. For example, user configuration files such as .profile, .gtkrc-2.0, .fonts.conf and .pango-aliases can be saved in the folder specified by %HOME%.


Set HOME environment variable for MinGW and Cygwin

Setting Up mingw* compiler for Cygwin


The file C:\Cygwin\etc\fstab is used to set up mount points in Cygwin. If you installed mingw64 packages, open the file C:\Cygwin\etc\fstab in a text editor and append the following line.


/usr/i686-w64-mingw32/sys-root/mingw /mingw none bind

Start the Cygwin terminal and type the following commands to set up Cygwin for Windows compilation.


ln -s /usr/bin/i686-w64-mingw32-g++.exe /usr/i686-w64-mingw32/bin/g++.exe
ln -s /usr/bin/i686-w64-mingw32-gcc.exe /usr/i686-w64-mingw32/bin/gcc.exe

Also, set up some environment variables.


export CFLAGS="-march=pentium2 -mtune=i586 -mthreads -mms-bitfields -O2"
export CXXFLAGS="-march=pentium2 -mtune=i586 -mthreads -mms-bitfields -O2"
export CPPFLAGS="-I/mingw/include"
export LDFLAGS="-L/mingw/lib -Wl,--enable-auto-image-base -Wl,--enable-auto-import -Wl,--enable-runtime-pseudo-reloc"
export PATH=/mingw/bin:/usr/i686-w64-mingw32/bin:/usr/local/bin:/usr/bin
export PKG_CONFIG_PATH=/mingw/lib/pkgconfig


Setting Up gcc* Compiler for Cygwin


If you installed the gcc4 compiler (as opposed to mingw*), set up some environment variables to customize your build environment. I usually type the following commands:


CC="/usr/bin/gcc.exe"
CFLAGS="-march=pentium2 -mtune=i586 -mthreads -mms-bitfields -O2"
CPPFLAGS="-I/usr/include"
CXXFLAGS="-march=pentium2 -mtune=i586 -mthreads -mms-bitfields -O2"
LDFLAGS="-L/usr/lib -Wl,--enable-auto-image-base -Wl,--enable-auto-import -Wl,--enable-runtime-pseudo-reloc"
export CC CFLAGS CPPFLAGS CXXFLAGS LDFLAGS

Wednesday, March 23, 2011

Hacker's Guide To Installing Windows 7

Many people want to try the new Windows 7, but they're not too sure if Windows 7 is worth it. After all, it doesn't make sense to buy a new computer to try Windows 7 and then find out it's another lame bloatware. This guide will help an average joe to download, install and activate Windows 7 with freely available tools.



Hardware Requirements of Windows 7


First, you need to decide if your computer is capable of running Windows 7. According to Microsoft, Windows 7 has the following hardware requirements:



  • 1 GHz or faster 32-bit or 64-bit processor
  • 1 GB RAM (32-bit) or 2 GB RAM (64-bit)
  • 16 GB available hard disk space (32-bit) or 20 GB (64-bit)
  • DVD-ROM drive or DVD burner
  • DirectX 9 graphics card with WDDM 1.0 or better driver


That means Windows 7 can run on most computers available. You may have to buy additional memory or a new video card to be able to run Windows 7. See the Windows 7 Compatibility site.



Next, decide which edition of Windows 7 you want to install on your computer. There are many editions of Windows 7, for example, Home Premium, Professional, Enterprise and Ultimate. For most people, Windows 7 Home Premium is good enough.



Windows 7 Direct Downloads and Bittorrents



It is recommended that you use aria2, Halogenware Retriever or Free Download Manager to download Windows 7 so you can resume a download in the event of connection problems. On the Web, you can download DVD images of Windows 7 from the following locations:



  • Windows 7 Home Premium SP1 (x86 English) X17-24208.iso

    MD5: c5bb99b2f1a9e7a5b4fbc6e3eff70882

    SHA1: 22df3e5a80f8dbf014c2776a01b1cd9f24d83233

    CRC32: 9c5dc931
  • Windows 7 Home Premium SP1 (x64 English) X17-24209.iso

    MD5: 971843a457b6e0db0af61258cbe7256a

    SHA1: b4821f46a171708f5f8f8a0ef48fc16529437961

    CRC32: d236fd70
  • Windows 7 Professional SP1 (x86 English) X17-24280.iso

    MD5: befd4f1e00ec8da2effbd789f4e66fbf

    SHA1: 917a542b0541054bb9c2a06a11a46aed6943856b

    CRC32: 20078d8d
  • Windows 7 Professional SP1 (x64 English) X17-24281.iso

    MD5: 338f3245d68527db47b8a44e55317d0a

    SHA1: 5ed2584110e03f498db4458ba9fafd5a7ef602ed

    CRC32: 74f3cb73
  • Windows 7 Ultimate SP1 (x86 English) X17-24394.iso

    CRC32: C2966895

    MD5: 24F3A45D43D7C532AA3126CC094C61BD

    SHA1 : 92c1ada4ff09c76ec2f1974940624cab7f822f62

    SHA2: BBB5E0BAF3659F6DEC96B50381CBB05C09F066675EE639324B728215D5D47C43
  • Windows 7 Ultimate SP1 (x64 English) X17-24395.iso

    CRC32: 8589EE18

    MD5: 56A26636EC667799F5A7F42F142C772D

    SHA1: 1693b6cb50b90d96fc3c04e4329604feba88cd51

    SHA2: 9A2F3972FBBBB4974255CCCC26CDA9B1A75D9D0179867D6111162AC33F0CB693
  • Windows 7 Home Premium (x86 English) X15-65732.iso

    SHA1: CC9D8220B2179E784D85BF1EA98D2EE2190D534F

    ISO/CRC: 5DF6DBA0
  • Windows 7 Home Premium (x64 English) X15-65733.iso

    SHA1: 336779EA6B65F63E11A609B4D021439C47AB315B

    ISO/CRC: 56D954E4
  • Windows 7 Professional (x86 English) X15-65804.iso

    SHA1: 697FA06554502FB21D30275273B25747299C020D

    ISO/CRC: 578725D1
  • Windows 7 Professional (x64 English) X15-65805.iso

    SHA1: 50127304441A793EE51B3F501289F6599A559E9F

    ISO/CRC: 502C42C1
  • Windows-7-SP1-EN-MSDN-TechNet.torrent


I like using aria2 for download. Get my aria2 win32 build from here. To use aria2c to download Windows 7 Home Premium, open the Command Prompt and type the following command.



aria2c --file-allocation=prealloc http://msft-dnl.digitalrivercontent.net/msvista/pub/X15-65732/X15-65732.iso


To stop the download, press Ctrl+C twice. Later, you can resume download with the command:



aria2c -c http://msft-dnl.digitalrivercontent.net/msvista/pub/X15-65732/X15-65732.iso


After the download has finished, verify the checksums of the download with md5deep or HashCheck shell extension.

This is optional. If you want to create a single All-in-One DVD that can be used to install Home Basic, Home Premium, Professional and Ultimate edition, download and run eicfg_remover. This tool removes ei.cfg from the ISO file.

Then, burn the image to a blank DVD. You need to have a DVD burner and a blank DVD, of course. For free DVD-burning software, you can get ImgBurn, InfraRecorder or CDBurnerXP.



Saturday, July 10, 2010

List of Useful Software for Windows



I just finished setting up my laptop. It's got Windows 7 Home Premium installed. The following is a list of software I installed onto my laptop:





Related Posts


Wednesday, June 30, 2010

Install Windows XP on a USB flash/hard drive

I am building a new PC from old spare parts. The new PC will be used mainly for the Internet, so a hard drive won't be necessary unless there's a need to download music and movies. I'm going to put together a computer with no internal storage, but use a USB stick as the main storage. Windows XP Professional will be installed on the USB stick, and the computer will boot up from the USB stick. Here I show how to install XP onto a USB stick and boot the PC from it. You should have the following ready.





Let's begin.




  1. Get your Windows XP installation CD and copy its contents to an empty folder on the hard drive. If you don't have the CD, use utorrent or emule to download the ISO file.



    Then, use 7-zip to extract the contents of the ISO file into an empty folder.



  2. Start the Command Prompt, go to the I386 subfolder and type the following commands to uncompress the USB driver files:


    CD I386
    EXPAND -I USB.IN_
    EXPAND -I USBPORT.IN_
    EXPAND -I USBSTOR.IN_

    We'll get 3 new files: USB.INF, USBPORT.INF and USBSTOR.INF. Remove the original .IN_ files.


    ERASE USB.IN_ USBPORT.IN_ USBSTOR.IN_


  3. Edit TXTSETUP.SIF to include USB storage support at the initial stage of Windows XP installation. The highlighted entries were copied from the [InputDevicesSupport.Load] section to the [BootBusExtenders.Load] section:

    [BootBusExtenders.Load]
    pci = pci.sys
    acpi = acpi.sys
    isapnp = isapnp.sys
    acpiec = acpiec.sys
    ohci1394 = ohci1394.sys
    usbehci = usbehci.sys
    usbohci = usbohci.sys
    usbuhci = usbuhci.sys
    usbhub = usbhub.sys
    usbstor = usbstor.sys


    Likewise for [BootBusExtenders] and [InputDevicesSupport]:



    [BootBusExtenders]
    pci = "PCI Bus Driver",files.pci,pci
    acpi = "ACPI Plug & Play Bus Driver",files.acpi,acpi
    isapnp = "ISA Plug & Play Bus Driver",files.isapnp,isapnp
    acpiec = "ACPI Embedded Controller Driver",files.none,acpiec
    ohci1394 = "IEEE 1394 Bus OHCI Compliant Port Driver",files.ohci1394,ohci1394
    usbehci = "Enhanced Host Controller",files.usbehci,usbehci
    usbohci = "Open Host Controller",files.usbohci,usbohci
    usbuhci = "Universal Host Controller",files.usbuhci,usbuhci
    usbhub = "Generic USB Hub Driver",files.usbhub,usbhub
    usbstor = "USB Storage Class Driver",files.usbstor,usbstor


    Insert the following in the [HiveInfs.Fresh] section:


    [HiveInfs.Fresh]
    AddReg = hivedef.inf,AddReg
    AddReg = hivesys.inf,AddReg
    AddReg = hivesft.inf,AddReg
    AddReg = hivecls.inf,AddReg
    AddReg = hiveusd.inf,AddReg
    AddReg = dmreg.inf,DM.AddReg
    AddReg = usbboot.inf,usbservices


    Then, in the [SourceDisksFiles] section:



    [SourceDisksFiles]
    usbboot.inf = 1,,,,,,_x,3,,3
    bootvid.dll = 1,,,,,,3_,2,0,0,,1,2
    kdcom.dll = 1,,,,,,3_,2,0,0,,1,2


    Save and close TXTSETUP.SIF.



  4. Edit DOSNET.INF so that the second [Files] section looks like this:

    [Files]
    d1,usbboot.inf
    d1,_default.pif
    d1,12520437.cpx
    d1,12520850.cpx


  5. Edit USB.INF as follows:


    [StandardHub.AddService]
    DisplayName = %StandardHub.SvcDesc%
    ServiceType = 1 ; SERVICE_KERNEL_DRIVER
    StartType = 0 ; SERVICE_DEMAND_START
    ErrorControl = 1 ; SERVICE_ERROR_NORMAL
    ServiceBinary = %12%\usbhub.sys
    LoadOrderGroup = Boot Bus Extender

    [CommonClassParent.AddService]
    DisplayName = %GenericParent.SvcDesc%
    ServiceType = 1 ; SERVICE_KERNEL_DRIVER
    StartType = 0 ; SERVICE_DEMAND_START
    ErrorControl = 1 ; SERVICE_ERROR_NORMAL
    ServiceBinary = %12%\usbccgp.sys
    LoadOrderGroup = Boot Bus Extender



  6. Modify USBPORT.INF like this.


    [EHCI.AddService]
    DisplayName = %EHCIMP.SvcDesc%
    ServiceType = 1 ; SERVICE_KERNEL_DRIVER
    StartType = 0 ; SERVICE_DEMAND_START
    ErrorControl = 1 ; SERVICE_ERROR_NORMAL
    ServiceBinary = %12%\usbehci.sys
    LoadOrderGroup = Boot Bus Extender


    [OHCI.AddService]
    DisplayName = %OHCIMP.SvcDesc%
    ServiceType = 1 ; SERVICE_KERNEL_DRIVER
    StartType = 0 ; SERVICE_DEMAND_START
    ErrorControl = 1 ; SERVICE_ERROR_NORMAL
    ServiceBinary = %12%\usbohci.sys
    LoadOrderGroup = Boot Bus Extender


    [UHCI.AddService]
    DisplayName = %UHCIMP.SvcDesc%
    ServiceType = 1 ; SERVICE_KERNEL_DRIVER
    StartType = 0 ; SERVICE_DEMAND_START
    ErrorControl = 1 ; SERVICE_ERROR_NORMAL
    ServiceBinary = %12%\usbuhci.sys
    LoadOrderGroup = Boot Bus Extender


    [ROOTHUB.AddService]
    DisplayName = %ROOTHUB.SvcDesc%
    ServiceType = 1 ; SERVICE_KERNEL_DRIVER
    StartType = 0 ; SERVICE_DEMAND_START
    ErrorControl = 1 ; SERVICE_ERROR_NORMAL
    ServiceBinary = %12%\usbhub.sys
    LoadOrderGroup = Boot Bus Extender


  7. Edit USBSTOR.INF:


    [USBSTOR.AddService]
    DisplayName = %USBSTOR.SvcDesc%
    ServiceType = 1
    StartType = 0
    Tag = 3

    ErrorControl = 1
    ServiceBinary = %12%\USBSTOR.SYS
    LoadOrderGroup = Boot Bus Extender


  8. Create a new file USBBOOT.INF with the following contents:


    [usbservices]

    HKLM,"SYSTEM\CurrentControlSet\Services\USBSTOR","DisplayName",0x00000000,"USB Mass Storage Driver"
    HKLM,"SYSTEM\CurrentControlSet\Services\USBSTOR","ErrorControl",0x00010001,1
    HKLM,"SYSTEM\CurrentControlSet\Services\USBSTOR","Group",0x00000000,"System Reserved"
    HKLM,"SYSTEM\CurrentControlSet\Services\USBSTOR","ImagePath",0x00020000,"system32\DRIVERS\USBSTOR.SYS"
    HKLM,"SYSTEM\CurrentControlSet\Services\USBSTOR","Start",0x00010001,0
    HKLM,"SYSTEM\CurrentControlSet\Services\USBSTOR","Type",0x00010001,1

    HKLM,"SYSTEM\CurrentControlSet\Services\usbehci","DisplayName",0x00000000,"USB 2.0 Enhanced Host Controller Miniport Driver"
    HKLM,"SYSTEM\CurrentControlSet\Services\usbehci","ErrorControl",0x00010001,1
    HKLM,"SYSTEM\CurrentControlSet\Services\usbehci","Group",0x00000000,"System Reserved"
    HKLM,"SYSTEM\CurrentControlSet\Services\usbehci","ImagePath",0x00020000,"system32\DRIVERS\usbehci.sys"
    HKLM,"SYSTEM\CurrentControlSet\Services\usbehci","Start",0x00010001,0
    HKLM,"SYSTEM\CurrentControlSet\Services\usbehci","Type",0x00010001,1

    HKLM,"SYSTEM\CurrentControlSet\Services\usbhub","DisplayName",0x00000000,"USB2 Enabled Hub"
    HKLM,"SYSTEM\CurrentControlSet\Services\usbhub","ErrorControl",0x00010001,1
    HKLM,"SYSTEM\CurrentControlSet\Services\usbhub","Group",0x00000000,"System Reserved"
    HKLM,"SYSTEM\CurrentControlSet\Services\usbhub","ImagePath",0x00020000,"system32\DRIVERS\usbhub.sys"
    HKLM,"SYSTEM\CurrentControlSet\Services\usbhub","Start",0x00010001,0
    HKLM,"SYSTEM\CurrentControlSet\Services\usbhub","Type",0x00010001,1

    HKLM,"SYSTEM\CurrentControlSet\Services\usbuhci","DisplayName",0x00000000,"Microsoft USB Universal Host Controller Miniport Driver"
    HKLM,"SYSTEM\CurrentControlSet\Services\usbuhci","ErrorControl",0x00010001,1
    HKLM,"SYSTEM\CurrentControlSet\Services\usbuhci","Group",0x00000000,"System Reserved"
    HKLM,"SYSTEM\CurrentControlSet\Services\usbuhci","ImagePath",0x00020000,"system32\DRIVERS\usbuhci.sys"
    HKLM,"SYSTEM\CurrentControlSet\Services\usbuhci","Start",0x00010001,0
    HKLM,"SYSTEM\CurrentControlSet\Services\usbuhci","Type",0x00010001,1

    HKLM,"SYSTEM\CurrentControlSet\Services\usbohci","DisplayName",0x00000000,"Microsoft USB Open Host Controller Miniport Driver"
    HKLM,"SYSTEM\CurrentControlSet\Services\usbohci","ErrorControl",0x00010001,1
    HKLM,"SYSTEM\CurrentControlSet\Services\usbohci","Group",0x00000000,"System Reserved"
    HKLM,"SYSTEM\CurrentControlSet\Services\usbohci","ImagePath",0x00020000,"system32\DRIVERS\usbohci.sys"
    HKLM,"SYSTEM\CurrentControlSet\Services\usbohci","Start",0x00010001,0
    HKLM,"SYSTEM\CurrentControlSet\Services\usbohci","Type",0x00010001,1


  9. If you haven't erased the original .IN_ files, do so now.


    erase USB.IN_
    erase USBPORT.IN_
    erase USBSTOR.IN_

    Compress the modified files with cabarc.


    cabarc n USB.IN_ usb.inf
    cabarc n USBPORT.IN_ usbport.inf
    cabarc n USBSTOR.IN_ usbstor.inf

    You'll get 3 compressed files with IN_ extension.



  10. Put these files back into the I386 subfolder of the Windows XP installation folder.

    • DOSNET.INF
    • TXTSETUP.SIF
    • USB.IN_
    • USBBOOT.INF
    • USBPORT.IN_
    • USBSTOR.IN_


  11. You'll need this boot sector (w2ksect.bin) to make your new CD bootable. Put w2ksect.bin inside the main folder containing XP files.



  12. Now, let's burn a new CD containing Windows XP files. Start ImgBurn and select Write files/folders to disc. Click the Browser for a folder... icon and select the folder containing Windows XP files. Then, set up options as follows.










    Insert a blank CD into your optical drive and burn it.



  13. Plug in your USB flash drive or USB hard drive to your computer and run the HP USB Disk Storage Format Tool. On Windows Vista or Windows 7, run it as administrator.




  14. From the I386 folder of XP installation CD, copy the following files to the USB drive:



    • ntldr
    • ntdetect.com

    Then, create a new file boot.ini with the following contents. Put it on the USB drive.


    [boot loader]
    timeout=30
    default=multi(0)disk(0)rdisk(0)partition(1)\WINDOWS

    [operating systems]
    multi(0)disk(0)rdisk(0)partition(1)\WINDOWS="Microsoft Windows XP Professional" /fastdetect


  15. Run the Partition Table Editor (PTEDIT32.EXE) as administrator. Select your USB drive from Hard Disk pulldown menu.




    Change the type of primary partition on the USB drive from 00 to 80. Click the Save Changes button.



    Partition Information should read FAT16X, Bootable



  16. Remove your hard drive from the computer. Then, connect your USB flash drive directly to your computer.



  17. Change the boot order in the BIOS so that your computer can boot from a USB drive. Typical BIOS options are as follows:


    • USB HDD
    • USB Hard Drive


  18. Insert your new Windows XP CD your burned above and boot your computer with it. During installation, don't format the USB drive. Just leave it as is.



  19. After successfully installing Windows XP on your USB drive, install the EWF or FBWF filter.



Monday, May 31, 2010

Compiling GTK+ for Windows with MinGW

GTK+ is a set of open-source widget libraries that are mature, functional and portable. GTK+ library is mainly used by many Linux programs. I am building a complete stack of GTK+ 2.x library before beginning my programming projects. This tutorial makes use of the free MinGW compiler to build GTK+.



If you haven't installed MinGW yet, read this tutorial on installing MinGW in Windows. Alternatively, you can also install MinGW Portable on your USB flash drive so you can enjoy compiling anywhere. GTK+ depends on many basic libraries that provide image, localization, font and other functions. These prerequisite libraries have be compiled first. Once you've installed MinGW and MSYS, launch MSYS. The following steps require you to type commands into MSYS console.




  1. Zlib 1.2.7


    Zlib is an essential compression library required by png, tiff and cairo. Get the zlib source and unpack it:

    tar xzvf zlib-1.2.7.tar.gz
    cd zlib-1.2.7/

    Compile zlib like this:


    make -f win32/Makefile.gcc

    Then, manually copy the files as follows:


    cp -iv zlib1.dll /mingw/bin
    cp -iv zconf.h zlib.h /mingw/include
    cp -iv libz.a /mingw/lib
    cp -iv libz.dll.a /mingw/lib


  2. libiconv 1.14


    libiconv is a character-set conversion library, and is needed by gettext. Download the libiconv source and compile libiconv:


    ./configure --prefix=/mingw
    make
    make install


  3. gettext 0.18.1.1


    GNU gettext is a tool for localizing and translating programs. Build gettext like this:


    ./configure --prefix=/mingw --enable-threads=win32 --enable-relocatable
    cd gettext-runtime/
    make
    make install


  4. glib 2.32.4


    glib's configure script requires pkg-config.exe and msgfmt.exe in the PATH. Download the executables and save them in /mingw/bin. Remember to set the system-wide environment variable PKG_CONFIG_PATH:


    export PKG_CONFIG_PATH=/mingw/lib/pkgconfig

    glib 2.30 and later depends on libffi. Compile libffi like this:


    ./configure --prefix=/mingw && make && make install

    Then, get the glib source from ftp.gnome.org and compile glib as follows:


    ./configure --prefix=/mingw --with-threads=win32 --with-pcre=internal --disable-debug
    make
    make install


  5. ATK 2.4.0


    Download ATK from here. Compile it like this:


    ./configure --prefix=/mingw
    make
    make install


  6. libpng 1.5.12


    PNG can be compiled like this:


    ./configure --prefix=/mingw
    make
    make install


  7. Optional libraries


    The following libraries are optional, but many GTK+ packages include them. It's up to you to decide whether to compile them or not.



    As usual, compile any of them like this:


    ./configure --prefix=/mingw && make && make install


  8. Pixman 0.26.2 and Cairo 1.12.2


    Get Pixman and Cairo from cairographics.org. Compile Pixman as follows:


    ./configure --prefix=/mingw

    make

    make install

    Then, compile cairo:


    ./configure --prefix=/mingw --enable-pthread
    make
    make install


  9. Pango Library 1.30.1


    Compile Pango like this:


    ./configure --prefix=/mingw --with-included-modules=yes

    make

    make install


  10. gdk-pixbuf 2.26.2


    Download and compile gdk-pixbuf:


    ./configure --prefix=/mingw --without-libjasper --with-included-loaders=yes --disable-modules --disable-debug
    make
    make install


  11. GTK+ 2.24.11 and GTK+ 3.4.2


    At last, we are ready to compile GTK+ for Windows. I compiled GTK+ like this:


    ./configure --prefix=/mingw --with-included-immodules=ime --disable-modules --disable-debug

    make

    make install


    To test your newly compiled GTK+ library, run gtk-demo.exe or testgtk.exe.



Wednesday, May 19, 2010

My Windows Vista/7 Power Settings

Here are my power settings on Windows Vista or Windows 7. I find the default setting annoying or inadequate, especially the Start menu power button triggering sleep.




  • Lid Close Action
    • On Battery: Sleep
    • Plugged in: Do nothing


  • Power Button Action
    • On Battery: Hibernate
    • Plugged in: Hibernate


  • Sleep Button
    • On Battery: Sleep
    • Plugged in: Hibernate


  • Start menu power button
    • On Battery: Shut down
    • Plugged in: Shut down

Monday, March 22, 2010

Free Command-Line Audio Encoders (for Windows)

Here you can download free, open-source audio encoders for MP3, OGG and AAC music formats. I compiled LAME and Ogg Vorbis tools with MinGW whereas FAAC was compiled by someone (faac-1.28.7z).




Install MPlayer, Mencoder, MP4Box and Mkvmerge


Download my package of Windows executables, including mencoder and mp4box here.



I built it using MinGW. The package contains the following programs.


  • faac.exe
  • faad.exe
  • lame.exe
  • mencoder.exe
  • MP4Box.exe
  • mpcenc.exe
  • mplayer.exe
  • normalize.exe
  • oggdec.exe
  • oggenc.exe
  • ogginfo.exe
  • speexdec.exe
  • speexenc.exe
  • twolame.exe
  • vorbiscomment.exe
  • x264.exe

It is recommended that you unpack the package into C:\Program Files. If MPlayer and Mencoder were installed in C:\Program Files\MPlayer, start Command Prompt and set PATH to include the MPlayer folder:


PATH "C:\Program Files\MPlayer\bin";%PATH%

Mkvmerge is part of Mkvtoolnix that can be obtained from http://www.bunkus.org/videotools/mkvtoolnix/.



Related Links


Saturday, March 13, 2010

Windows 7 Installation

I installed the following programs on my Windows 7 machine.



  • Adobe Flash Player
  • Adobe Reader 10.0
  • Avast Antivirus 5
  • CDBurnerXP or ImgBurn
  • Google Apps or Thinkfree
  • Google Chrome
  • IBM Lotus Symphony
  • iTunes
  • Java
  • Microsoft Office 2010
  • NVIDIA Driver
  • QuickTime
  • RealPlayer
  • Skype
  • Windows Live Essentials
  • Zimbra
  • Zumodrive

Saturday, February 20, 2010

Fixing Jittery DVD Sound on Windows 7

I've been using Windows 7 happily until I played a DVD movie and heard continuous jittery noise. The picture was fine, but Windows Media Player 12 only uttered the jittery noise instead of words and music.


I think it's a codec problem. To fix the problem, I downloaded Preferred Filter Tweaker for Windows 7 and disabled Microsoft DTV-DVD Audio Decoder.




This renames C:\Windows\System32\msmpeg2adec.dll so that Windows Media Player 12 doesn't use its own codec. Then, I installed AC3Filter. This fixed the jittery noise problem. Alternatively, ffdshow can be used instead of AC3Filter.

Sunday, January 17, 2010

gtk-gnutella for Windows

Here's my gtk-gnutella build.




You may choose to install the GTK+ library and gtk-gnutella in the same folder. This means gtk-gnutella.exe and libgtk-win32-2.0-0.dll are in the same place.


Create a shortcut on the desktop to the GTK-Gnutella executable. Double-click the shortcut to run gtk-gnutella.

Wednesday, November 25, 2009

Writing and Verifying a Floppy Image

First format a floppy with the following command:



fdformat /dev/fd0 (in Linux)
fdformat /dev/rfd0c (in OpenBSD)
format A: (in DOS)


Linux and OpenBSD


Insert a floppy and use the dd command to write an floppy image to the floppy diskette.



dd if=floppy46.fs of=/dev/fd0 bs=32k (in Linux)
dd if=floppy46.fs of=/dev/rfd0c bs=32k (in OpenBSD)


Use the following command to make sure that the image is written correctly to
the floppy.



cmp /dev/fd0 floppy46.fs (in Linux)
cmp /dev/rfd0c floppy46.fs (in OpenBSD)


Windows and DOS


If you use Windows XP, Vista or Windows 7, use fdimage or ntrw to write the boot floppy. Make sure the floppy has been formatted first.



C:\> ntrw floppy46.fs a:
3.5", 1.44MB, 512 bytes/sector
bufsize is 9216
1474560 bytes written


Or,



C:\> fdimage -q floppy46.fs a:


In Windows 9x/ME or DOS, you can use rawrite to write your boot floppy.



C:\> rawrite
RaWrite 1.2 - Write disk file to raw floppy diskette

Enter source file name: floppy46.fs
Enter destination drive: a
Please insert a formatted diskette into drive A: and press -ENTER- :

Sunday, November 22, 2009

To Activate Windows 7 on Toshiba Mini NB205

Because Toshiba Mini NB205 has BIOS with embedded SLIC 2.1 signature, it is easy to activate the netbook if the owner obtains an .xrm-ms file and a valid Windows key. Thanks to the Internet and powerful search engines, this seemingly difficult task becomes rather easy for average people. Surprisingly, new computers and motherboards in most cases come with SLP 2.1 capable BIOS, thus making it easy to activate new computers.


For your information, SLP (system locked preinstallation) 2.1 is the newest anti-piracy scheme used by Microsoft to sell more Windows 7 on OEM computers. In this case, BIOS of OEM computers have SLIC 2.1 signature which is unique per each OEM manufacturer. An OEM version of Windows 7 is installed on an OEM computer and contain an OEM certificate (*.xrm-ms) that should match SLP/SLIC 2.1 thing in the BIOS. In this post, it is assumed that you installed an OEM version of Microsoft Windows 7 that can be downloaded using utorrent, eMule or Limewire.


If you use the SLIC Dump Toolkit on Toshiba Mini NB205, you can find that SLIC 2.1 begins with the string TOSCPLTOSCPL00.


SLIC Dump Toolkit V2.0

Now you can search for an OEM certificate matching your SLIC 2.1 data with the help of a search engine. You can use such search keywords like: TOSCPLTOSCPL00 2.1 XRM-MS.


ysearch_toscpl

Clicking on the fourth link in the picture above, you'll be taken to a page where you can download a file containing TOSCPLTOSCPL00.XRM-MS. You'll need to type a 3-digit number to download the archive 2.1.rar. Once you downloaded it, open it and extract TOSCPLTOSCPL00.XRM-MS.


7-zip opening 2.1.rar

Open a command prompt with administrator privilege.


Start Command Prompt as Administrator

Type the following command to install the OEM certificate.


slmgr -ilc TOSCPLTOSCPL00.XRM-MS

Now you need to activate Windows 7 with a valid Windows 7 key. Use a command in the following form to activate Windows 7.


slmgr -ipk XXXXX-XXXXX-XXXXX-XXXXX-XXXXX

Some valid Windows 7 keys are circulating on the Internet. With luck, you'll be able to find one. The following are some keywords to locate a Windows 7 key:


Wednesday, October 28, 2009

Ethernet File Transfer between Windows XP and Windows Vista

I found it hard to set up file transfer between Windows XP and Windows Vista using direct Ethernet connection. Sometimes, Windows Vista can see a Windows XP machine, but Windows XP somehow can't see a Windows Vista machine. I connected a PC running Windows XP and a PC running Windows Vista with a Ethernet crossover cable.



Setting Up Windows XP for direct Ethernet connection


  1. Make sure that the following items are enabled in the Local Area Connection Properties dialog.

    • Client for Microsoft Networks
    • File and Printer Sharing for Microsoft Networks
    • Internet Protocol (TCP/IP)

    LAN Properties

    You can open the Local Area Connection Properties dialog by opening Control Panel, Choosing Network and Internet Connections category, clicking Network Connections icon, right-clicking the icon for your Ethernet connection and choosing Properties from the right-click menu.


  2. Select Internet Protocol (TCP/IP) and click Properties. Internet Protocol (TCP/IP) Properties dialog will show up. Click Use the following IP address and specify IP address and subnet mask. Then, click OK to close the Internet Protocol Properties dialog.

    Windows XP TCP/IP Properties
  3. Open the Advanced tab and click the Settings button in Windows Firewall area.

    LAN Advanced Properties
  4. Windows Firewall window will show up. Open the Exceptions tab and make sure that File and Printer Sharing is enabled. Click OK to close Windows Firewall window. Then, click the Close button in the Local Area Network Properties window.
  5. Now connect the PC running Windows XP to a PC running Windows Vista with a Ethernet crossover cable.
  6. In the Network Connections window, click and select the icon for your Ethernet connection. In the left pane of the Network Connections window, click Set up a home or small office network. Keep clicking the Next button until you reach the Select a connection method step. Choose Other. Then choose "This computer belongs to a network that does not have an Internet connection" and click Next.
  7. Make sure that your Computer name is unique. Click Next.
  8. Type a Workgroup name that will be shared with a PC running Windows Vista. Click Next.
  9. Turn on the file and printer sharing. Click Next.
  10. Review your network settings and click Next.
  11. Select "Just finish the wizard." Click the Finish button to close the wizard.


Setting Up Windows Vista for direct Ethernet Connection



  1. Open the Control Panel. Under the Network and Internet category, select View network status and tasks. In the left pane, click Manage network connections. Right-click the icon for your Ethernet connection and choose Properties.
  2. In the Local Area Connection Properties dialog, make sure the following items are enabled.
    • Client for Microsoft Networks
    • File and Printer Sharing for Microsoft Networks
    • Internet Protocol Version 4 (TCP/IPv4)
    • Link-Layer Topology Discovery Responder
    • Link-Layer Topology Discovery Mapper I/O Driver

  3. Select Internet Protocol Version 4 (TCP/IPv4) and click Properties. Click Use the following IP address and enter unique values for IP address and Subnet mask.

    Windows Vista TCP/IPv4 Properties
  4. Go back to the Network and Sharing Center. Unidentified network will be shown. Click Customize and choose Private.
  5. In the Sharing and Discovery area, make sure that you have the following settings.

    • Network discovery: On

      Expand the Network discovery section and verify that the workgroup is the same as with Windows XP.
    • File Sharing: On
    • Public folder sharing: On

      Expand this section and enable Turn on sharing so anyone with network access can open, change, and create files
    • Printer sharing: On or Off
    • Password protected sharing: Off

      To avoid unnecessary problems, check it off.
    • Media sharing: On

Sunday, October 18, 2009

Setting Up Windows 7 on Compaq Presario V5306US

I installed Windows 7 Home Premium on my old Compaq Presario V5306US notebook. Installation went without a problem, but 3 hardware components were not detected. They are:


  • ATI Mobility RADEON XPRESS X200M Series

  • In-Build Conexant ATI AC '97 Modem

  • HP Quick Launch Buttons


Since both of the built-in Ethernet and wireless network adapters are detected by Windows 7, I started Windows Update and installed the display driver through Windows Update. Drivers for the modem and quick launch buttons can be downloaded from HP/Compaq support site. For the quick launch buttons, extract the package with 7-zip and only install the driver.

The following pictures are taken from the device manager that list devices available in Compaq Presario V5306US.








About This Blog

KBlog logo This blog seeks to share useful information on hottest movies available on the Internet. Thanks for visiting the blog and posting your comments.

© Contents by KBlog

© Blogger template by Emporium Digital 2008

Followers

Total Pageviews

icon
Powered By Blogger