Skip to content

Commit

Permalink
Remove all glib dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
james_rich committed Mar 8, 2005
1 parent b760db1 commit dfab4de
Show file tree
Hide file tree
Showing 27 changed files with 757 additions and 743 deletions.
3 changes: 3 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
2005-03-06 James Rich <[email protected]>
- Removed glib dependancies

2005-02-24 James Rich <[email protected]>
- Added more descriptive comments to tn5250_session_query_reply().
- Changed tn5250_terminal_enhanced() to return 0 if NULL as suggested by
Expand Down
18 changes: 1 addition & 17 deletions README
Original file line number Diff line number Diff line change
Expand Up @@ -35,23 +35,6 @@ You may receive an error the first time you run this script. If so, run
the script a second time to make sure you don't get an error (this is a bug
with automake).

Glib Dependency
===============

Versions 0.17.x and up also require a developers version of glib to be
installed. On Linux, this means that you have to install the glib-devel
package. On FreeBSD, you need to install the glib12 port. (from the ports
collection)

On FreeBSD (and possibly some other systems) the "glib-config" script is
installed as "glib12-config". To allow tn5250 to find it, you need to set
the GLIB_CONFIG environment variable.

For example, a csh/tcsh user might type:
setenv GLIB_CONFIG /usr/local/bin/glib12-config
or under sh/bash:
export GLIB_CONFIG=/usr/local/bin/glib12-config


Building and Installing
=======================
Expand Down Expand Up @@ -95,6 +78,7 @@ http://www.midrange.com/linux5250.shtml - linux5250 List Info
http://archive.midrange.com/linux5250/index.htm - linux5250 List Archives
http://sourceforge.net/projects/tn5250/ - linux5250 at Sourceforge
http://perso.libertysurf.fr/plinux/tn5250-faq.html - linux5250 FAQ
http://www.chowhouse.com/~james/tn5250-HOWTO.pdf - linux5250 HOWTO

Comments, questions, bug reports and patches are much appreciated - please
subscribe to the list and post them there if at all possible. If that's too
Expand Down
5 changes: 0 additions & 5 deletions configure.in
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,6 @@ AC_ARG_ENABLE(old-keys,
AC_DEFINE_UNQUOTED(USE_OWN_KEY_PARSING,1)
])

dnl *
dnl * This version of TN5250 depends on GLIB 2.0
dnl *
AM_PATH_GLIB_2_0

dnl **************************************************************************
dnl * Python interface support. *
dnl **************************************************************************
Expand Down
6 changes: 3 additions & 3 deletions src/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@ lib5250_la_SOURCES = buffer.c\
macro.c\
window.c

lib5250_la_LIBADD = @with_extra_libs@ @GLIB_LIBS@
lib5250_la_LIBADD = @with_extra_libs@

INCLUDES = @GLIB_CFLAGS@ @PYTHON_CFLAGS@ \
INCLUDES = @PYTHON_CFLAGS@ \
-DSYSCONFDIR=\"$(sysconfdir)\"

# Here's where we build the python module.
Expand All @@ -46,7 +46,7 @@ pyso_LTLIBRARIES = libtn5250module.la
# just add all the SOURCES (sigh).
# libtn5250module_la_LIBADD = lib5250.la

libtn5250module_la_LIBADD = @with_exra_libs@ @GLIB_LIBS@
libtn5250module_la_LIBADD = @with_exra_libs@

libtn5250module_la_SOURCES = tn5250-python.c\
$(lib5250_la_SOURCES)
Expand Down
6 changes: 3 additions & 3 deletions src/buffer.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ void tn5250_buffer_init(Tn5250Buffer * This)
void tn5250_buffer_free(Tn5250Buffer * This)
{
if (This->data != NULL)
g_free(This->data);
free(This->data);
This->data = NULL;
This->len = This->allocated = 0;
}
Expand All @@ -75,10 +75,10 @@ void tn5250_buffer_append_byte(Tn5250Buffer * This, unsigned char b)
if (This->len + 1 >= This->allocated) {
if (This->data == NULL) {
This->allocated = BUFFER_DELTA;
This->data = (unsigned char *) g_malloc(This->allocated);
This->data = (unsigned char *) malloc(This->allocated);
} else {
This->allocated += BUFFER_DELTA;
This->data = (unsigned char *) g_realloc(This->data, This->allocated);
This->data = (unsigned char *) realloc(This->data, This->allocated);
}
}
TN5250_ASSERT (This->data != NULL);
Expand Down
Loading

0 comments on commit dfab4de

Please sign in to comment.