Commit Graph

2 Commits

Author SHA1 Message Date
Dodji Seketeli
0dd5f64279 Sort elf symbols before serializing them
* include/abg-corpus.h (corpus::{get_sorted_fun_symbols,
	get_sorted_var_symbols}): Declare new member functions.
	* src/abg-corpus.cc (corpus_priv::{sorted_var_symbols,
	sorted_fun_symbols}): New data members.
	(struct elf_symbol_comp_functor): Define new comparison functor.
	(corpus::{get_sorted_fun_symbols, get_sorted_var_symbols}): Define
	new member functions.
	* src/abg-writer.cc (write_elf_symbols_table): Take a sorted
	vector of symbols in parameters, rather than an unsorted map.
	(write_corpus_to_native_xml): Write a sorted vector of symbols,
	rather than an unsorted map of symbols.
	* tests/data/test-read-dwarf/test0.abi: Adjust.
	* tests/data/test-read-dwarf/test1.abi: Likewise.
	* tests/data/test-read-dwarf/test2.so.abi: Likewise.
	* tests/data/test-read-dwarf/test3.so.abi: Likewise.
	* tests/data/test-read-dwarf/test6.so.abi: Likewise.

Signed-off-by: Dodji Seketeli <dodji@redhat.com>
2014-11-08 11:22:43 +01:00
Sinny Kumari
64bd3adce5 Keep symbol's multiple aliases within single attribute separated by comma
* src/abg-writer.cc (write_elf_symbol_aliases): Changing function
	to keep multiple symbol aliases within one alias attribute
	* src/abg-reader.cc (build_elf_symbol_db): Changing function to read
	symbol's alias attribute and split if multiple alias exist with comma(,)
	asi a delimiter and add all aliases to main symbol
	* tests/data/test-read-dwarf/test3.c: Test file to generate multiple aliases
	* tests/data/test-read-dwarf/test3.so: Test shared library having multiple
	aliases of a symbol
	* tests/data/test-read-dwarf/test3.so.abi: XML file containing dwarf
	information from test3.so
	* tests/test-read-dwarf.cc (in_out_specs): Add the new test above
	* tests/Makefile.am: Add tests/data/test-read-dwarf/test3.c,
	tests/data/test-read-dwarf/test3.so and tests/data/test-read-dwarf/test3.so.abi
	to the distribution

Signed-off-by: Sinny Kumari <skumari@redhat.com>
2014-06-20 11:56:49 +02:00