summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMikael Hallendal <micke@codefactory.se>2002-01-26 16:18:05 +0000
committerMikael Hallendal <hallski@src.gnome.org>2002-01-26 16:18:05 +0000
commit8553436fea12fdb7a22e9c51224b5790cf3379ba (patch)
treeb7e5668454948293ef73544cf0d807034f2295f2
parent9b3e23e0cc1382bcf9b38af4fd71397ac70316e9 (diff)
downloadyelp-8553436fea12fdb7a22e9c51224b5790cf3379ba.tar.gz
Thanks to Laszlo PETER <Laszlo.Peter@ireland.sun.com> for the following
2002-01-26 Mikael Hallendal <micke@codefactory.se> * Thanks to Laszlo PETER <Laszlo.Peter@ireland.sun.com> for the following patches. * src/yelp-view-toc.c: (yelp_view_toc_write_header): buildfixes when not using gcc. (yelp_view_toc_start): dito * src/yelp-html.c: build fixes when not using glibc. * configure.in: make yelp build with other compilers than GCC.
-rw-r--r--ChangeLog11
-rw-r--r--configure.in4
-rw-r--r--src/yelp-html.c16
-rw-r--r--src/yelp-view-toc.c54
4 files changed, 48 insertions, 37 deletions
diff --git a/ChangeLog b/ChangeLog
index 700e26fb..166093d7 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,16 @@
2002-01-26 Mikael Hallendal <micke@codefactory.se>
+ * Thanks to Laszlo PETER <Laszlo.Peter@ireland.sun.com> for the
+ following patches.
+
+ * src/yelp-view-toc.c:
+ (yelp_view_toc_write_header): buildfixes when not using gcc.
+ (yelp_view_toc_start): dito
+
+ * src/yelp-html.c: build fixes when not using glibc.
+
+ * configure.in: make yelp build with other compilers than GCC.
+
* src/yelp-window.c:
- Fixed history
(yw_handle_url): added, broke out code from
diff --git a/configure.in b/configure.in
index a5e51b6b..37234dc1 100644
--- a/configure.in
+++ b/configure.in
@@ -19,7 +19,9 @@ AM_PATH_GLIB_2_0
dnl NOTE : it appears that some systems do not like it when you use line
dnl continuation charactes to split CFLAGS into readable chunks
-CFLAGS="$CFLAGS -Wall -Wno-uninitialized -Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wno-sign-compare -Wsign-promo"
+if test "x$GCC" = "xyes"; then
+ CFLAGS="$CFLAGS -Wall -Wno-uninitialized -Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wno-sign-compare -Wsign-promo"
+fi
AC_SUBST(CFLAGS)
AC_SUBST(LDFLAGS)
diff --git a/src/yelp-html.c b/src/yelp-html.c
index dce77108..31f8d718 100644
--- a/src/yelp-html.c
+++ b/src/yelp-html.c
@@ -160,7 +160,7 @@ yh_async_close_cb (GnomeVFSAsyncHandle *handle,
{
StreamData *sdata;
- d(puts(__FUNCTION__));
+ d(puts(G_GNUC_FUNCTION));
sdata = (StreamData *) callback_data;
@@ -182,7 +182,7 @@ yh_async_read_cb (GnomeVFSAsyncHandle *handle,
{
StreamData *sdata;
- d(puts(__FUNCTION__));
+ d(puts(G_GNUC_FUNCTION));
sdata = (StreamData *) callback_data;
@@ -207,7 +207,7 @@ yh_async_open_cb (GnomeVFSAsyncHandle *handle,
{
StreamData *sdata;
- d(puts(__FUNCTION__));
+ d(puts(G_GNUC_FUNCTION));
sdata = (StreamData *) callback_data;
@@ -238,7 +238,7 @@ yh_url_requested_cb (HtmlDocument *doc,
GnomeVFSURI *vfs_uri;
StreamData *sdata;
- d(puts(__FUNCTION__));
+ d(puts(G_GNUC_FUNCTION));
view = YELP_HTML (data);
priv = view->priv;
@@ -292,7 +292,7 @@ yh_stream_cancel (HtmlStream *stream,
{
StreamData *sdata = (StreamData *)cancel_data;
- d(puts(__FUNCTION__));
+ d(puts(G_GNUC_FUNCTION));
gnome_vfs_async_cancel (sdata->handle);
@@ -304,7 +304,7 @@ yh_free_stream_data (StreamData *sdata, gboolean remove)
{
YelpHtmlPriv *priv;
- d(puts(__FUNCTION__));
+ d(puts(G_GNUC_FUNCTION));
priv = sdata->view->priv;
@@ -351,7 +351,7 @@ yelp_html_new (void)
{
YelpHtml *view;
- d(puts(__FUNCTION__));
+ d(puts(G_GNUC_FUNCTION));
view = g_object_new (YELP_TYPE_HTML, NULL);
@@ -378,7 +378,7 @@ yelp_html_open_section (YelpHtml *view, const YelpSection *section)
GnomeVFSURI *uri;
const char *fragment;
- d(puts(__FUNCTION__));
+ d(puts(G_GNUC_FUNCTION));
g_return_if_fail (YELP_IS_HTML (view));
g_return_if_fail (section != NULL);
diff --git a/src/yelp-view-toc.c b/src/yelp-view-toc.c
index cb927505..15548e73 100644
--- a/src/yelp-view-toc.c
+++ b/src/yelp-view-toc.c
@@ -184,20 +184,20 @@ yelp_view_toc_printf (YelpViewTOC *view, char *format, ...)
static void
yelp_view_toc_write_header (YelpViewTOC *view, char *title)
{
- char *header="
-<html>
- <head>
- <title>
- %s
- </title>
- <style type=\"text/css\">
- A:link { color: #00008b }
- A:visited { color: #00008b }
- A:active { color: #00008b }
- BODY { color: #00008b }
- </style>
- </head>
- <body bgcolor=\"#ffffff\">";
+ char *header="\n"
+"<html>\n"
+" <head>\n"
+" <title>\n"
+" %s\n"
+" </title> \n"
+" <style type=\"text/css\">\n"
+" A:link { color: #00008b }\n"
+" A:visited { color: #00008b }\n"
+" A:active { color: #00008b }\n"
+" BODY { color: #00008b }\n"
+" </style>\n"
+" </head>\n"
+" <body bgcolor=\"#ffffff\">";
char *s;
s = g_strdup_printf (header, title);
@@ -210,10 +210,9 @@ yelp_view_toc_write_header (YelpViewTOC *view, char *title)
static void
yelp_view_toc_write_footer (YelpViewTOC *view)
{
- char *footer="
- </body>
-</html>
-";
+ char *footer="\n"
+" </body>\n"
+"</html>\n";
yelp_view_toc_write (view, footer, -1);
}
@@ -224,15 +223,14 @@ yelp_view_toc_start (YelpViewTOC *view)
YelpViewTOCPriv *priv;
GNode *node;
YelpSection *section;
- gchar *table_start = "
- <center>
- <table cellspacing=\"20\" width=\"100%\">
- <tr>";
- gchar *table_end = "
- </tr>
- </table>
- </center>
-";
+ gchar *table_start = "\n"
+" <center>\n"
+" <table cellspacing=\"20\" width=\"100%\">\n"
+" <tr>\n";
+ gchar *table_end = "\n"
+" </tr>\n"
+" </table>\n"
+" </center>\n";
char *seriesid;
GNode *root;
char *path;
@@ -369,7 +367,7 @@ yelp_view_toc_man_emit (YelpViewTOC *view, GNode *first)
if (got_a_leaf) {
yelp_view_toc_write (view,
- "<table cellpadding=\"2\" cellspacing=\"2\" border=\"0\" width=\"100\%\"><tbody>\n",
+ "<table cellpadding=\"2\" cellspacing=\"2\" border=\"0\" width=\"100%%\"><tbody>\n",
-1);
i = 0;