[packages/aep1000] - adjusted make patch to support Linux 3.x .. 5.x and drop unnecessary -lnsl - added format patch -

qboosh qboosh at pld-linux.org
Mon Aug 31 17:07:10 CEST 2020


commit c6504b7446a0b141ed8c4ff2028f3750a026daf0
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Mon Aug 31 17:09:42 2020 +0200

    - adjusted make patch to support Linux 3.x .. 5.x and drop unnecessary -lnsl
    - added format patch
    - release 2

 aep1000-format.patch | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 aep1000-make.patch   | 24 +++++++++++++----------
 aep1000.spec         |  4 +++-
 3 files changed, 71 insertions(+), 11 deletions(-)
---
diff --git a/aep1000.spec b/aep1000.spec
index 7e2c0e1..619dd12 100644
--- a/aep1000.spec
+++ b/aep1000.spec
@@ -2,7 +2,7 @@ Summary:	Utilities for AEP1000 SSL Accelerator
 Summary(pl.UTF-8):	Narzędzia dla akceleratora AEP1000 SSL Accelerator
 Name:		aep1000
 Version:	2.1
-Release:	1
+Release:	2
 License:	BSD
 Group:		Applications/System
 Source0:	aep_host_sw.tar.gz
@@ -11,6 +11,7 @@ Source1:	aeptarg.bin
 # Source1-md5:	dc6e1cadea20006fc9e3f457b23d32c5
 Patch0:		%{name}-redhat.patch
 Patch1:		%{name}-make.patch
+Patch2:		%{name}-format.patch
 Requires:	%{name}-libs = %{version}-%{release}
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -59,6 +60,7 @@ Statyczna biblioteka AEP.
 %setup -q -c
 %patch0 -p0
 %patch1 -p0
+%patch2 -p1
 
 %build
 cd Host
diff --git a/aep1000-format.patch b/aep1000-format.patch
new file mode 100644
index 0000000..861abbc
--- /dev/null
+++ b/aep1000-format.patch
@@ -0,0 +1,54 @@
+--- aep1000-2.1/Host/API/aeptrace.c.orig	2001-10-18 17:29:58.000000000 +0200
++++ aep1000-2.1/Host/API/aeptrace.c	2020-08-31 06:37:01.811150729 +0200
+@@ -53,6 +53,7 @@
+ 
+ #include <stdio.h>
+ #include <stdarg.h>
++#include <stdlib.h>
+ #include <time.h>
+ #include <string.h>
+ #include <sys/types.h>
+@@ -458,14 +459,14 @@
+ 
+ 	/* If log is to be written to console -print it*/
+ 	if(TRACE_OPTIONS[STREAM_OUTPUT_ENABLED].Status == ON)
+-		printf(buffer);	
++		fputs(buffer, stdout);	
+ 	/* If log is to be written to file */
+ 	if(subsysLogfile != NULL)
+ 	{
+ 		if(TRACE_OPTIONS[FILE_OUTPUT_ENABLED].Status == ON)
+ 		{
+ 			/* Write buffer to file */
+-			fprintf(SUBSYS_LOG , (AEP_CHAR_PTR)buffer);	
++			fputs((AEP_CHAR_PTR)buffer, SUBSYS_LOG);	
+ 			/* Close file */
+ 			fclose(SUBSYS_LOG);
+ 		}	
+--- aep1000-2.1/Host/Daemon/aeptrace.c.orig	2001-10-18 17:29:58.000000000 +0200
++++ aep1000-2.1/Host/Daemon/aeptrace.c	2020-08-31 06:37:01.811150729 +0200
+@@ -53,6 +53,7 @@
+ 
+ #include <stdio.h>
+ #include <stdarg.h>
++#include <stdlib.h>
+ #include <time.h>
+ #include <string.h>
+ #include <sys/types.h>
+@@ -458,14 +459,14 @@
+ 
+ 	/* If log is to be written to console -print it*/
+ 	if(TRACE_OPTIONS[STREAM_OUTPUT_ENABLED].Status == ON)
+-		printf(buffer);	
++		fputs(buffer, stdout);	
+ 	/* If log is to be written to file */
+ 	if(subsysLogfile != NULL)
+ 	{
+ 		if(TRACE_OPTIONS[FILE_OUTPUT_ENABLED].Status == ON)
+ 		{
+ 			/* Write buffer to file */
+-			fprintf(SUBSYS_LOG , (AEP_CHAR_PTR)buffer);	
++			fputs((AEP_CHAR_PTR)buffer, SUBSYS_LOG);	
+ 			/* Close file */
+ 			fclose(SUBSYS_LOG);
+ 		}	
diff --git a/aep1000-make.patch b/aep1000-make.patch
index 7cd560e..abbdfc5 100644
--- a/aep1000-make.patch
+++ b/aep1000-make.patch
@@ -5,7 +5,7 @@
  	# Linux     2.4.*    gcc 
  	#------------------------------ 
 -	Linux:2.4.*:gcc) 
-+	Linux:2.[46].*:gcc) 
++	Linux:2.[46].*:gcc|Linux:[345].*:gcc)
  		cflags="-Wall -I../h  -I../Daemon/h -I../API/h  -I../../common  ${ENDIAN_FLAG} ${BITS_FLAG} -D_REENTRANT -fPIC" 
  		ldflags="-lpthread -L. -L../API -laep" 
  	;; 
@@ -31,13 +31,13 @@
  	# Linux     2.4.*    gcc
  	#------------------------------
 -	Linux:2.4.*:gcc)
-+	Linux:2.[46].*:gcc)
++	Linux:2.[46].*:gcc|Linux:[345].*:gcc)
  		TARGET="libaep.so.1"
  		cflags="-Wall -I../h  -I./h   -I../../common ${ENDIAN_FLAG} ${BITS_FLAG} -D_REENTRANT -fPIC"
  		ldflags="-shared -O-no-undefined -Wl,-soname=${TARGET}"
---- Host/Daemon/make.conf.orig	2007-09-02 23:35:03.856667000 +0200
-+++ Host/Daemon/make.conf	2007-09-03 00:11:45.838151035 +0200
-@@ -126,10 +126,13 @@ ENDIAN_FLAG="-DL_ENDIAN"
+--- Host/Daemon/make.conf.orig	2020-08-31 06:43:42.438980342 +0200
++++ Host/Daemon/make.conf	2020-08-31 06:49:33.497078497 +0200
+@@ -126,10 +126,13 @@
  BITS_FLAG="-D_32BIT"
  
  case ${MACHINE} in 
@@ -52,15 +52,19 @@
  	sun4*)
  		ENDIAN_FLAG="-DB_ENDIAN"
  		ISA=`(isainfo) 2>/dev/null`
-@@ -178,7 +181,7 @@ case "${PLATFORM}:${RELEASE}:${CMPLR}" i
+@@ -178,10 +181,10 @@
  	#------------------------------
  	# Linux     2.4.*    gcc
  	#------------------------------
 -	Linux:2.4.*:gcc)
-+	Linux:2.[46].*:gcc)
++	Linux:2.[46].*:gcc|Linux:[345].*:gcc)
  		TARGET="aepdaemon"
  		cflags="-Wall -I../h  -I./h   -I../../common ${ENDIAN_FLAG} ${BITS_FLAG} -D_REENTRANT -fPIC"
- 		ldflags="-lpthread -lnsl -lrt"
+-		ldflags="-lpthread -lnsl -lrt"
++		ldflags="-lpthread"
+ 	;;
+ 
+ 	#------------------------------
 --- Host/Test/quicktest/make.conf.orig	2007-09-02 23:35:03.856667000 +0200
 +++ Host/Test/quicktest/make.conf	2007-09-03 00:12:27.744539144 +0200
 @@ -177,7 +177,7 @@ case "${PLATFORM}:${RELEASE}:${CMPLR}" i
@@ -68,7 +72,7 @@
          # Linux     2.4.*    gcc
          #------------------------------
 -        Linux:2.4.*:gcc)
-+        Linux:2.[46].*:gcc)
++        Linux:2.[46].*:gcc|Linux:[345].*:gcc)
                  cflags="-Wall -I./h -I../../h ${ENDIAN_FLAG} ${BITS_FLAG} -D_REENTRANT -fPIC"
                  ldflags="-lpthread -L. -L../../API -laep"
          ;;
@@ -79,7 +83,7 @@
          # Linux     2.4.*    gcc
          #------------------------------
 -        Linux:2.4.*:gcc)
-+        Linux:2.[46].*:gcc)
++        Linux:2.[46].*:gcc|Linux:[345].*:gcc)
                  cflags=" -Wall -I../h -I./h ${ENDIAN_FLAG} ${BITS_FLAG} -D_REENTRANT -fPIC"
                  ldflags="-lpthread -L. -L../API -laep"
          ;;
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/aep1000.git/commitdiff/c6504b7446a0b141ed8c4ff2028f3750a026daf0



More information about the pld-cvs-commit mailing list