Re: [Sofia-sip-devel] patch for iphone

2007-11-16 Thread Pekka Pessi
2007/11/6, Youness Alaoui [EMAIL PROTECTED]:
 Attached is a patch that will allow sofia-sip to compile correctly for
 the iPhone. The issue is that many files (20 files in total) are using
 printf/fprintf/etc.. without ever including stdio.h which is needed to
 use these functions. Apparently gcc by default includes that header or
 something, but with the toolchain for the iPhone it doesn't.

Thanks for the patch. I'll apply that.

 Also note that sofia-sip uses some functions from the
 SystemConfiguration framework when compiled on Mac OS X (iPhone), but
 the Makefile doesn't have a -framework SystemConfiguration option.
 This should be fixed too (not included in the attached patch). I fixed
 it by adding the -framework SystemConfiguration hardcoded into
 Makefile.in, but it should be fixed differently.

Is the option -framework SystemConfiguration niided in CFLAGS or
where? By the way, what kind of toolchain you are using with iPhone?

-- 
Pekka.Pessi mail at nokia.com

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Sofia-sip-devel mailing list
Sofia-sip-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sofia-sip-devel


Re: [Sofia-sip-devel] patch for iphone

2007-11-16 Thread Youness Alaoui
Pekka Pessi wrote:
 2007/11/6, Youness Alaoui [EMAIL PROTECTED]:
   
 Attached is a patch that will allow sofia-sip to compile correctly for
 the iPhone. The issue is that many files (20 files in total) are using
 printf/fprintf/etc.. without ever including stdio.h which is needed to
 use these functions. Apparently gcc by default includes that header or
 something, but with the toolchain for the iPhone it doesn't.
 

 Thanks for the patch. I'll apply that.

   
Thanks

 Also note that sofia-sip uses some functions from the
 SystemConfiguration framework when compiled on Mac OS X (iPhone), but
 the Makefile doesn't have a -framework SystemConfiguration option.
 This should be fixed too (not included in the attached patch). I fixed
 it by adding the -framework SystemConfiguration hardcoded into
 Makefile.in, but it should be fixed differently.
 

 Is the option -framework SystemConfiguration niided in CFLAGS or
 where? By the way, what kind of toolchain you are using with iPhone?

   
Oh sorry, forgot to mention that the option should be added to the LIBS 
variable. Below is the 'hacked' patch that adds the option to the right 
variable. It should just be moved into adding it from the configure 
instead of hardcoding it in the Makefile (only for Mac compilations and 
don't use 'uname' so that it works even when cross compiling) :

diff -ru sofia-sip-1.12.7.orig/libsofia-sip-ua/Makefile.in 
sofia-sip-1.12.7/libsofia-sip-ua/Makefile.in
--- sofia-sip-1.12.7.orig/libsofia-sip-ua/Makefile.in   2007-10-17 
07:03:32.0 -0400
+++ sofia-sip-1.12.7/libsofia-sip-ua/Makefile.in2007-10-26 
16:18:30.0 -0400
@@ -193,7 +193,7 @@
 LD = @LD@
 LDFLAGS = @LDFLAGS@
 LIBOBJS = @LIBOBJS@
-LIBS = @LIBS@
+LIBS = -framework SystemConfiguration @LIBS@
 LIBTOOL = @LIBTOOL@
 LIBVER_SOFIA_SIP_UA_AGE = @LIBVER_SOFIA_SIP_UA_AGE@
 LIBVER_SOFIA_SIP_UA_CUR = @LIBVER_SOFIA_SIP_UA_CUR@



I was using the iphone-dev team toolchain available at : 
http://code.google.com/p/iphone-dev/

Thanks,
Youness.

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Sofia-sip-devel mailing list
Sofia-sip-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sofia-sip-devel


[Sofia-sip-devel] patch for iphone

2007-11-09 Thread Youness Alaoui

Hi,

Attached is a patch that will allow sofia-sip to compile correctly for 
the iPhone. The issue is that many files (20 files in total) are using 
printf/fprintf/etc.. without ever including stdio.h which is needed to 
use these functions. Apparently gcc by default includes that header or 
something, but with the toolchain for the iPhone it doesn't.
Also note that sofia-sip uses some functions from the 
SystemConfiguration framework when compiled on Mac OS X (iPhone), but 
the Makefile doesn't have a -framework SystemConfiguration option. 
This should be fixed too (not included in the attached patch). I fixed 
it by adding the -framework SystemConfiguration hardcoded into 
Makefile.in, but it should be fixed differently.


Thank you,
Youness.

diff -ru sofia-sip-1.12.7.orig/libsofia-sip-ua/bnf/bnf.c sofia-sip-1.12.7/libsofia-sip-ua/bnf/bnf.c
--- sofia-sip-1.12.7.orig/libsofia-sip-ua/bnf/bnf.c	2007-10-08 08:39:26.0 -0400
+++ sofia-sip-1.12.7/libsofia-sip-ua/bnf/bnf.c	2007-10-24 21:48:26.0 -0400
@@ -35,6 +35,7 @@
 
 #include sofia-sip/bnf.h
 
+#include stdio.h
 #include assert.h
 
 #define wsbnf_ws
--
diff -ru sofia-sip-1.12.7.orig/libsofia-sip-ua/http/http_extra.c sofia-sip-1.12.7/libsofia-sip-ua/http/http_extra.c
--- sofia-sip-1.12.7.orig/libsofia-sip-ua/http/http_extra.c	2007-10-08 08:39:26.0 -0400
+++ sofia-sip-1.12.7/libsofia-sip-ua/http/http_extra.c	2007-10-24 21:55:36.0 -0400
@@ -33,6 +33,7 @@
 
 #include config.h
 
+#include stdio.h
 #include stddef.h
 #include stdlib.h
 #include string.h
--
diff -ru sofia-sip-1.12.7.orig/libsofia-sip-ua/ipt/token64.c sofia-sip-1.12.7/libsofia-sip-ua/ipt/token64.c
--- sofia-sip-1.12.7.orig/libsofia-sip-ua/ipt/token64.c	2007-10-08 08:39:26.0 -0400
+++ sofia-sip-1.12.7/libsofia-sip-ua/ipt/token64.c	2007-10-24 21:48:45.0 -0400
@@ -33,6 +33,7 @@
 
 #include config.h
 
+#include stdio.h
 #include stddef.h
 #include assert.h
 
--
diff -ru sofia-sip-1.12.7.orig/libsofia-sip-ua/iptsec/auth_common.c sofia-sip-1.12.7/libsofia-sip-ua/iptsec/auth_common.c
--- sofia-sip-1.12.7.orig/libsofia-sip-ua/iptsec/auth_common.c	2007-10-08 08:39:26.0 -0400
+++ sofia-sip-1.12.7/libsofia-sip-ua/iptsec/auth_common.c	2007-10-24 21:56:34.0 -0400
@@ -37,6 +37,7 @@
 #include sofia-sip/auth_common.h
 #include sofia-sip/msg_header.h
 
+#include stdio.h
 #include string.h
 #include stdarg.h
 #include assert.h
--
diff -ru sofia-sip-1.12.7.orig/libsofia-sip-ua/iptsec/auth_digest.c sofia-sip-1.12.7/libsofia-sip-ua/iptsec/auth_digest.c
--- sofia-sip-1.12.7.orig/libsofia-sip-ua/iptsec/auth_digest.c	2007-10-08 08:39:26.0 -0400
+++ sofia-sip-1.12.7/libsofia-sip-ua/iptsec/auth_digest.c	2007-10-24 21:56:58.0 -0400
@@ -41,6 +41,7 @@
 
 #include iptsec_debug.h
 
+#include stdio.h
 #include string.h
 #include stdarg.h
 #include limits.h
--
diff -ru sofia-sip-1.12.7.orig/libsofia-sip-ua/msg/msg_auth.c sofia-sip-1.12.7/libsofia-sip-ua/msg/msg_auth.c
--- sofia-sip-1.12.7.orig/libsofia-sip-ua/msg/msg_auth.c	2007-10-08 08:39:26.0 -0400
+++ sofia-sip-1.12.7/libsofia-sip-ua/msg/msg_auth.c	2007-10-24 21:49:39.0 -0400
@@ -35,6 +35,7 @@
 
 #include config.h
 
+#include stdio.h
 #include stddef.h
 #include stdlib.h
 #include string.h
--
diff -ru sofia-sip-1.12.7.orig/libsofia-sip-ua/sip/sip_event.c sofia-sip-1.12.7/libsofia-sip-ua/sip/sip_event.c
--- sofia-sip-1.12.7.orig/libsofia-sip-ua/sip/sip_event.c	2007-10-08 08:39:27.0 -0400
+++ sofia-sip-1.12.7/libsofia-sip-ua/sip/sip_event.c	2007-10-24 21:53:54.0 -0400
@@ -41,6 +41,7 @@
 
 #include sofia-sip/sip_parser.h
 
+#include stdio.h
 #include stddef.h
 #include stdlib.h
 #include string.h
--
diff -ru sofia-sip-1.12.7.orig/libsofia-sip-ua/sip/sip_extra.c sofia-sip-1.12.7/libsofia-sip-ua/sip/sip_extra.c
--- sofia-sip-1.12.7.orig/libsofia-sip-ua/sip/sip_extra.c	2007-10-08 08:39:27.0 -0400
+++ sofia-sip-1.12.7/libsofia-sip-ua/sip/sip_extra.c	2007-10-24 21:51:07.0 -0400
@@ -43,6 +43,7 @@
 #include sofia-sip/sip_parser.h
 #include sofia-sip/sip_extra.h
 
+#include stdio.h
 #include stddef.h
 #include stdlib.h
 #include string.h
--
diff -ru sofia-sip-1.12.7.orig/libsofia-sip-ua/sip/sip_feature.c sofia-sip-1.12.7/libsofia-sip-ua/sip/sip_feature.c
--- sofia-sip-1.12.7.orig/libsofia-sip-ua/sip/sip_feature.c	2007-10-08 08:39:27.0 -0400
+++ sofia-sip-1.12.7/libsofia-sip-ua/sip/sip_feature.c	2007-10-24 21:51:33.0 -0400
@@ -39,6 +39,7 @@
 
 #include sofia-sip/sip_parser.h
 
+#include stdio.h
 #include stddef.h
 #include stdlib.h
 #include string.h
--
diff -ru sofia-sip-1.12.7.orig/libsofia-sip-ua/sip/sip_mime.c sofia-sip-1.12.7/libsofia-sip-ua/sip/sip_mime.c
--- sofia-sip-1.12.7.orig/libsofia-sip-ua/sip/sip_mime.c	2007-10-08 08:39:27.0 -0400
+++ sofia-sip-1.12.7/libsofia-sip-ua/sip/sip_mime.c	2007-10-24 21:52:43.0 -0400
@@ -40,6 +40,7 @@
 #include sofia-sip/sip_parser.h
 #include sofia-sip/msg_mime_protos.h
 
+#include