--- a/xed_mbuild.py
+++ b/xed_mbuild.py
@@ -2262,6 +2262,7 @@
                           'lib%(base_lib)s.so',
                           '%(base_lib)s.lib',
                           '%(base_lib)s.dll',
+                          'lib%(base_lib)s.dll',
                           'lib%(base_lib)s.dylib' ] 
     libnames = []
     for base_lib in ['xed', 'xed-ild']:
@@ -2330,9 +2331,6 @@
     """Build install in the prefix_dir. Use prefix_lib_dir as library name
        since some systems use lib, lib32 or lib64. non-windows only.
     """
-    if env.on_windows():
-        return
-
     if not env['prefix_dir']:
         return
 
@@ -2343,6 +2341,8 @@
 
     def _set_perm(fn):
         "-rwx-r-xr-x"
+        if env.on_windows():
+            return
         os.chmod(fn, stat.S_IRUSR|stat.S_IRGRP|stat.S_IROTH|
                      stat.S_IXUSR|stat.S_IXGRP|stat.S_IXOTH|
                      stat.S_IWUSR)
--- a/xed_build_common.py
+++ b/xed_build_common.py
@@ -143,7 +143,7 @@
                 ### Inexecutable Stack ###
                 # Specifies that the stack memory should be marked as non-executable
                 env.add_to_var('LINKFLAGS','-z noexecstack')
-        else:  # Windows
+        elif env['compiler'] == 'ms':  # MSVC compiler
             # Enables Data Execution Prevention (DEP) for executables.
             env.add_to_var('LINKFLAGS','-z /NXCOMPAT')
             # Enables address space layout randomization (ASLR) for executables.
@@ -412,8 +412,8 @@
        base we return base.lib and base.dll on windows.  base.so and
        base.so on non-windows.  Users link against the link lib."""
     
-    dll = env.shared_lib_name(base)
-    static_lib = env.static_lib_name(base)
+    dll = env.shared_lib_name("lib" + base)
+    static_lib = env.static_lib_name("lib" + base)
     
     if env['shared']:
         if env.on_windows():
@@ -429,11 +429,11 @@
     return mbuild.join(env['xed_lib_dir'],s)
 
 def get_libxed_names(env):
-    libxed_lib, libxed_dll = make_lib_dll(env,'xed')
+    libxed_lib, libxed_dll = make_lib_dll(env,'libxed')
     env['link_libxed'] = _xed_lib_dir_join(env,libxed_lib)
     env['shd_libxed']  = _xed_lib_dir_join(env,libxed_dll)
         
-    lib,dll = make_lib_dll(env,'xed-ild')
+    lib,dll = make_lib_dll(env,'libxed-ild')
     env['link_libild'] = _xed_lib_dir_join(env,lib)
     env['shd_libild']  = _xed_lib_dir_join(env,dll)
     
