diff --git a/smartmontools/CHANGELOG b/smartmontools/CHANGELOG
index d99985df9f4d314d35907698f667957949b9bdfa..9e058df10c2f5e85a6cbaba4f359a92ba12865be 100644
--- a/smartmontools/CHANGELOG
+++ b/smartmontools/CHANGELOG
@@ -43,6 +43,9 @@ NOTES FOR FUTURE RELEASES: see TODO file.
 
 <DEVELOPERS: ADDITIONS TO THE CHANGE LOG GO JUST BELOW HERE, PLEASE>
 
+  [CF] Move 'posix/getopt*' to 'getopt/getopt*'.  Can be used for
+       platforms with regex() but without getopt_long() (QNX, ticket #1).
+
   [CF] smartd '-l selftest' directive: Print info if error count
        decreased.  Avoid misleading warning if error count decreased
        to zero (ticket #67).
diff --git a/smartmontools/posix/getopt.c b/smartmontools/getopt/getopt.c
similarity index 100%
rename from smartmontools/posix/getopt.c
rename to smartmontools/getopt/getopt.c
diff --git a/smartmontools/posix/getopt.h b/smartmontools/getopt/getopt.h
similarity index 100%
rename from smartmontools/posix/getopt.h
rename to smartmontools/getopt/getopt.h
diff --git a/smartmontools/posix/getopt1.c b/smartmontools/getopt/getopt1.c
similarity index 100%
rename from smartmontools/posix/getopt1.c
rename to smartmontools/getopt/getopt1.c
diff --git a/smartmontools/os_win32/smartctl_vc8.vcproj b/smartmontools/os_win32/smartctl_vc8.vcproj
index 980ff787f23c3d09029980d1f68f3577b9be3c26..ea44ab7f0e662cccb81d21a8a7c5587297db5ef8 100644
--- a/smartmontools/os_win32/smartctl_vc8.vcproj
+++ b/smartmontools/os_win32/smartctl_vc8.vcproj
@@ -304,18 +304,6 @@
 		<Filter
 			Name="posix"
 			>
-			<File
-				RelativePath="..\posix\getopt.c"
-				>
-			</File>
-			<File
-				RelativePath="..\posix\getopt.h"
-				>
-			</File>
-			<File
-				RelativePath="..\posix\getopt1.c"
-				>
-			</File>
 			<File
 				RelativePath="..\posix\regcomp.c"
 				>
@@ -389,6 +377,22 @@
 				</FileConfiguration>
 			</File>
 		</Filter>
+		<Filter
+			Name="getopt"
+			>
+			<File
+				RelativePath="..\getopt\getopt.c"
+				>
+			</File>
+			<File
+				RelativePath="..\getopt\getopt.h"
+				>
+			</File>
+			<File
+				RelativePath="..\getopt\getopt1.c"
+				>
+			</File>
+		</Filter>
 		<File
 			RelativePath="..\atacmdnames.cpp"
 			>
diff --git a/smartmontools/os_win32/smartd_vc8.vcproj b/smartmontools/os_win32/smartd_vc8.vcproj
index 807d4a2f0f5678355a1d2510a75a9571b69e6204..c98b5f0445c21317af60a2d9b1d94dc2334ca86a 100644
--- a/smartmontools/os_win32/smartd_vc8.vcproj
+++ b/smartmontools/os_win32/smartd_vc8.vcproj
@@ -208,18 +208,6 @@
 		<Filter
 			Name="posix"
 			>
-			<File
-				RelativePath="..\posix\getopt.c"
-				>
-			</File>
-			<File
-				RelativePath="..\posix\getopt.h"
-				>
-			</File>
-			<File
-				RelativePath="..\posix\getopt1.c"
-				>
-			</File>
 			<File
 				RelativePath="..\posix\regcomp.c"
 				>
@@ -293,6 +281,22 @@
 				</FileConfiguration>
 			</File>
 		</Filter>
+		<Filter
+			Name="getopt"
+			>
+			<File
+				RelativePath="..\getopt\getopt.c"
+				>
+			</File>
+			<File
+				RelativePath="..\getopt\getopt.h"
+				>
+			</File>
+			<File
+				RelativePath="..\getopt\getopt1.c"
+				>
+			</File>
+		</Filter>
 		<File
 			RelativePath="..\atacmdnames.cpp"
 			>