$NetBSD: patch-ab,v 1.1 2010/09/10 13:36:15 taca Exp $

Use RUBY_PLATFORM instead of obsolete PLATFORM.

--- extconf.rb.orig	2003-07-06 17:20:37.000000000 +0000
+++ extconf.rb
@@ -7,7 +7,7 @@ require "mkmf"
 #
 # detect GTK+ configurations
 #
-if /mswin32/ !~ PLATFORM
+if /mswin32/ !~ RUBY_PLATFORM
   config_cmd = with_config("gtk-config", "gtk-config")
  
   begin
@@ -55,9 +55,9 @@ begin
   Dir.chdir "src"
 
   lib_ary = []
-  if /cygwin|mingw/ =~ PLATFORM
+  if /cygwin|mingw/ =~ RUBY_PLATFORM
     $CFLAGS += " -fnative-struct -DNATIVE_WIN32" unless gdkx
-  elsif /mswin32/ !~ PLATFORM
+  elsif /mswin32/ !~ RUBY_PLATFORM
     lib_ary = [ ["X11", "XOpenDisplay"],
                 ["Xext", "XShmQueryVersion"],
                 ["Xi", "XOpenDevice"],
@@ -94,7 +94,7 @@ begin
     item.gsub(/\.c$/, obj_ext)
   end
 
-  if /mswin32/ =~ PLATFORM
+  if /mswin32/ =~ RUBY_PLATFORM
     $objs << "rbgdkkeysyms.lib"
   else
     $objs << "librbgdkkeysyms.a"
@@ -104,7 +104,7 @@ begin
   raise Interrupt if not FileTest.exist? "Makefile"
 
   mfile = File.open("Makefile", "a")
-  if /mswin32/ =~ PLATFORM
+  if /mswin32/ =~ RUBY_PLATFORM
     mfile.puts "	copy /Y  gtk.lib .."
     mfile.puts
   end
@@ -115,7 +115,7 @@ begin
   mfile.print "rbgdkconst#{obj_ext}: rbgdkconst.c rbgdkcursors.h\n"
   mfile.print "rbgdk#{obj_ext}: rbgdk.c global.h\n"
 
-  if /mswin32/ =~ PLATFORM
+  if /mswin32/ =~ RUBY_PLATFORM
     mfile.print "\
 rbgdkkeysyms.lib: makedefconst.rb rbgdkkeysyms.h
 	$(RUBY) makedefconst.rb rbgdkkeysyms.h Init_gtk_gdkkeysyms
@@ -144,7 +144,7 @@ allclean: clean
   Dir.chdir ".."
 
   mfile = File.open("Makefile", "w")
-  if /mswin32/ =~ PLATFORM
+  if /mswin32/ =~ RUBY_PLATFORM
     mfile.print "\
 
 all:
