--- dos2unix.c.orig +++ dos2unix.c @@ -158,8 +158,8 @@ #define R_CNTRL "rb" #define W_CNTRL "wb" #else - #define R_CNTRL "r" - #define W_CNTRL "w" + #define R_CNTRL "re" + #define W_CNTRL "we" #endif #define BINARY_FILE 0x1 --- unix2dos.c.orig +++ unix2dos.c @@ -148,8 +148,8 @@ #define R_CNTRL "rb" #define W_CNTRL "wb" #else - #define R_CNTRL "r" - #define W_CNTRL "w" + #define R_CNTRL "re" + #define W_CNTRL "we" #endif #define BINARY_FILE 0x1 --- Makefile.orig +++ Makefile @@ -198,7 +198,7 @@ endif CFLAGS = -O2 -Wall $(RPM_OPT_FLAGS) -EXTRA_CFLAGS = -DVER_REVISION=\"$(DOS2UNIX_VERSION)\" \ +EXTRA_CFLAGS = -D_GNU_SOURCE -DVER_REVISION=\"$(DOS2UNIX_VERSION)\" \ -DVER_DATE=\"$(DOS2UNIX_DATE)\" \ -DDEBUG=$(DEBUG) \ $(CFLAGS_OS)