summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--MANIFEST1
-rw-r--r--NetWare/Makefile1
-rwxr-xr-xconfigpm4
-rw-r--r--doio.c7
-rw-r--r--embed.fnc2
-rw-r--r--embed.h2
-rw-r--r--ext/PerlIO-encoding/encoding.pm2
-rw-r--r--ext/PerlIO-encoding/encoding.xs2
-rw-r--r--makedef.pl84
-rw-r--r--perl.h13
-rw-r--r--perlio.c74
-rw-r--r--perlio.h13
-rw-r--r--perlsfio.h83
-rw-r--r--pod/perlapio.pod9
-rw-r--r--pod/perlfunc.pod3
-rw-r--r--pod/perliol.pod3
-rw-r--r--pp_ctl.c2
-rw-r--r--proto.h2
-rw-r--r--t/io/fflush.t3
-rw-r--r--t/io/pipe.t5
-rw-r--r--t/op/lfs.t2
-rw-r--r--t/op/sprintf.t4
-rw-r--r--universal.c4
-rw-r--r--util.c13
-rw-r--r--win32/Makefile1
-rw-r--r--win32/Makefile.ce1
-rw-r--r--win32/makefile.mk1
-rw-r--r--win32/win32.c2
-rw-r--r--win32/wince.c2
29 files changed, 30 insertions, 315 deletions
diff --git a/MANIFEST b/MANIFEST
index 23fa14387d..5f2bab1c61 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -4460,7 +4460,6 @@ perlio.h PerlIO abstraction
perliol.h PerlIO Layer definition
perlio.sym Symbols for PerlIO abstraction
perlsdio.h Fake stdio using perlio
-perlsfio.h Prototype sfio mapping for PerlIO
perlvars.h Global variables
perly.act parser actions; derived from perly.y
perly.c parser code (NOT derived from perly.y)
diff --git a/NetWare/Makefile b/NetWare/Makefile
index 8691bf462f..a002f3f36d 100644
--- a/NetWare/Makefile
+++ b/NetWare/Makefile
@@ -764,7 +764,6 @@ CORE_NOCFG_H = \
..\perl.h \
..\perlapi.h \
..\perlsdio.h \
- ..\perlsfio.h \
..\perly.h \
..\pp.h \
..\proto.h \
diff --git a/configpm b/configpm
index fbc471009d..cf105baf58 100755
--- a/configpm
+++ b/configpm
@@ -72,13 +72,13 @@ my %Extensions = map {($_,$_)}
# Could use a map to add ".h", but I suspect that it's easier to use literals,
# so that anyone using grep will find them
-# This is the list from MM_VMS, plus pad.h, parser.h, perlsfio.h utf8.h
+# This is the list from MM_VMS, plus pad.h, parser.h, utf8.h
# which it installs. It *doesn't* install perliol.h - FIXME.
my @header_files = qw(EXTERN.h INTERN.h XSUB.h av.h config.h cop.h cv.h
embed.h embedvar.h form.h gv.h handy.h hv.h hv_func.h intrpvar.h
iperlsys.h keywords.h mg.h nostdio.h op.h opcode.h
pad.h parser.h patchlevel.h perl.h perlio.h perlsdio.h
- perlsfio.h perlvars.h perly.h pp.h pp_proto.h proto.h
+ perlvars.h perly.h pp.h pp_proto.h proto.h
regcomp.h regexp.h regnodes.h scope.h sv.h thread.h utf8.h
util.h);
diff --git a/doio.c b/doio.c
index fe74cc95db..86f366aa73 100644
--- a/doio.c
+++ b/doio.c
@@ -359,13 +359,6 @@ Perl_do_openn(pTHX_ GV *gv, const char *oname, I32 len, int as_raw,
* be optimized away on most platforms;
* only Solaris and Linux seem to flush
* on that. --jhi */
-#ifdef USE_SFIO
- /* sfio fails to clear error on next
- sfwrite, contrary to documentation.
- -- Nicholas Clark */
- if (PerlIO_seek(that_fp, 0, SEEK_CUR) == -1)
- PerlIO_clearerr(that_fp);
-#endif
/* On the other hand, do all platforms
* take gracefully to flushing a read-only
* filehandle? Perhaps we should do
diff --git a/embed.fnc b/embed.fnc
index 2b82824a65..42ab356823 100644
--- a/embed.fnc
+++ b/embed.fnc
@@ -2382,7 +2382,7 @@ pMXE |SV* |sv_setsv_cow |NULLOK SV* dstr|NN SV* sstr
Aop |const char *|PerlIO_context_layers|NULLOK const char *mode
-#if defined(USE_PERLIO) && !defined(USE_SFIO)
+#if defined(USE_PERLIO)
Ap |int |PerlIO_close |NULLOK PerlIO *f
Ap |int |PerlIO_fill |NULLOK PerlIO *f
Ap |int |PerlIO_fileno |NULLOK PerlIO *f
diff --git a/embed.h b/embed.h
index 9e3af8bacb..0f8e82c502 100644
--- a/embed.h
+++ b/embed.h
@@ -822,7 +822,7 @@
#if defined(USE_LOCALE_COLLATE)
#define sv_collxfrm_flags(a,b,c) Perl_sv_collxfrm_flags(aTHX_ a,b,c)
#endif
-#if defined(USE_PERLIO) && !defined(USE_SFIO)
+#if defined(USE_PERLIO)
#define PerlIO_clearerr(a) Perl_PerlIO_clearerr(aTHX_ a)
#define PerlIO_close(a) Perl_PerlIO_close(aTHX_ a)
#define PerlIO_eof(a) Perl_PerlIO_eof(aTHX_ a)
diff --git a/ext/PerlIO-encoding/encoding.pm b/ext/PerlIO-encoding/encoding.pm
index e3291a54b0..8d39ed9a20 100644
--- a/ext/PerlIO-encoding/encoding.pm
+++ b/ext/PerlIO-encoding/encoding.pm
@@ -1,7 +1,7 @@
package PerlIO::encoding;
use strict;
-our $VERSION = '0.17';
+our $VERSION = '0.18';
our $DEBUG = 0;
$DEBUG and warn __PACKAGE__, " called by ", join(", ", caller), "\n";
diff --git a/ext/PerlIO-encoding/encoding.xs b/ext/PerlIO-encoding/encoding.xs
index f522ef101c..fababd1d70 100644
--- a/ext/PerlIO-encoding/encoding.xs
+++ b/ext/PerlIO-encoding/encoding.xs
@@ -6,7 +6,7 @@
#define OUR_DEFAULT_FB "Encode::PERLQQ"
-#if defined(USE_PERLIO) && !defined(USE_SFIO)
+#if defined(USE_PERLIO)
/* Define an encoding "layer" in the perliol.h sense.
diff --git a/makedef.pl b/makedef.pl
index 5c4985933c..c97fdc46db 100644
--- a/makedef.pl
+++ b/makedef.pl
@@ -635,88 +635,8 @@ if ($define{'USE_PERLIO'}) {
# of its implementation - read from a file
push @syms, 'perlio.sym';
- # This part is then dependent on how the abstraction is implemented
- if ($define{'USE_SFIO'}) {
- # Old legacy non-stdio "PerlIO"
- ++$skip{$_} foreach @layer_syms;
- ++$skip{perlsio_binmode};
- # SFIO defines most of the PerlIO routines as macros
- # So undo most of what $perlio_sym has just done - d'oh !
- # Perhaps it would be better to list the ones which do exist
- # And emit them
- ++$skip{$_} foreach qw(
- PerlIO_canset_cnt
- PerlIO_clearerr
- PerlIO_close
- PerlIO_eof
- PerlIO_error
- PerlIO_exportFILE
- PerlIO_fast_gets
- PerlIO_fdopen
- PerlIO_fileno
- PerlIO_findFILE
- PerlIO_flush
- PerlIO_get_base
- PerlIO_get_bufsiz
- PerlIO_get_cnt
- PerlIO_get_ptr
- PerlIO_getc
- PerlIO_getname
- PerlIO_has_base
- PerlIO_has_cntptr
- PerlIO_importFILE
- PerlIO_open
- PerlIO_printf
- PerlIO_putc
- PerlIO_puts
- PerlIO_read
- PerlIO_releaseFILE
- PerlIO_reopen
- PerlIO_rewind
- PerlIO_seek
- PerlIO_set_cnt
- PerlIO_set_ptrcnt
- PerlIO_setlinebuf
- PerlIO_stderr
- PerlIO_stdin
- PerlIO_stdout
- PerlIO_stdoutf
- PerlIO_tell
- PerlIO_ungetc
- PerlIO_vprintf
- PerlIO_write
- PerlIO_perlio
- Perl_PerlIO_clearerr
- Perl_PerlIO_close
- Perl_PerlIO_eof
- Perl_PerlIO_error
- Perl_PerlIO_fileno
- Perl_PerlIO_fill
- Perl_PerlIO_flush
- Perl_PerlIO_get_base
- Perl_PerlIO_get_bufsiz
- Perl_PerlIO_get_cnt
- Perl_PerlIO_get_ptr
- Perl_PerlIO_read
- Perl_PerlIO_seek
- Perl_PerlIO_set_cnt
- Perl_PerlIO_set_ptrcnt
- Perl_PerlIO_setlinebuf
- Perl_PerlIO_stderr
- Perl_PerlIO_stdin
- Perl_PerlIO_stdout
- Perl_PerlIO_tell
- Perl_PerlIO_unread
- Perl_PerlIO_write
- PL_def_layerlist
- PL_known_layers
- PL_perlio
- );
- }
- else {
- # PerlIO with layers - export implementation
- try_symbols(@layer_syms, 'perlsio_binmode');
- }
+ # PerlIO with layers - export implementation
+ try_symbols(@layer_syms, 'perlsio_binmode');
} else {
# -Uuseperlio
# Skip the PerlIO layer symbols - although
diff --git a/perl.h b/perl.h
index 5e3b84654e..f245ad9d2e 100644
--- a/perl.h
+++ b/perl.h
@@ -1016,12 +1016,6 @@ EXTERN_C int usleep(unsigned int);
# include <arpa/inet.h>
#endif
-#if defined(SF_APPEND) && defined(USE_SFIO) && defined(I_SFIO)
-/* <sfio.h> defines SF_APPEND and <sys/stat.h> might define SF_APPEND
- * (the neo-BSD seem to do this). */
-# undef SF_APPEND
-#endif
-
#ifdef I_SYS_STAT
# include <sys/stat.h>
#endif
@@ -2960,7 +2954,7 @@ typedef pthread_key_t perl_key;
* out there, Solaris being the most prominent.
*/
#ifndef PERL_FLUSHALL_FOR_CHILD
-# if defined(USE_PERLIO) || defined(FFLUSH_NULL) || defined(USE_SFIO)
+# if defined(USE_PERLIO) || defined(FFLUSH_NULL)
# define PERL_FLUSHALL_FOR_CHILD PerlIO_flush((PerlIO*)NULL)
# else
# ifdef FFLUSH_ALL
@@ -3976,7 +3970,7 @@ typedef Sighandler_t Sigsave_t;
# define RUNOPS_DEFAULT Perl_runops_standard
#endif
-#if defined(USE_PERLIO) && !defined(USE_SFIO)
+#if defined(USE_PERLIO)
EXTERN_C void PerlIO_teardown(void);
# ifdef USE_ITHREADS
# define PERLIO_INIT MUTEX_INIT(&PL_perlio_mutex)
@@ -4631,9 +4625,6 @@ EXTCONST char PL_bincompat_options[] =
# ifdef USE_REENTRANT_API
" USE_REENTRANT_API"
# endif
-# ifdef USE_SFIO
- " USE_SFIO"
-# endif
# ifdef USE_SOCKS
" USE_SOCKS"
# endif
diff --git a/perlio.c b/perlio.c
index 1369cd8476..5d41e76c55 100644
--- a/perlio.c
+++ b/perlio.c
@@ -117,8 +117,6 @@ extern off_t ftello(FILE *);
#define NATIVE_0xd CR_NATIVE
#define NATIVE_0xa LF_NATIVE
-#ifndef USE_SFIO
-
EXTERN_C int perlsio_binmode(FILE *fp, int iotype, int mode);
int
@@ -157,7 +155,6 @@ perlsio_binmode(FILE *fp, int iotype, int mode)
# endif
#endif
}
-#endif /* sfio */
#ifndef O_ACCMODE
#define O_ACCMODE 3 /* Assume traditional implementation */
@@ -234,14 +231,7 @@ PerlIO_destruct(pTHX)
int
PerlIO_binmode(pTHX_ PerlIO *fp, int iotype, int mode, const char *names)
{
-#ifdef USE_SFIO
- PERL_UNUSED_ARG(iotype);
- PERL_UNUSED_ARG(mode);
- PERL_UNUSED_ARG(names);
- return 1;
-#else
return perlsio_binmode(fp, iotype, mode);
-#endif
}
PerlIO *
@@ -366,67 +356,6 @@ PerlIO_tmpfile(void)
#else /* PERLIO_IS_STDIO */
-#ifdef USE_SFIO
-
-#undef HAS_FSETPOS
-#undef HAS_FGETPOS
-
-/*
- * This section is just to make sure these functions get pulled in from
- * libsfio.a
- */
-
-#undef PerlIO_tmpfile
-PerlIO *
-PerlIO_tmpfile(void)
-{
- return sftmp(0);
-}
-
-void
-PerlIO_init(pTHX)
-{
- PERL_UNUSED_CONTEXT;
- /*
- * Force this file to be included in perl binary. Which allows this
- * file to force inclusion of other functions that may be required by
- * loadable extensions e.g. for FileHandle::tmpfile
- */
-
- /*
- * Hack sfio does its own 'autoflush' on stdout in common cases. Flush
- * results in a lot of lseek()s to regular files and lot of small
- * writes to pipes.
- */
- sfset(sfstdout, SF_SHARE, 0);
-}
-
-/* This is not the reverse of PerlIO_exportFILE(), PerlIO_releaseFILE() is. */
-PerlIO *
-PerlIO_importFILE(FILE *stdio, const char *mode)
-{
- const int fd = fileno(stdio);
- if (!mode || !*mode) {
- mode = "r+";
- }
- return PerlIO_fdopen(fd, mode);
-}
-
-FILE *
-PerlIO_findFILE(PerlIO *pio)
-{
- const int fd = PerlIO_fileno(pio);
- FILE * f = fdopen(fd, "r+");
- PerlIO_flush(pio);
- if (!f && errno == EINVAL)
- f = fdopen(fd, "w");
- if (!f && errno == EINVAL)
- f = fdopen(fd, "r");
- return f;
-}
-
-
-#else /* USE_SFIO */
/*======================================================================================*/
/*
* Implement all the PerlIO interface ourselves.
@@ -5063,7 +4992,6 @@ PerlIO_tmpfile(void)
#undef HAS_FSETPOS
#undef HAS_FGETPOS
-#endif /* USE_SFIO */
#endif /* PERLIO_IS_STDIO */
/*======================================================================================*/
@@ -5166,7 +5094,7 @@ PerlIO_getpos(PerlIO *f, SV *pos)
}
#endif
-#if (defined(PERLIO_IS_STDIO) || !defined(USE_SFIO)) && !defined(HAS_VPRINTF)
+#if !defined(HAS_VPRINTF)
int
vprintf(char *pat, char *args)
diff --git a/perlio.h b/perlio.h
index 34968c3a29..777c886f3f 100644
--- a/perlio.h
+++ b/perlio.h
@@ -21,13 +21,7 @@
USE_PERLIO - The primary Configure variable that enables PerlIO.
If USE_PERLIO is _NOT_ set
then USE_STDIO above will be set to be conservative.
- If USE_PERLIO is set
- then there are two modes determined by USE_SFIO:
-
- USE_SFIO - If set causes PerlIO_xxx() to be #define-d onto sfio functions.
- A backward compatibility mode for some specialist applications.
-
- If USE_SFIO is not set then PerlIO_xxx() are real functions
+ PerlIO_xxx() are real functions
defined in perlio.c which implement extra functionality
required for utf8 support.
@@ -80,11 +74,6 @@
#ifdef PERLIO_IS_STDIO
/* #define PerlIO_xxxx() as equivalent stdio function */
#include "perlsdio.h"
-#else /* PERLIO_IS_STDIO */
-#ifdef USE_SFIO
-/* #define PerlIO_xxxx() as equivalent sfio function */
-#include "perlsfio.h"
-#endif /* USE_SFIO */
#endif /* PERLIO_IS_STDIO */
#ifndef PerlIO
diff --git a/perlsfio.h b/perlsfio.h
deleted file mode 100644
index 05c81a6fa4..0000000000
--- a/perlsfio.h
+++ /dev/null
@@ -1,83 +0,0 @@
-/* perlsfio.h
- *
- * Copyright (C) 1996, 1999, 2000, 2001, 2002, 2003, 2005, 2007,
- * by Larry Wall and others
- *
- * You may distribute under the terms of either the GNU General Public
- * License or the Artistic License, as specified in the README file.
- *
- */
-
-/* The next #ifdef should be redundant if Configure behaves ... */
-#ifndef FILE
-#define FILE FILE
-#endif
-#ifdef I_SFIO
-#include <sfio.h>
-#endif
-
-/* sfio 2000 changed _stdopen to _stdfdopen */
-#if SFIO_VERSION >= 20000101L
-#define _stdopen _stdfdopen
-#endif
-
-extern Sfio_t* _stdopen _ARG_((int, const char*));
-extern int _stdprintf _ARG_((const char*, ...));
-
-#define PerlIO Sfio_t
-#define PerlIO_stderr() sfstderr
-#define PerlIO_stdout() sfstdout
-#define PerlIO_stdin() sfstdin
-
-#define PerlIO_isutf8(f) 0
-
-#define PerlIO_printf sfprintf
-#define PerlIO_stdoutf _stdprintf
-#define PerlIO_vprintf(f,fmt,a) sfvprintf(f,fmt,a)
-#define PerlIO_read(f,buf,count) sfread(f,buf,count)
-#define PerlIO_write(f,buf,count) sfwrite(f,buf,count)
-#define PerlIO_open(path,mode) sfopen(NULL,path,mode)
-#define PerlIO_fdopen(fd,mode) _stdopen(fd,mode)
-#define PerlIO_reopen(path,mode,f) sfopen(f,path,mode)
-#define PerlIO_close(f) sfclose(f)
-#define PerlIO_puts(f,s) sfputr(f,s,-1)
-#define PerlIO_putc(f,c) sfputc(f,c)
-#define PerlIO_ungetc(f,c) sfungetc(f,c)
-#define PerlIO_getc(f) sfgetc(f)
-#define PerlIO_eof(f) sfeof(f)
-#define PerlIO_error(f) sferror(f)
-#define PerlIO_fileno(f) sffileno(f)
-#define PerlIO_clearerr(f) sfclrerr(f)
-#define PerlIO_flush(f) sfsync(f)
-#define PerlIO_tell(f) sftell(f)
-#define PerlIO_seek(f,o,w) sfseek(f,o,w)
-#define PerlIO_rewind(f) (void) sfseek((f),0L,0)
-#define PerlIO_tmpfile() sftmp(0)
-#define PerlIO_exportFILE(f,fl) Perl_croak(aTHX_ "Export to FILE * unimplemented")
-#define PerlIO_releaseFILE(p,f) Perl_croak(aTHX_ "Release of FILE * unimplemented")
-
-#define PerlIO_setlinebuf(f) sfset(f,SF_LINE,1)
-
-/* Now our interface to equivalent of Configure's FILE_xxx macros */
-
-#define PerlIO_has_cntptr(f) 1
-#define PerlIO_get_ptr(f) ((f)->next)
-#define PerlIO_get_cnt(f) ((f)->endr - (f)->next)
-#define PerlIO_canset_cnt(f) 1
-#define PerlIO_fast_gets(f) 1
-#define PerlIO_set_ptrcnt(f,p,c) STMT_START {(f)->next = (unsigned char *)(p); assert(PerlIO_get_cnt(f) == (c));} STMT_END
-#define PerlIO_set_cnt(f,c) STMT_START {(f)->next = (f)->endr - (c);} STMT_END
-
-#define PerlIO_has_base(f) 1
-#define PerlIO_get_base(f) ((f)->data)
-#define PerlIO_get_bufsiz(f) ((f)->endr - (f)->data)
-
-/*
- * Local variables:
- * c-indentation-style: bsd
- * c-basic-offset: 4
- * indent-tabs-mode: nil
- * End:
- *
- * ex: set ts=8 sts=4 sw=4 et:
- */
diff --git a/pod/perlapio.pod b/pod/perlapio.pod
index e130ed8fa0..a7f3cc879b 100644
--- a/pod/perlapio.pod
+++ b/pod/perlapio.pod
@@ -90,14 +90,7 @@ functions which call stdio. In this case I<only> PerlIO * is a FILE *.
This has been the default implementation since the abstraction was
introduced in perl5.003_02.
-=item 2. USE_SFIO
-
-A "legacy" implementation in terms of the "sfio" library. Used for
-some specialist applications on Unix machines ("sfio" is not widely
-ported away from Unix). Most of above are #define'd to the sfio
-functions. PerlIO * is in this case Sfio_t *.
-
-=item 3. USE_PERLIO
+=item 2. USE_PERLIO
Introduced just after perl5.7.0, this is a re-implementation of the
above abstraction which allows perl more control over how IO is done
diff --git a/pod/perlfunc.pod b/pod/perlfunc.pod
index 72b7c7ddec..69423d0b9d 100644
--- a/pod/perlfunc.pod
+++ b/pod/perlfunc.pod
@@ -7883,8 +7883,7 @@ on this.
Note that C<sysopen> depends on the fdopen() C library function.
On many Unix systems, fdopen() is known to fail when file descriptors
exceed a certain value, typically 255. If you need more file
-descriptors than that, consider rebuilding Perl to use the C<sfio>
-library, or perhaps using the POSIX::open() function.
+descriptors than that, consider using the POSIX::open() function.
See L<perlopentut> for a kinder, gentler explanation of opening files.
diff --git a/pod/perliol.pod b/pod/perliol.pod
index a1ac2f0f33..b01b10e6d2 100644
--- a/pod/perliol.pod
+++ b/pod/perliol.pod
@@ -10,8 +10,7 @@ perliol - C API for Perl's implementation of IO in Layers.
=head1 DESCRIPTION
This document describes the behavior and implementation of the PerlIO
-abstraction described in L<perlapio> when C<USE_PERLIO> is defined (and
-C<USE_SFIO> is not).
+abstraction described in L<perlapio> when C<USE_PERLIO> is defined.
=head2 History and Background
diff --git a/pp_ctl.c b/pp_ctl.c
index c06e796db3..74a5450567 100644
--- a/pp_ctl.c
+++ b/pp_ctl.c
@@ -3595,7 +3595,7 @@ S_check_type_and_open(pTHX_ SV *name)
return NULL;
}
-#if !defined(PERLIO_IS_STDIO) && !defined(USE_SFIO)
+#if !defined(PERLIO_IS_STDIO)
return PerlIO_openn(aTHX_ ":", PERL_SCRIPT_MODE, -1, 0, 0, NULL, 1, &name);
#else
return PerlIO_open(p, PERL_SCRIPT_MODE);
diff --git a/proto.h b/proto.h
index 6943041188..32dfa1a7df 100644
--- a/proto.h
+++ b/proto.h
@@ -7990,7 +7990,7 @@ PERL_CALLCONV char* Perl_sv_collxfrm_flags(pTHX_ SV *const sv, STRLEN *const nxp
assert(sv); assert(nxp)
#endif
-#if defined(USE_PERLIO) && !defined(USE_SFIO)
+#if defined(USE_PERLIO)
PERL_CALLCONV void Perl_PerlIO_clearerr(pTHX_ PerlIO *f);
PERL_CALLCONV int Perl_PerlIO_close(pTHX_ PerlIO *f);
PERL_CALLCONV int Perl_PerlIO_eof(pTHX_ PerlIO *f);
diff --git a/t/io/fflush.t b/t/io/fflush.t
index 4570f891b9..0bbfa545e6 100644
--- a/t/io/fflush.t
+++ b/t/io/fflush.t
@@ -19,12 +19,11 @@ use strict;
# it here too or expect test gratuitous test failures.
my $useperlio = defined $Config{useperlio} ? $Config{useperlio} eq 'define' ? 1 : 0 : 0;
my $fflushNULL = defined $Config{fflushNULL} ? $Config{fflushNULL} eq 'define' ? 1 : 0 : 0;
-my $d_sfio = defined $Config{d_sfio} ? $Config{d_sfio} eq 'define' ? 1 : 0 : 0;
my $fflushall = defined $Config{fflushall} ? $Config{fflushall} eq 'define' ? 1 : 0 : 0;
my $d_fork = defined $Config{d_fork} ? $Config{d_fork} eq 'define' ? 1 : 0 : 0;
skip_all('fflush(NULL) or equivalent not available')
- unless $useperlio || $fflushNULL || $d_sfio || $fflushall;
+ unless $useperlio || $fflushNULL || $fflushall;
plan(tests => 7);
diff --git a/t/io/pipe.t b/t/io/pipe.t
index 50d589dc85..fdd8b992bf 100644
--- a/t/io/pipe.t
+++ b/t/io/pipe.t
@@ -147,11 +147,10 @@ SKIP: {
if $^O eq 'VMS';
SKIP: {
- # Sfio doesn't report failure when closing a broken pipe
+ # POSIX-BC doesn't report failure when closing a broken pipe
# that has pending output. Go figure.
- # Nor does POSIX-BC.
skip "Won't report failure on broken pipe", 1
- if $Config{d_sfio} || $^O eq 'posix-bc';
+ if $^O eq 'posix-bc';
local $SIG{PIPE} = 'IGNORE';
open NIL, qq{|$Perl -e "exit 0"} or die "open failed: $!";
diff --git a/t/op/lfs.t b/t/op/lfs.t
index f06d19261c..acf9fe801f 100644
--- a/t/op/lfs.t
+++ b/t/op/lfs.t
@@ -1,4 +1,4 @@
-# NOTE: this file tests how large files (>2GB) work with perlio (stdio/sfio).
+# NOTE: this file tests how large files (>2GB) work with perlio (or stdio).
# sysopen(), sysseek(), syswrite(), sysread() are tested in t/lib/syslfs.t.
# If you modify/add tests here, remember to update also ext/Fcntl/t/syslfs.t.
diff --git a/t/op/sprintf.t b/t/op/sprintf.t
index 372ca90eb7..f4cbb49da6 100644
--- a/t/op/sprintf.t
+++ b/t/op/sprintf.t
@@ -389,8 +389,8 @@ __END__
>%.0f< >0< >0<
>%.0f< >2**38< >274877906944< >Should have exact int'l rep'n<
>%.0f< >0.1< >0<
->%.0f< >0.6< >1< >Known to fail with sfio, (irix|nonstop-ux|powerux); -DHAS_LDBL_SPRINTF_BUG may fix<
->%.0f< >-0.6< >-1< >Known to fail with sfio, (irix|nonstop-ux|powerux); -DHAS_LDBL_SPRINTF_BUG may fix<
+>%.0f< >0.6< >1< >Known to fail with (irix|nonstop-ux|powerux); -DHAS_LDBL_SPRINTF_BUG may fix<
+>%.0f< >-0.6< >-1< >Known to fail with (irix|nonstop-ux|powerux); -DHAS_LDBL_SPRINTF_BUG may fix<
>%.0f< >1.6< >2<
>%.0f< >-1.6< >-2<
>%.0f< >1< >1<
diff --git a/universal.c b/universal.c
index 110ab8d9cf..49ef0a43f3 100644
--- a/universal.c
+++ b/universal.c
@@ -29,7 +29,7 @@
#define PERL_IN_UNIVERSAL_C
#include "perl.h"
-#if defined(USE_PERLIO) && !defined(USE_SFIO)
+#if defined(USE_PERLIO)
#include "perliol.h" /* For the PERLIO_F_XXX */
#endif
@@ -1026,7 +1026,7 @@ XS(XS_PerlIO_get_layers)
dXSARGS;
if (items < 1 || items % 2 == 0)
croak_xs_usage(cv, "filehandle[,args]");
-#if defined(USE_PERLIO) && !defined(USE_SFIO)
+#if defined(USE_PERLIO)
{
SV * sv;
GV * gv;
diff --git a/util.c b/util.c
index 26a002abe7..e3059434ba 100644
--- a/util.c
+++ b/util.c
@@ -26,7 +26,7 @@
#include "perl.h"
#include "reentr.h"
-#if defined(USE_PERLIO) && !defined(USE_SFIO)
+#if defined(USE_PERLIO)
#include "perliol.h" /* For PerlIOUnix_refcnt */
#endif
@@ -1343,17 +1343,10 @@ Perl_write_to_stderr(pTHX_ SV* msv)
Perl_magic_methcall(aTHX_ MUTABLE_SV(io), mg, SV_CONST(PRINT),
G_SCALAR | G_DISCARD | G_WRITING_TO_STDERR, 1, msv);
else {
-#ifdef USE_SFIO
- /* SFIO can really mess with your errno */
- dSAVE_ERRNO;
-#endif
PerlIO * const serr = Perl_error_log;
do_print(msv, serr);
(void)PerlIO_flush(serr);
-#ifdef USE_SFIO
- RESTORE_ERRNO;
-#endif
}
}
@@ -2728,7 +2721,7 @@ Perl_my_pclose(pTHX_ PerlIO *ptr)
SvREFCNT_dec(*svp);
*svp = NULL;
-#if defined(USE_PERLIO) && !defined(USE_SFIO)
+#if defined(USE_PERLIO)
/* Find out whether the refcount is low enough for us to wait for the
child proc without blocking. */
should_wait = PerlIOUnix_refcnt(fd) == 1 && pid > 0;
@@ -3317,7 +3310,7 @@ Perl_get_vtbl(pTHX_ int vtbl_id)
I32
Perl_my_fflush_all(pTHX)
{
-#if defined(USE_PERLIO) || defined(FFLUSH_NULL) || defined(USE_SFIO)
+#if defined(USE_PERLIO) || defined(FFLUSH_NULL)
return PerlIO_flush(NULL);
#else
# if defined(HAS__FWALK)
diff --git a/win32/Makefile b/win32/Makefile
index c8aaea2b8c..a4a4e90cb7 100644
--- a/win32/Makefile
+++ b/win32/Makefile
@@ -748,7 +748,6 @@ CORE_NOCFG_H = \
..\perl.h \
..\perlapi.h \
..\perlsdio.h \
- ..\perlsfio.h \
..\perly.h \
..\pp.h \
..\proto.h \
diff --git a/win32/Makefile.ce b/win32/Makefile.ce
index 6a76da93d9..bdaeef5f48 100644
--- a/win32/Makefile.ce
+++ b/win32/Makefile.ce
@@ -702,7 +702,6 @@ CORE_NOCFG_H = \
..\perl.h \
..\perlapi.h \
..\perlsdio.h \
- ..\perlsfio.h \
..\perly.h \
..\pp.h \
..\proto.h \
diff --git a/win32/makefile.mk b/win32/makefile.mk
index c077544695..82599a8345 100644
--- a/win32/makefile.mk
+++ b/win32/makefile.mk
@@ -856,7 +856,6 @@ CORE_NOCFG_H = \
..\perl.h \
..\perlapi.h \
..\perlsdio.h \
- ..\perlsfio.h \
..\perly.h \
..\pp.h \
..\proto.h \
diff --git a/win32/win32.c b/win32/win32.c
index bf91b76226..c708439c7c 100644
--- a/win32/win32.c
+++ b/win32/win32.c
@@ -42,7 +42,7 @@
/* #include "config.h" */
-#if !defined(PERLIO_IS_STDIO) && !defined(USE_SFIO)
+#if !defined(PERLIO_IS_STDIO)
# define PerlIO FILE
#endif
diff --git a/win32/wince.c b/win32/wince.c
index 15d80f9083..63147cce3f 100644
--- a/win32/wince.c
+++ b/win32/wince.c
@@ -13,7 +13,7 @@
#define PERLIO_NOT_STDIO 0
-#if !defined(PERLIO_IS_STDIO) && !defined(USE_SFIO)
+#if !defined(PERLIO_IS_STDIO)
#define PerlIO FILE
#endif