r60312 - in /trunk/libopengl-perl: Makefile.PL debian/changelog debian/patches/disable-glversion

chrisb at users.alioth.debian.org chrisb at users.alioth.debian.org
Wed Jul 14 19:06:27 UTC 2010


Author: chrisb
Date: Wed Jul 14 19:06:05 2010
New Revision: 60312

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=60312
Log:
Refreshed disable-glversion patch.

Modified:
    trunk/libopengl-perl/Makefile.PL
    trunk/libopengl-perl/debian/changelog
    trunk/libopengl-perl/debian/patches/disable-glversion

Modified: trunk/libopengl-perl/Makefile.PL
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libopengl-perl/Makefile.PL?rev=60312&op=diff
==============================================================================
--- trunk/libopengl-perl/Makefile.PL (original)
+++ trunk/libopengl-perl/Makefile.PL Wed Jul 14 19:06:05 2010
@@ -766,166 +766,6 @@
 sub get_extensions
 {
   my($found,$no_excl) = @_;
-  print "Testing for OpenGL Extensions\n" if ($verbose);
-
-  # clean up previous output files
-  my $exc_file = 'gl_exclude.h';
-  unlink($exc_file) if (-e $exc_file);
-  my $glv_file = 'utils/glversion.txt';
-  unlink($glv_file) if (-e $glv_file);
-
-  # Only run the rest if GLUT is installed
-  print "Testing GLUT version\n" if ($verbose);
-  my($lib,$def);
-  if ($found->{FREEGLUT32} || $found->{FREEGLUT})
-  {
-    $lib = $found->{FREEGLUT32} || $found->{FREEGLUT};
-    $def = "HAVE_FREEGLUT";
-  }
-  elsif ($found->{GLUT32} || $found->{GLUT})
-  {
-    $lib = $found->{GLUT32} || $found->{GLUT};
-    $def = "HAVE_GLUT";
-  }
-  elsif ($verbose)
-  {
-    print "GLUT not found\n";
-  }
-
-  # Platform-specific makefiles for glversion
-  my $make_ver;
-  if ($IS_MINGW)
-  {
-    $make_ver = "&mingw.bat";
-#    $make_ver = '&dmake -f makefile.mingw GLUT_DEF='.$def;
-    print "mingw glversion: '$make_ver'\n" if $verbose>1;
-  }
-  elsif ($IS_W32API)
-  {
-    $make_ver = ";make -f Makefile.cygwin " .  (length($lib) ? "GLUT_LIB=$lib " : "") . (length($def) ? "GLUT_DEF=$def " : "");
-    print "cygwin glversion: '$make_ver'\n" if $verbose>1;
-  }
-  elsif ($^O eq 'MSWin32')
-  {
-    $make_ver = '&nmake -f makefile.mak ' . (length($def) ? "GLUT_DEF=$def " : "");
-    print "MSWin32 glversion: '$make_ver'\n" if $verbose>1;
-  }
-  elsif ($^O eq 'darwin')
-  {
-    $make_ver = ";make -f Makefile.macosx " .  (length($lib) ? "GLUT_LIB=$lib " : "") . (length($def) ? "GLUT_DEF=$def " : "");
-    print "MacOSX glversion: '$make_ver'\n" if $verbose>1;
-  }
-  else
-  {
-    if ($ENV{TERM} ne 'xterm')
-    {
-      print "\nIn order to test your GPU's capabilities, run this make under an X11 shell\n\n";
-    }
-
-    $make_ver = ";make -f Makefile " .  (length($lib) ? "GLUT_LIB=$lib " : "") . (length($def) ? "GLUT_DEF=$def " : "");
-    print "glversion: '$make_ver'\n" if $verbose>1;
-  }
-  my $exec = 'cd utils'."$make_ver clean".$make_ver;
-  print "glversion: $exec\n" if ($verbose);
-  my $stat = `$exec`;
-  print "\n$stat\n\n" if ($verbose);
-
-
-  # Parse glversion.txt file
-  if ( !defined(open(GLDATA,$glv_file)) ) {
-     print "get_extensions: could not open $glv_file: $!\n" if $verbose;
-     return '';
-  }
-  my $gldata = {};
-  my @gldata = <GLDATA>;
-  close(GLDATA);
-
-  foreach my $line (@gldata)
-  {
-    $line =~ s|[\r\n]+||;
-    my($key,$val) = split('=',$line);
-    $gldata->{$key} = $val;
-  }
-  if (!scalar(keys %$gldata)) {
-     print "get_extensions: no extensions found in $glv_file\n" if $verbose;
-     return '';
-  }
-
-
-  # Parse glext_procs.h file
-  return '' if (!open(GLEXT,"glext_procs.h"));
-  my @lines = <GLEXT>;
-  close(GLEXT);
-
-  my $no_ext = {};
-  foreach my $line (@lines)
-  {
-    next if ($line !~ m|\#ifndef NO_([^\s]+)|);
-    my $ext = $1;
-    next if ($ext =~ m|^GL_VERSION_|);
-    $no_ext->{$ext}++;
-  }
-
-
-  # Create gl_exclude.h
-  die "Unable to write to $exc_file\n" if (!open(GLEXC,">$exc_file"));
-  print GLEXC "// OpenGL Extension Exclusions - may be modified before building.\n";
-  print GLEXC "//\n";
-  print GLEXC "// Generated for ".$gldata->{VENDOR}.", ".$gldata->{RENDERER}."\n";
-  print GLEXC "// OpenGL v".$gldata->{VERSION}.", using ";
-
-  # Fix GLUT flags based on results
-  if ($gldata->{GLUT} > 0)
-  {
-    print 'Found FreeGLUT v'.$gldata->{GLUT}."\n";
-    print GLEXC 'FreeGLUT v'.$gldata->{GLUT}."\n";
-
-    if (!$found->{FREEGLUT} && !$found->{FREEGLUT32})
-    {
-      $found->{FREEGLUT} = $lib;
-    }
-  }
-  else
-  {
-    print "Found GLUT - unknown version\n";
-  }
-
-  # Make an empty exclusion file if a Windows distribution build
-  if ($no_excl)
-  {
-    print "OpenGL Extension exclusions disabled\n";
-    print GLEXC "//\n";
-    print GLEXC "// Exclusions omitted for distribution build.\n";
-  }
-  else
-  {
-    print GLEXC "\n";
-    if ($gldata->{VERSION} =~ m|^(\d\.\d+)|)
-    {
-      my $ver = $1;
-      print GLEXC "#define NO_GL_VERSION_2_0\n" if ($ver < 2.0);
-      print GLEXC "#define NO_GL_VERSION_1_5\n" if ($ver < 1.5);
-      print GLEXC "#define NO_GL_VERSION_1_4\n" if ($ver < 1.4);
-      print GLEXC "#define NO_GL_VERSION_1_3\n" if ($ver < 1.3);
-      print GLEXC "#define NO_GL_VERSION_1_2\n" if ($ver < 1.2);
-      print GLEXC "#define NO_GL_VERSION_1_1\n" if ($ver < 1.1);
-    }
-
-    foreach my $ext (split(' ',$gldata->{EXTENSIONS}))
-    {
-      next if (!$no_ext->{$ext});
-      $no_ext->{$ext} = 0;
-    }
-
-    foreach my $ext (sort keys(%$no_ext))
-    {
-      next if (!$no_ext->{$ext});
-      print GLEXC "#define NO_$ext\n";
-    }
-  }
-
-  close(GLEXC);
-
 
   # return Distributable Defs
   print "Have Version Data\n" if ($verbose);

Modified: trunk/libopengl-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libopengl-perl/debian/changelog?rev=60312&op=diff
==============================================================================
--- trunk/libopengl-perl/debian/changelog (original)
+++ trunk/libopengl-perl/debian/changelog Wed Jul 14 19:06:05 2010
@@ -5,7 +5,8 @@
     number.
   * Add myself to copyright and Uploaders.
   * Switched to source format 3.0 (quilt), removed quilt framework.
-  * Removed patch fix-pod-spelling (applied upstream).
+  * Removed patch fix-pod-spelling (applied upstream), refreshed
+    disable-glversion patch.
 
  -- Chris Butler <chrisb at debian.org>  Wed, 14 Jul 2010 19:46:07 +0100
 

Modified: trunk/libopengl-perl/debian/patches/disable-glversion
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libopengl-perl/debian/patches/disable-glversion?rev=60312&op=diff
==============================================================================
--- trunk/libopengl-perl/debian/patches/disable-glversion (original)
+++ trunk/libopengl-perl/debian/patches/disable-glversion Wed Jul 14 19:06:05 2010
@@ -3,7 +3,7 @@
 includes a gl_exclude.h already that works for us, so just skip the detection.
 --- a/Makefile.PL
 +++ b/Makefile.PL
-@@ -764,166 +764,6 @@
+@@ -766,166 +766,6 @@
  sub get_extensions
  {
    my($found,$no_excl) = @_;




More information about the Pkg-perl-cvs-commits mailing list