Commit dafdffd7 authored by Matthias Clasen's avatar Matthias Clasen Committed by Matthias Clasen

Implement the same PLT reduction technique used in GTK+:

Thu Sep 16 02:03:15 2004  Matthias Clasen  <maclas@gmx.de>

	Implement the same PLT reduction technique used in GTK+:
parent e0811a5e
Thu Sep 16 02:03:15 2004 Matthias Clasen <maclas@gmx.de>
Implement the same PLT reduction technique used in GTK+:
* glib/glib.symbols: Master list of symbols
* glib/makegalias.pl: Perl script which creates galias.h
* glib/abicheck.sh: Compares actual exports against glib.symbols
* glib/glib.def: Removed. This file is now generated from
glib.symbols
* glib/Makefile.am: Add rules to generate galias.h and glib.def,
and add abicheck.sh to TESTS. Don't export _-prefixed symbols.
* configure.in: Add --disable-visibility to suppress the
use of ELF visibility attributes.
* glib/*.c: Include galias.h
2004-09-15 Tor Lillqvist <tml@iki.fi>
* glib/gwin32.c (g_win32_error_message): Convert message to
......
Thu Sep 16 02:03:15 2004 Matthias Clasen <maclas@gmx.de>
Implement the same PLT reduction technique used in GTK+:
* glib/glib.symbols: Master list of symbols
* glib/makegalias.pl: Perl script which creates galias.h
* glib/abicheck.sh: Compares actual exports against glib.symbols
* glib/glib.def: Removed. This file is now generated from
glib.symbols
* glib/Makefile.am: Add rules to generate galias.h and glib.def,
and add abicheck.sh to TESTS. Don't export _-prefixed symbols.
* configure.in: Add --disable-visibility to suppress the
use of ELF visibility attributes.
* glib/*.c: Include galias.h
2004-09-15 Tor Lillqvist <tml@iki.fi>
* glib/gwin32.c (g_win32_error_message): Convert message to
......
Thu Sep 16 02:03:15 2004 Matthias Clasen <maclas@gmx.de>
Implement the same PLT reduction technique used in GTK+:
* glib/glib.symbols: Master list of symbols
* glib/makegalias.pl: Perl script which creates galias.h
* glib/abicheck.sh: Compares actual exports against glib.symbols
* glib/glib.def: Removed. This file is now generated from
glib.symbols
* glib/Makefile.am: Add rules to generate galias.h and glib.def,
and add abicheck.sh to TESTS. Don't export _-prefixed symbols.
* configure.in: Add --disable-visibility to suppress the
use of ELF visibility attributes.
* glib/*.c: Include galias.h
2004-09-15 Tor Lillqvist <tml@iki.fi>
* glib/gwin32.c (g_win32_error_message): Convert message to
......
Thu Sep 16 02:03:15 2004 Matthias Clasen <maclas@gmx.de>
Implement the same PLT reduction technique used in GTK+:
* glib/glib.symbols: Master list of symbols
* glib/makegalias.pl: Perl script which creates galias.h
* glib/abicheck.sh: Compares actual exports against glib.symbols
* glib/glib.def: Removed. This file is now generated from
glib.symbols
* glib/Makefile.am: Add rules to generate galias.h and glib.def,
and add abicheck.sh to TESTS. Don't export _-prefixed symbols.
* configure.in: Add --disable-visibility to suppress the
use of ELF visibility attributes.
* glib/*.c: Include galias.h
2004-09-15 Tor Lillqvist <tml@iki.fi>
* glib/gwin32.c (g_win32_error_message): Convert message to
......
Thu Sep 16 02:03:15 2004 Matthias Clasen <maclas@gmx.de>
Implement the same PLT reduction technique used in GTK+:
* glib/glib.symbols: Master list of symbols
* glib/makegalias.pl: Perl script which creates galias.h
* glib/abicheck.sh: Compares actual exports against glib.symbols
* glib/glib.def: Removed. This file is now generated from
glib.symbols
* glib/Makefile.am: Add rules to generate galias.h and glib.def,
and add abicheck.sh to TESTS. Don't export _-prefixed symbols.
* configure.in: Add --disable-visibility to suppress the
use of ELF visibility attributes.
* glib/*.c: Include galias.h
2004-09-15 Tor Lillqvist <tml@iki.fi>
* glib/gwin32.c (g_win32_error_message): Convert message to
......
......@@ -149,6 +149,7 @@ case "$host" in
esac
AC_MSG_RESULT([$glib_native_win32])
AM_CONDITIONAL(OS_WIN32, [test "$glib_native_win32" = "yes"])
AM_CONDITIONAL(OS_UNIX, [test "$glib_native_win32" != "yes"])
AC_SUBST(G_LIB_WIN32_RESOURCE)
AC_SUBST(G_MODULE_WIN32_RESOURCE)
AC_SUBST(G_OBJECT_WIN32_RESOURCE)
......@@ -164,6 +165,16 @@ if test "$glib_native_win32" = "yes"; then
fi
AM_CONDITIONAL(MS_LIB_AVAILABLE, [test x$ms_librarian = xyes])
if test "$glib_native_win32" != yes; then
# libtool option to control which symbols are exported
# right now, symbols starting with _ are not exported
LIBTOOL_EXPORT_OPTIONS='-export-symbols-regex "^[[^_]].*"'
else
# We currently use .def files on Windows
LIBTOOL_EXPORT_OPTIONS=
fi
AC_SUBST(LIBTOOL_EXPORT_OPTIONS)
dnl declare --enable-* args and collect ac_help strings
AC_ARG_ENABLE(debug,
AC_HELP_STRING([--enable-debug=@<:@no/minimum/yes@:>@],
......@@ -191,6 +202,10 @@ AC_ARG_ENABLE(rebuilds,
[AC_HELP_STRING([--disable-rebuilds],
[disable all source autogeneration rules])],,
[enable_rebuilds=yes])
AC_ARG_ENABLE(visibility,
[AC_HELP_STRING([--disable-visibility],
[don't use ELF visibility attributes])],,
[enable_visibility=yes])
if test "x$enable_threads" != "xyes"; then
enable_threads=no
......@@ -275,6 +290,10 @@ else
fi
fi
if test "x$enable_visibility" = "xno"; then
GLIB_DEBUG_FLAGS="$GLIB_DEBUG_FLAGS -DDISABLE_VISIBILITY"
fi
# Ensure MSVC-compatible struct packing convention is used when
# compiling for Win32 with gcc.
# What flag to depends on gcc version: gcc3 uses "-mms-bitfields", while
......
......@@ -13,16 +13,31 @@ DIST_SUBDIRS = libcharset gnulib
INCLUDES = -I$(top_srcdir) -DG_LOG_DOMAIN=\"GLib\" \
$(GLIB_DEBUG_FLAGS) -DG_DISABLE_DEPRECATED -DGLIB_COMPILATION
glib.def: glib.symbols
(echo -e EXPORTS; cpp -P -DINCLUDE_VARIABLES -DINCLUDE_INTERNAL_SYMBOLS -DG_OS_WIN32 $(srcdir)/glib.symbols | sed -e '/^$$/d' -e 's/^/\t/') > glib.def
galias.h: glib.symbols
./makegalias.pl < $(srcdir)/glib.symbols > galias.h
if OS_UNIX
TESTS = abicheck.sh
endif
BUILT_SOURCES = galias.h
EXTRA_DIST = \
makefile.msc.in \
glib.rc.in \
gen-unicode-tables.pl \
glib.def
makegalias.pl \
glib.symbols
# These may be in the builddir too
BUILT_EXTRA_DIST = \
makefile.msc \
glib.rc
glib.rc \
glib.def \
galias.h
lib_LTLIBRARIES = libglib-2.0.la
......@@ -184,6 +199,8 @@ uninstall-libtool-import-lib:
else
install-libtool-import-lib:
uninstall-libtool-import-lib:
export_symbols = $(LIBTOOL_EXPORT_OPTIONS)
endif
libglib_2_0_la_LIBADD = libcharset/libcharset.la $(printf_la) @GIO@ @GSPAWN@ @PLATFORMDEP@ @G_LIB_WIN32_RESOURCE@ @ICONV_LIBS@ @G_LIBS_EXTRA@
......
#! /bin/sh
cpp -P -DG_OS_UNIX -DINCLUDE_INTERNAL_SYMBOLS ${srcdir:-.}/glib.symbols | sed -e '/^$/d' | sort > expected-abi
nm -D .libs/libglib-2.0.so | grep " T " | cut -c12- | sort > actual-abi
diff -u expected-abi actual-abi && rm expected-abi actual-abi
......@@ -32,6 +32,7 @@
#include <string.h>
#include <stdlib.h>
#include "galias.h"
#include "glib.h"
......
......@@ -26,6 +26,7 @@
#include "config.h"
#include "galias.h"
#include "glib.h"
......
......@@ -22,6 +22,7 @@
#include "config.h"
#include "galias.h"
#include "glib.h"
#include "gthreadinit.h"
......
......@@ -35,6 +35,7 @@
#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>
#include "galias.h"
#include "glib.h"
#include "gprintfint.h"
......
......@@ -30,6 +30,7 @@
#include "config.h"
#include "galias.h"
#include "glib.h"
......
......@@ -32,6 +32,7 @@
#include <string.h>
#include "galias.h"
#include "glib.h"
......
......@@ -28,6 +28,7 @@
#include <string.h>
#include <stdlib.h>
#include "galias.h"
#include "glib.h"
#include "gprintfint.h"
#include "gthreadinit.h"
......
......@@ -34,7 +34,7 @@
#include "config.h"
#include <string.h>
#include "galias.h"
#include "glib.h"
......
......@@ -35,6 +35,7 @@
/* #define DEBUG_MSG(args) g_message args ; */
#endif
#include "galias.h"
#include "glib.h"
#include <time.h>
......
......@@ -31,6 +31,7 @@
#include <dirent.h>
#endif
#include "galias.h"
#include "glib.h"
#include "gdir.h"
......
......@@ -26,6 +26,7 @@
#include "config.h"
#include "galias.h"
#include "glib.h"
......
......@@ -20,6 +20,7 @@
#include "config.h"
#include "galias.h"
#include "glib.h"
#include <sys/stat.h>
......
......@@ -30,6 +30,7 @@
#include "config.h"
#include "galias.h"
#include "glib.h"
......
......@@ -33,6 +33,7 @@
#include "config.h"
#include "galias.h"
#include "glib.h"
......
......@@ -42,6 +42,7 @@
#undef G_DISABLE_DEPRECATED
#include "galias.h"
#include "glib.h"
#include "giochannel.h"
......
......@@ -43,6 +43,7 @@
#include <string.h>
#include <fcntl.h>
#include "galias.h"
#include "glib.h"
/*
......
......@@ -34,6 +34,7 @@
#include "config.h"
#include "galias.h"
#include "glib.h"
#include <stdlib.h>
......
EXPORTS
g_allocator_free
g_allocator_new
g_array_append_vals
g_array_free
g_array_insert_vals
g_array_new
g_array_prepend_vals
g_array_remove_index
g_array_remove_index_fast
g_array_remove_range
g_array_set_size
g_array_sized_new
g_array_sort
g_array_sort_with_data
g_ascii_digit_value
g_ascii_dtostr
g_ascii_formatd
g_ascii_strcasecmp
g_ascii_strdown
g_ascii_strncasecmp
g_ascii_strtod
g_ascii_strtoull
g_ascii_strup
g_ascii_table
g_ascii_tolower
g_ascii_toupper
g_ascii_xdigit_value
g_async_queue_length
g_async_queue_length_unlocked
g_async_queue_lock
g_async_queue_new
g_async_queue_pop
g_async_queue_pop_unlocked
g_async_queue_push
g_async_queue_push_unlocked
g_async_queue_ref
g_async_queue_ref_unlocked
g_async_queue_timed_pop
g_async_queue_timed_pop_unlocked
g_async_queue_try_pop
g_async_queue_try_pop_unlocked
g_async_queue_unlock
g_async_queue_unref
g_async_queue_unref_and_unlock
g_atexit
g_atomic_int_add
g_atomic_int_compare_and_exchange
g_atomic_int_exchange_and_add
; g_atomic_int_get
g_atomic_pointer_compare_and_exchange
; g_atomic_pointer_get
g_basename
g_bit_nth_lsf
g_bit_nth_msf
g_bit_storage
g_blow_chunks
g_build_filename
g_build_path
g_byte_array_append
g_byte_array_free
g_byte_array_new
g_byte_array_prepend
g_byte_array_remove_index
g_byte_array_remove_index_fast
g_byte_array_remove_range
g_byte_array_set_size
g_byte_array_sized_new
g_byte_array_sort
g_byte_array_sort_with_data
g_cache_destroy
g_cache_insert
g_cache_key_foreach
g_cache_new
g_cache_remove
g_cache_value_foreach
g_child_watch_add
g_child_watch_add_full
g_child_watch_source_new
g_clear_error
g_completion_add_items
g_completion_clear_items
g_completion_complete
g_completion_complete_utf8
g_completion_free
g_completion_new
g_completion_remove_items
g_completion_set_compare
g_convert
g_convert_error_quark
g_convert_with_fallback
g_convert_with_iconv
g_datalist_clear
g_datalist_foreach
g_datalist_id_get_data
g_datalist_id_remove_no_notify
g_datalist_id_set_data_full
g_datalist_init
g_dataset_destroy
g_dataset_foreach
g_dataset_id_get_data
g_dataset_id_remove_no_notify
g_dataset_id_set_data_full
g_date_add_days
g_date_add_months
g_date_add_years
g_date_clamp
g_date_clear
g_date_compare
g_date_days_between
g_date_free
g_date_get_day
g_date_get_day_of_year
g_date_get_days_in_month
g_date_get_iso8601_week_of_year
g_date_get_julian
g_date_get_monday_week_of_year
g_date_get_monday_weeks_in_year
g_date_get_month
g_date_get_sunday_week_of_year
g_date_get_sunday_weeks_in_year
g_date_get_weekday
g_date_get_year
g_date_is_first_of_month
g_date_is_last_of_month
g_date_is_leap_year
g_date_new
g_date_new_dmy
g_date_new_julian
g_date_order
g_date_set_day
g_date_set_dmy
g_date_set_julian
g_date_set_month
g_date_set_parse
g_date_set_time
g_date_set_year
g_date_strftime
g_date_subtract_days
g_date_subtract_months
g_date_subtract_years
g_date_to_struct_tm
g_date_valid
g_date_valid_day
g_date_valid_dmy
g_date_valid_julian
g_date_valid_month
g_date_valid_weekday
g_date_valid_year
g_dir_close
g_dir_open
g_dir_read_name
g_dir_rewind
g_direct_equal
g_direct_hash
g_error_copy
g_error_free
g_error_matches
g_error_new
g_error_new_literal
g_file_error_from_errno
g_file_error_quark
g_file_get_contents
g_file_open_tmp
g_file_read_link
g_file_test
g_filename_from_uri
g_filename_from_utf8
g_filename_to_uri
g_filename_to_utf8
g_find_program_in_path
g_fprintf
g_free
g_get_application_name
g_get_charset
g_get_codeset
g_get_current_dir
g_get_current_time
g_get_home_dir
g_get_language_names
g_get_prgname
g_get_real_name
g_get_system_config_dirs
g_get_system_data_dirs
g_get_tmp_dir
g_get_user_cache_dir
g_get_user_config_dir
g_get_user_data_dir
g_get_user_name
g_getenv
g_hash_table_destroy
g_hash_table_find
g_hash_table_foreach
g_hash_table_foreach_remove
g_hash_table_foreach_steal
g_hash_table_insert
g_hash_table_lookup
g_hash_table_lookup_extended
g_hash_table_new
g_hash_table_new_full
g_hash_table_remove
g_hash_table_replace
g_hash_table_size
g_hash_table_steal
g_hook_alloc
g_hook_compare_ids
g_hook_destroy
g_hook_destroy_link
g_hook_find
g_hook_find_data
g_hook_find_func
g_hook_find_func_data
g_hook_first_valid
g_hook_free
g_hook_get
g_hook_insert_before
g_hook_insert_sorted
g_hook_list_clear
g_hook_list_init
g_hook_list_invoke
g_hook_list_invoke_check
g_hook_list_marshal
g_hook_list_marshal_check
g_hook_next_valid
g_hook_prepend
g_hook_ref
g_hook_unref
g_iconv
g_iconv_close
g_iconv_open
g_idle_add
g_idle_add_full
g_idle_funcs
g_idle_remove_by_data
g_idle_source_new
g_int_equal
g_int_hash
g_io_add_watch
g_io_add_watch_full
g_io_channel_close
g_io_channel_error_from_errno
g_io_channel_error_quark
g_io_channel_flush
g_io_channel_get_buffer_condition
g_io_channel_get_buffer_size
g_io_channel_get_buffered
g_io_channel_get_close_on_unref
g_io_channel_get_encoding
g_io_channel_get_flags
g_io_channel_get_line_term
g_io_channel_init
g_io_channel_new_file
g_io_channel_read
g_io_channel_read_chars
g_io_channel_read_line
g_io_channel_read_line_string
g_io_channel_read_to_end
g_io_channel_read_unichar
g_io_channel_ref
g_io_channel_seek
g_io_channel_seek_position
g_io_channel_set_buffer_size
g_io_channel_set_buffered
g_io_channel_set_close_on_unref
g_io_channel_set_encoding
g_io_channel_set_flags
g_io_channel_set_line_term
g_io_channel_shutdown
g_io_channel_unix_get_fd
g_io_channel_unix_new
g_io_channel_unref
g_io_channel_win32_get_fd
g_io_channel_win32_make_pollfd
g_io_channel_win32_new_fd
g_io_channel_win32_new_messages
g_io_channel_win32_new_socket
g_io_channel_win32_new_stream_socket
g_io_channel_win32_poll
g_io_channel_win32_set_debug
g_io_channel_write
g_io_channel_write_chars
g_io_channel_write_unichar
g_io_create_watch
g_io_watch_funcs
g_list_alloc
g_list_append
g_list_concat
g_list_copy
g_list_delete_link
g_list_find
g_list_find_custom
g_list_first
g_list_foreach
g_list_free
g_list_free_1
g_list_index
g_list_insert
g_list_insert_before
g_list_insert_sorted
g_list_last
g_list_length
g_list_nth
g_list_nth_data
g_list_nth_prev
g_list_pop_allocator
g_list_position
g_list_prepend
g_list_push_allocator
g_list_remove
g_list_remove_all
g_list_remove_link
g_list_reverse
g_list_sort
g_list_sort_with_data
g_locale_from_utf8
g_locale_to_utf8
g_log
g_log_default_handler
g_log_remove_handler
g_log_set_always_fatal
g_log_set_default_handler
g_log_set_fatal_mask
g_log_set_handler
g_logv
g_main_context_acquire
g_main_context_add_poll
g_main_context_check
g_main_context_default
g_main_context_dispatch
g_main_context_find_source_by_funcs_user_data
g_main_context_find_source_by_id
g_main_context_find_source_by_user_data
g_main_context_get_poll_func
g_main_context_iteration
g_main_context_new
g_main_context_pending
g_main_context_prepare
g_main_context_query
g_main_context_ref
g_main_context_release
g_main_context_remove_poll
g_main_context_set_poll_func
g_main_context_unref
g_main_context_wait
g_main_context_wakeup
g_main_depth
g_main_loop_get_context
g_main_loop_is_running
g_main_loop_new
g_main_loop_quit
g_main_loop_ref
g_main_loop_run
g_main_loop_unref
g_malloc
g_malloc0
g_markup_error_quark
g_markup_escape_text
g_markup_parse_context_end_parse
g_markup_parse_context_free
g_markup_parse_context_get_element
g_markup_parse_context_get_position
g_markup_parse_context_new
g_markup_parse_context_parse
g_markup_printf_escaped
g_markup_vprintf_escaped
g_mem_chunk_alloc
g_mem_chunk_alloc0
g_mem_chunk_clean
g_mem_chunk_destroy
g_mem_chunk_free
g_mem_chunk_info
g_mem_chunk_new
g_mem_chunk_print
g_mem_chunk_reset
g_mem_is_system_malloc
g_mem_profile
g_mem_set_vtable
g_memdup
g_mkstemp
g_node_child_index
g_node_child_position
g_node_children_foreach
g_node_copy
g_node_copy_deep
g_node_depth
g_node_destroy
g_node_find
g_node_find_child
g_node_first_sibling
g_node_get_root
g_node_insert
g_node_insert_after
g_node_insert_before
g_node_is_ancestor
g_node_last_child
g_node_last_sibling
g_node_max_height
g_node_n_children
g_node_n_nodes
g_node_new
g_node_nth_child
g_node_pop_allocator
g_node_prepend
g_node_push_allocator
g_node_reverse_children
g_node_traverse
g_node_unlink
g_nullify_pointer