(problem noticed by Graham with List::Util).
p4raw-id: //depot/perl@18709
#ifndef PERL_VERSION
# include <patchlevel.h>
-# ifndef PERL_VERSION
+# if !(defined(PERL_VERSION) || (SUBVERSION > 0 && defined(PATCHLEVEL)))
# include <could_not_find_Perl_patchlevel.h>
# endif
# define PERL_VERSION PATCHLEVEL
}
#endif
-#include <patchlevel.h>
-#ifndef PERL_VERSION
-# include <could_not_find_Perl_patchlevel.h>
+#ifndef PATCHLEVEL
+# include <patchlevel.h>
+# if !(defined(PERL_VERSION) || (SUBVERSION > 0 && defined(PATCHLEVEL)))
+# include <could_not_find_Perl_patchlevel.h>
+# endif
#endif
+
#if PATCHLEVEL <= 4 && !defined(PL_dowarn)
#define PL_dowarn dowarn
#endif
}
#endif
-#include "patchlevel.h"
+#ifndef PATCHLEVEL
+# include <patchlevel.h>
+# if !(defined(PERL_VERSION) || (SUBVERSION > 0 && defined(PATCHLEVEL)))
+# include <could_not_find_Perl_patchlevel.h>
+# endif
+#endif
+
#if PATCHLEVEL <= 4 && !defined(PL_dowarn)
#define PL_dowarn dowarn
#endif
#include <EXTERN.h>
#include <perl.h>
-#include <patchlevel.h> /* Perl's one, needed since 5.6 */
+#include <XSUB.h>
+
#ifndef PERL_VERSION
-# include <could_not_find_Perl_patchlevel.h>
+# include <patchlevel.h> /* Perl's one, needed since 5.6 */
+# if !(defined(PERL_VERSION) || (SUBVERSION > 0 && defined(PATCHLEVEL)))
+# include <could_not_find_Perl_patchlevel.h>
+# endif
#endif
-#include <XSUB.h>
#ifndef NETWARE
#if 0