gkdr / lurch

XEP-0384: OMEMO Encryption for libpurple.
GNU General Public License v3.0
289 stars 32 forks source link

Why not compile statically for easier distribution? #182

Open ctrlcctrlv opened 2 years ago

ctrlcctrlv commented 2 years ago
diff --git a/Makefile b/Makefile
index 4331906..0b8e94e 100644
--- a/Makefile
+++ b/Makefile
@@ -83,11 +83,11 @@ ifeq ($(USE_DYNAMIC_LIBS),)
 else
    HEADERS=-I$(HDIR)/jabber
 endif
-CFLAGS += -std=c11 -Wall -g -Wstrict-overflow $(PKGCFG_C) $(HEADERS)
+CFLAGS += -Wl,--whole-archive -fcommon -fPIC -std=c11 -Wall -g -Wstrict-overflow $(PKGCFG_C) $(HEADERS)
 PLUGIN_CPPFLAGS=-DPURPLE_PLUGINS
 # -D_BSD_SOURCE can be removed once nobody uses glibc <= 2.18 any more
 CPPFLAGS += -D_XOPEN_SOURCE=700 -D_BSD_SOURCE -D_DEFAULT_SOURCE
-LDFLAGS += -ldl -lm $(PKGCFG_L) $(LJABBER) -Wl,-rpath,$(PURPLE_PLUGIN_DIR)
+LDFLAGS += -z muldefs -ldl -lm $(PKGCFG_L) $(LJABBER) -Wl,-rpath,$(PURPLE_PLUGIN_DIR)
 LDFLAGS_T=$(LDFLAGS) -lpurple -lcmocka

 ### directories
@@ -126,7 +126,9 @@ endif

 ### make rules
 #
-all: $(BDIR)/lurch.so
+all:
+   $(MAKE) $(BDIR)/lurch.a
+   $(MAKE) $(BDIR)/lurch.so

 $(BDIR):
    $(MKDIR_P) build

Sure, it's a ton of symbols…

_absvdi2.o __absvti2.cold _addvdi3.o __addvti3.cold _subvdi3.o __subvti3.cold _mulvdi3.o __mulvti3.cold _negvdi2.o __negvti2.cold generic-morestack.o nl.2 msg.1 __morestack_fullmask static_pagesize use_guard_page msg.0 __morestack_allocate_stack_space.cold _absvdi2.o __absvti2.cold _addvdi3.o __addvti3.cold _subvdi3.o __subvti3.cold _mulvdi3.o __mulvti3.cold _negvdi2.o __negvti2.cold generic-morestack.o nl.2 msg.1 __morestack_fullmask static_pagesize use_guard_page msg.0 __morestack_allocate_stack_space.cold _absvdi2.o __absvti2.cold _addvdi3.o __addvti3.cold _subvdi3.o __subvti3.cold _mulvdi3.o __mulvti3.cold _negvdi2.o __negvti2.cold generic-morestack.o nl.2 msg.1 __morestack_fullmask static_pagesize use_guard_page msg.0 __morestack_allocate_stack_space.cold _absvdi2.o __absvti2.cold _addvdi3.o __addvti3.cold _subvdi3.o __subvti3.cold _mulvdi3.o __mulvti3.cold _negvdi2.o __negvti2.cold generic-morestack.o nl.2
msg.1 __morestack_fullmask static_pagesize use_guard_page msg.0 __morestack_allocate_stack_space.cold cpuinfo.o set_cpu_feature.part.0.constprop.0 get_available_features.constprop.0 has_cpu_feature.part.0.constprop.0 cpuinfo.o set_cpu_feature.part.0.constprop.0 get_available_features.constprop.0 has_cpu_feature.part.0.constprop.0 cpuinfo.o set_cpu_feature.part.0.constprop.0 get_available_features.constprop.0 has_cpu_feature.part.0.constprop.0 cpuinfo.o set_cpu_feature.part.0.constprop.0 get_available_features.constprop.0 has_cpu_feature.part.0.constprop.0 crtstuff.c deregister_tm_clones register_tm_clones __do_global_dtors_aux completed.0 __do_global_dtors_aux_fini_array_entry frame_dummy __frame_dummy_init_array_entry lurch.c crypto lurch_queued_msg_create __func__.15 lurch_queued_msg_is_handled lurch_queued_msg_destroy lurch_queue_make_key_string_s lurch_axc_prepare __func__.14 lurch_bundle_publish_own __func__.13
lurch_bundle_name_get_device_id lurch_bundle_create_session __func__.12 lurch_export_encrypted lurch_bundle_request_cb __func__.11 lurch_bundle_request_do __func__.10 lurch_pep_bundle_for_keytransport __func__.9 lurch_devicelist_process __func__.8 lurch_pep_own_devicelist_request_handler __func__.7 lurch_pep_devicelist_event_handler __func__.6 lurch_account_connect_cb __func__.5 lurch_msg_finalize_encryption __func__.4 lurch_message_encrypt_im __func__.3 lurch_message_encrypt_groupchat __func__.2 lurch_xml_sent_cb lurch_message_decrypt __func__.1 lurch_message_warn lurch_xml_received_cb lurch_topic_update_im lurch_topic_update_chat lurch_conv_created_cb lurch_conv_updated_cb lurch_plugin_load __func__.0 lurch_plugin_unload lurch_get_plugin_pref_frame prefs_info info lurch_plugin_init lurch_addr.c lurch_addr_list_destroy_func __func__.0 lurch_api.c lurch_api_id_list_get_own lurch_api_fp_create_table lurch_api_status_chat_discover
lurch_api_marshal_VOID__POINTER_INT_POINTER_POINTER get_num_of_signals lurch_cmd_ui.c lurch_cmd_print lurch_cmd_print_err lurch_cmd_help lurch_cmd_id lurch_cmd_enable lurch_cmd_disable lurch_cmd_fp lurch_cmd_status lurch_crypto.c crypto __func__.1 __func__.0 lurch_util.c __func__.1 __func__.0 libomemo.c int_to_string expect_next_node add_recipient jid_strip_resource omemo_message_find_key_element libomemo_crypto.c libomemo_storage.c db_conn_open_and_prepare db_conn_commit axc.c __func__.10 __func__.9 __func__.8 __func__.7 __func__.6 __func__.5 __func__.4 __func__.3 __func__.2 __func__.1 __func__.0 axc_crypto.c __func__.5 __func__.4 __func__.3 __func__.2 choose_aes __func__.1 __func__.0 axc_store.c db_conn_cleanup db_conn_open __func__.29 __func__.28 __func__.27 __func__.26 __func__.25 __func__.24 __func__.23 __func__.22 __func__.21 __func__.20 __func__.19 __func__.18 __func__.17 __func__.16 __func__.15 __func__.14 __func__.13
__func__.12 __func__.11 __func__.10 __func__.9 __func__.8 __func__.7 __func__.6 __func__.5 __func__.4 __func__.3 __func__.2 __func__.1 __func__.0 LocalStorageProtocol.pb-c.c init_value.42 init_value.41 init_value.40 init_value.39 init_value.38 init_value.37 __PRETTY_FUNCTION__.36 __PRETTY_FUNCTION__.35 __PRETTY_FUNCTION__.34 __PRETTY_FUNCTION__.33 init_value.32 __PRETTY_FUNCTION__.31 __PRETTY_FUNCTION__.30 __PRETTY_FUNCTION__.29 __PRETTY_FUNCTION__.28 init_value.27 __PRETTY_FUNCTION__.26 __PRETTY_FUNCTION__.25 __PRETTY_FUNCTION__.24 __PRETTY_FUNCTION__.23 init_value.22 __PRETTY_FUNCTION__.21 __PRETTY_FUNCTION__.20 __PRETTY_FUNCTION__.19 __PRETTY_FUNCTION__.18 init_value.17 __PRETTY_FUNCTION__.16 __PRETTY_FUNCTION__.15 __PRETTY_FUNCTION__.14 __PRETTY_FUNCTION__.13 init_value.12 init_value.11 init_value.10 init_value.9 __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5 init_value.4
__PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 textsecure__session_structure__chain__chain_key__field_descriptors textsecure__session_structure__chain__chain_key__field_indices_by_name textsecure__session_structure__chain__chain_key__number_ranges textsecure__session_structure__chain__message_key__field_descriptors textsecure__session_structure__chain__message_key__field_indices_by_name textsecure__session_structure__chain__message_key__number_ranges textsecure__session_structure__chain__field_descriptors textsecure__session_structure__chain__field_indices_by_name textsecure__session_structure__chain__number_ranges textsecure__session_structure__pending_key_exchange__field_descriptors textsecure__session_structure__pending_key_exchange__field_indices_by_name textsecure__session_structure__pending_key_exchange__number_ranges textsecure__session_structure__pending_pre_key__field_descriptors
textsecure__session_structure__pending_pre_key__field_indices_by_name textsecure__session_structure__pending_pre_key__number_ranges textsecure__session_structure__field_descriptors textsecure__session_structure__field_indices_by_name textsecure__session_structure__number_ranges textsecure__record_structure__field_descriptors textsecure__record_structure__field_indices_by_name textsecure__record_structure__number_ranges textsecure__pre_key_record_structure__field_descriptors textsecure__pre_key_record_structure__field_indices_by_name textsecure__pre_key_record_structure__number_ranges textsecure__signed_pre_key_record_structure__field_descriptors textsecure__signed_pre_key_record_structure__field_indices_by_name textsecure__signed_pre_key_record_structure__number_ranges textsecure__identity_key_pair_structure__field_descriptors textsecure__identity_key_pair_structure__field_indices_by_name
textsecure__identity_key_pair_structure__number_ranges textsecure__sender_key_state_structure__sender_chain_key__field_descriptors textsecure__sender_key_state_structure__sender_chain_key__field_indices_by_name textsecure__sender_key_state_structure__sender_chain_key__number_ranges textsecure__sender_key_state_structure__sender_message_key__field_descriptors textsecure__sender_key_state_structure__sender_message_key__field_indices_by_name textsecure__sender_key_state_structure__sender_message_key__number_ranges textsecure__sender_key_state_structure__sender_signing_key__field_descriptors textsecure__sender_key_state_structure__sender_signing_key__field_indices_by_name textsecure__sender_key_state_structure__sender_signing_key__number_ranges textsecure__sender_key_state_structure__field_descriptors textsecure__sender_key_state_structure__field_indices_by_name textsecure__sender_key_state_structure__number_ranges
textsecure__sender_key_record_structure__field_descriptors textsecure__sender_key_record_structure__field_indices_by_name textsecure__sender_key_record_structure__number_ranges WhisperTextProtocol.pb-c.c init_value.29 __PRETTY_FUNCTION__.28 __PRETTY_FUNCTION__.27 __PRETTY_FUNCTION__.26 __PRETTY_FUNCTION__.25 init_value.24 __PRETTY_FUNCTION__.23 __PRETTY_FUNCTION__.22 __PRETTY_FUNCTION__.21 __PRETTY_FUNCTION__.20 init_value.19 __PRETTY_FUNCTION__.18 __PRETTY_FUNCTION__.17 __PRETTY_FUNCTION__.16 __PRETTY_FUNCTION__.15 init_value.14 __PRETTY_FUNCTION__.13 __PRETTY_FUNCTION__.12 __PRETTY_FUNCTION__.11 __PRETTY_FUNCTION__.10 init_value.9 __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5 init_value.4 __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 textsecure__signal_message__field_descriptors textsecure__signal_message__field_indices_by_name
textsecure__signal_message__number_ranges textsecure__pre_key_signal_message__field_descriptors textsecure__pre_key_signal_message__field_indices_by_name textsecure__pre_key_signal_message__number_ranges textsecure__key_exchange_message__field_descriptors textsecure__key_exchange_message__field_indices_by_name textsecure__key_exchange_message__number_ranges textsecure__sender_key_message__field_descriptors textsecure__sender_key_message__field_indices_by_name textsecure__sender_key_message__number_ranges textsecure__sender_key_distribution_message__field_descriptors textsecure__sender_key_distribution_message__field_indices_by_name textsecure__sender_key_distribution_message__number_ranges textsecure__device_consistency_code_message__field_descriptors textsecure__device_consistency_code_message__field_indices_by_name textsecure__device_consistency_code_message__number_ranges FingerprintProtocol.pb-c.c init_value.9
__PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5 init_value.4 __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 textsecure__logical_fingerprint__field_descriptors textsecure__logical_fingerprint__field_indices_by_name textsecure__logical_fingerprint__number_ranges textsecure__combined_fingerprints__field_descriptors textsecure__combined_fingerprints__field_indices_by_name textsecure__combined_fingerprints__number_ranges vpool.c vpool_shift vpool_new_size vpool_resize signal_protocol.c utarray_str_cpy utarray_str_dtor ut_str_icd ut_int_icd ut_ptr_icd __PRETTY_FUNCTION__.44 __PRETTY_FUNCTION__.43 __PRETTY_FUNCTION__.42 __PRETTY_FUNCTION__.41 __PRETTY_FUNCTION__.40 __PRETTY_FUNCTION__.39 __PRETTY_FUNCTION__.38 __PRETTY_FUNCTION__.37 __PRETTY_FUNCTION__.36 __PRETTY_FUNCTION__.35 __PRETTY_FUNCTION__.34 __PRETTY_FUNCTION__.33 __PRETTY_FUNCTION__.32
__PRETTY_FUNCTION__.31 __PRETTY_FUNCTION__.30 __PRETTY_FUNCTION__.29 __PRETTY_FUNCTION__.28 __PRETTY_FUNCTION__.27 __PRETTY_FUNCTION__.26 __PRETTY_FUNCTION__.25 __PRETTY_FUNCTION__.24 __PRETTY_FUNCTION__.23 __PRETTY_FUNCTION__.22 __PRETTY_FUNCTION__.21 __PRETTY_FUNCTION__.20 __PRETTY_FUNCTION__.19 __PRETTY_FUNCTION__.18 __PRETTY_FUNCTION__.17 __PRETTY_FUNCTION__.16 __PRETTY_FUNCTION__.15 __PRETTY_FUNCTION__.14 __PRETTY_FUNCTION__.13 __PRETTY_FUNCTION__.12 __PRETTY_FUNCTION__.11 __PRETTY_FUNCTION__.10 __PRETTY_FUNCTION__.9 __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5 __PRETTY_FUNCTION__.4 __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 curve.c utarray_str_cpy utarray_str_dtor ut_str_icd ut_int_icd ut_ptr_icd __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 basepoint.5 __PRETTY_FUNCTION__.4 __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2
__PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 hkdf.c __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 ratchet.c __PRETTY_FUNCTION__.18 message_key_seed.17 key_material_seed.16 chain_key_seed.15 key_info.14 __PRETTY_FUNCTION__.13 __PRETTY_FUNCTION__.12 __PRETTY_FUNCTION__.11 __PRETTY_FUNCTION__.10 __PRETTY_FUNCTION__.9 __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5 __PRETTY_FUNCTION__.4 key_info.3 __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 protocol.c __PRETTY_FUNCTION__.35 __PRETTY_FUNCTION__.34 __PRETTY_FUNCTION__.33 signal_message_serialize signal_message_get_mac __PRETTY_FUNCTION__.32 __PRETTY_FUNCTION__.31 __PRETTY_FUNCTION__.30 __PRETTY_FUNCTION__.29 __PRETTY_FUNCTION__.28 __PRETTY_FUNCTION__.27 __PRETTY_FUNCTION__.26 __PRETTY_FUNCTION__.25 __PRETTY_FUNCTION__.24 pre_key_signal_message_serialize __PRETTY_FUNCTION__.23
__PRETTY_FUNCTION__.22 __PRETTY_FUNCTION__.21 __PRETTY_FUNCTION__.20 __PRETTY_FUNCTION__.19 __PRETTY_FUNCTION__.18 __PRETTY_FUNCTION__.17 __PRETTY_FUNCTION__.16 __PRETTY_FUNCTION__.15 __PRETTY_FUNCTION__.14 __PRETTY_FUNCTION__.13 sender_key_message_serialize __PRETTY_FUNCTION__.12 __PRETTY_FUNCTION__.11 __PRETTY_FUNCTION__.10 __PRETTY_FUNCTION__.9 __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 sender_key_distribution_message_serialize __PRETTY_FUNCTION__.5 __PRETTY_FUNCTION__.4 __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 session_state.c __PRETTY_FUNCTION__.47 session_state_serialize_prepare_sender_chain session_state_serialize_prepare_receiver_chain session_state_serialize_prepare_pending_key_exchange session_state_serialize_prepare_pending_pre_key session_state_serialize_prepare_chain_chain_key session_state_serialize_prepare_chain_message_keys_list
session_state_serialize_prepare_message_keys session_state_serialize_prepare_message_keys_free __PRETTY_FUNCTION__.46 session_state_serialize_prepare_chain_free session_state_serialize_prepare_pending_key_exchange_free session_state_serialize_prepare_pending_pre_key_free session_state_deserialize_protobuf_sender_chain session_state_deserialize_protobuf_receiver_chain session_state_deserialize_protobuf_pending_key_exchange session_state_deserialize_protobuf_pending_pre_key __PRETTY_FUNCTION__.45 __PRETTY_FUNCTION__.44 __PRETTY_FUNCTION__.43 __PRETTY_FUNCTION__.42 __PRETTY_FUNCTION__.41 __PRETTY_FUNCTION__.40 __PRETTY_FUNCTION__.39 __PRETTY_FUNCTION__.38 __PRETTY_FUNCTION__.37 __PRETTY_FUNCTION__.36 __PRETTY_FUNCTION__.35 __PRETTY_FUNCTION__.34 __PRETTY_FUNCTION__.33 __PRETTY_FUNCTION__.32 __PRETTY_FUNCTION__.31 __PRETTY_FUNCTION__.30 __PRETTY_FUNCTION__.29 __PRETTY_FUNCTION__.28 __PRETTY_FUNCTION__.27 session_state_find_receiver_chain
__PRETTY_FUNCTION__.26 __PRETTY_FUNCTION__.25 __PRETTY_FUNCTION__.24 session_state_free_receiver_chain_node __PRETTY_FUNCTION__.23 __PRETTY_FUNCTION__.22 __PRETTY_FUNCTION__.21 __PRETTY_FUNCTION__.20 __PRETTY_FUNCTION__.19 __PRETTY_FUNCTION__.18 __PRETTY_FUNCTION__.17 __PRETTY_FUNCTION__.16 __PRETTY_FUNCTION__.15 __PRETTY_FUNCTION__.14 __PRETTY_FUNCTION__.13 __PRETTY_FUNCTION__.12 __PRETTY_FUNCTION__.11 __PRETTY_FUNCTION__.10 __PRETTY_FUNCTION__.9 __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5 __PRETTY_FUNCTION__.4 __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 session_state_free_sender_chain __PRETTY_FUNCTION__.1 session_state_free_receiver_chain __PRETTY_FUNCTION__.0 session_record.c __PRETTY_FUNCTION__.13 __PRETTY_FUNCTION__.12 __PRETTY_FUNCTION__.11 __PRETTY_FUNCTION__.10 __PRETTY_FUNCTION__.9 __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5
__PRETTY_FUNCTION__.4 __PRETTY_FUNCTION__.3 session_record_free_previous_states __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 session_pre_key.c __PRETTY_FUNCTION__.9 __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5 __PRETTY_FUNCTION__.4 __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 session_builder.c __PRETTY_FUNCTION__.1 session_builder_process_pre_key_signal_message_v3 __PRETTY_FUNCTION__.0 session_cipher.c __PRETTY_FUNCTION__.9 __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5 session_cipher_get_ciphertext __PRETTY_FUNCTION__.4 session_cipher_decrypt_from_record_and_signal_message session_cipher_decrypt_callback __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 session_cipher_decrypt_from_state_and_signal_message session_cipher_get_or_create_chain_key session_cipher_get_or_create_message_keys
session_cipher_get_plaintext __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 key_helper.c __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5 __PRETTY_FUNCTION__.4 __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 sender_key.c __PRETTY_FUNCTION__.12 info_material.11 __PRETTY_FUNCTION__.10 __PRETTY_FUNCTION__.9 __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5 __PRETTY_FUNCTION__.4 MESSAGE_KEY_SEED.3 sender_chain_key_get_derivative __PRETTY_FUNCTION__.2 CHAIN_KEY_SEED.1 __PRETTY_FUNCTION__.0 sender_key_state.c __PRETTY_FUNCTION__.10 __PRETTY_FUNCTION__.9 __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5 __PRETTY_FUNCTION__.4 __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 sender_key_record.c __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7
__PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5 sender_key_record_add_sender_key_state_impl __PRETTY_FUNCTION__.4 __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 group_session_builder.c __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 group_cipher.c __PRETTY_FUNCTION__.5 __PRETTY_FUNCTION__.4 __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 group_cipher_get_sender_key group_cipher_decrypt_callback fingerprint.c __PRETTY_FUNCTION__.12 fingerprint_generator_create_for_impl fingerprint_generator_get_logical_key_bytes fingerprint_generator_get_fingerprint fingerprint_generator_create_display_string __PRETTY_FUNCTION__.11 __PRETTY_FUNCTION__.10 __PRETTY_FUNCTION__.9 __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 __PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5 __PRETTY_FUNCTION__.4 __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1
__PRETTY_FUNCTION__.0 device_consistency.c utarray_str_cpy utarray_str_dtor ut_str_icd ut_int_icd ut_ptr_icd __PRETTY_FUNCTION__.11 __PRETTY_FUNCTION__.10 version.9 __PRETTY_FUNCTION__.8 __PRETTY_FUNCTION__.7 device_consistency_message_create __PRETTY_FUNCTION__.6 __PRETTY_FUNCTION__.5 __PRETTY_FUNCTION__.4 device_consistency_signature_list_sort __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 curve25519-donna.c fsum fdifference fscalar_product fproduct freduce_degree div_by_2_26 div_by_2_25 freduce_coefficients fmul fsquare_inner fsquare fexpand s32_eq s32_gte fcontract fmonty swap_conditional cmult crecip fe_0.c fe_1.c fe_add.c fe_cmov.c fe_copy.c fe_frombytes.c load_3 load_4 fe_invert.c fe_isnegative.c fe_isnonzero.c zero fe_mul.c fe_neg.c fe_pow22523.c fe_sq.c fe_sq2.c fe_sub.c fe_tobytes.c ge_add.c ge_double_scalarmult.c slide Bi ge_frombytes.c d sqrtm1 ge_madd.c ge_msub.c
ge_p1p1_to_p2.c ge_p1p1_to_p3.c ge_p2_0.c ge_p2_dbl.c ge_p3_0.c ge_p3_dbl.c ge_p3_to_cached.c d2 ge_p3_to_p2.c ge_p3_tobytes.c ge_precomp_0.c ge_scalarmult_base.c equal negative cmov base select ge_sub.c ge_tobytes.c open.c sc_muladd.c load_3 load_4 sc_reduce.c load_3 load_4 sign.c compare.c curve_sigs.c elligator.c fe_isequal.c fe_isreduced.c fe_mont_rhs.c fe_montx_to_edy.c fe_sqrt.c i_bytes __PRETTY_FUNCTION__.0 ge_isneutral.c ge_montx_to_p3.c A_bytes __PRETTY_FUNCTION__.0 ge_neg.c ge_p3_to_montx.c ge_scalarmult.c equal negative cmov select ge_scalarmult_cofactor.c keygen.c open_modified.c sc_clamp.c sc_cmov.c sc_neg.c lminus1 sign_modified.c utility.c ge_p3_add.c gen_eddsa.c gen_labelset.c gen_veddsa.c generalized_calculate_Bv generalized_calculate_vrf_output gen_x.c convert_25519_pubkey calculate_25519_keypair point_isreduced.c sc_isreduced.c xeddsa.c zeroize.c blocks.c load_bigendian store_bigendian hash.c iv
internal_fast_tests.c protobuf-c.c system_alloc system_free do_alloc do_free protobuf_c__allocator get_tag_size uint32_size int32_size zigzag32 sint32_size uint64_size zigzag64 sint64_size required_field_get_packed_size __PRETTY_FUNCTION__.16 oneof_field_get_packed_size optional_field_get_packed_size repeated_field_get_packed_size unknown_field_get_packed_size __PRETTY_FUNCTION__.15 uint32_pack int32_pack sint32_pack uint64_pack sint64_pack fixed32_pack fixed64_pack boolean_pack string_pack binary_data_pack prefixed_message_pack tag_pack required_field_pack __PRETTY_FUNCTION__.14 oneof_field_pack optional_field_pack sizeof_elt_in_repeated_array __PRETTY_FUNCTION__.12 copy_to_little_endian_32 copy_to_little_endian_64 get_type_min_size repeated_field_pack __PRETTY_FUNCTION__.13 unknown_field_pack __PRETTY_FUNCTION__.11 required_field_pack_to_buffer __PRETTY_FUNCTION__.10 oneof_field_pack_to_buffer optional_field_pack_to_buffer
get_packed_payload_length __PRETTY_FUNCTION__.9 pack_buffer_packed_payload __PRETTY_FUNCTION__.8 repeated_field_pack_to_buffer __PRETTY_FUNCTION__.7 unknown_field_pack_to_buffer __PRETTY_FUNCTION__.6 int_range_lookup parse_tag_and_wiretype scan_length_prefixed_data max_b128_numbers merge_messages count_packed_elements parse_uint32 parse_int32 unzigzag32 parse_fixed_uint32 parse_uint64 unzigzag64 parse_fixed_uint64 parse_boolean parse_required_member parse_oneof_member parse_optional_member parse_repeated_member scan_varint parse_packed_repeated_member __PRETTY_FUNCTION__.5 is_packable_type parse_member __PRETTY_FUNCTION__.4 message_init_generic __PRETTY_FUNCTION__.3 __PRETTY_FUNCTION__.2 protobuf_c_message_free_unpacked.localalias protobuf_c_message_check.localalias __PRETTY_FUNCTION__.1 __PRETTY_FUNCTION__.0 bid_binarydecimal.o exponents_binary32 breakpoints_binary32 multipliers1_binary32 roundbound_128 multipliers2_binary32
exponents_binary64 breakpoints_binary64 multipliers1_binary64 multipliers2_binary64 exponents_binary80 breakpoints_binary80 multipliers1_binary80 multipliers2_binary80 exponents_binary128 breakpoints_binary128 multipliers1_binary128 multipliers2_binary128 exponents_bid32 breakpoints_bid32 multipliers1_bid32 coefflimits_bid32 power_five multipliers2_bid32 exponents_bid64 breakpoints_bid64 multipliers1_bid64 coefflimits_bid64 multipliers2_bid64 innertable_sig innertable_exp coefflimits_bid128 outertable_exp outertable_sig bid64_noncomp.o mult_factor bid128_fma.o sub256 nr_digits256 rounding_correction.constprop.0 add_and_round.constprop.0 bid128_ext_fma bid64_div.o __div_128_by_128 __div_256_by_128 get_BID64_UF.part.0.constprop.0 get_BID64.constprop.0 bid128_div.o __div_128_by_128 __div_256_by_128 handle_UF_128_rem.constprop.0.isra.0 handle_UF_128.constprop.0.isra.0 bid64_compare.o mult_factor generic-morestack-thread.o
stack_split_initialize_thread segment_list_key msg.1 create_key free_segments msg.0 create_key_once msg.2 bid_binarydecimal.o exponents_binary32 breakpoints_binary32 multipliers1_binary32 roundbound_128 multipliers2_binary32 exponents_binary64 breakpoints_binary64 multipliers1_binary64 multipliers2_binary64 exponents_binary80 breakpoints_binary80 multipliers1_binary80 multipliers2_binary80 exponents_binary128 breakpoints_binary128 multipliers1_binary128 multipliers2_binary128 exponents_bid32 breakpoints_bid32 multipliers1_bid32 coefflimits_bid32 power_five multipliers2_bid32 exponents_bid64 breakpoints_bid64 multipliers1_bid64 coefflimits_bid64 multipliers2_bid64 innertable_sig innertable_exp coefflimits_bid128 outertable_exp outertable_sig bid64_noncomp.o mult_factor bid128_fma.o sub256 nr_digits256 rounding_correction.constprop.0 add_and_round.constprop.0 bid128_ext_fma bid64_div.o __div_128_by_128 __div_256_by_128
get_BID64_UF.part.0.constprop.0 get_BID64.constprop.0 bid128_div.o __div_128_by_128 __div_256_by_128 handle_UF_128_rem.constprop.0.isra.0 handle_UF_128.constprop.0.isra.0 bid64_compare.o mult_factor generic-morestack-thread.o stack_split_initialize_thread segment_list_key msg.1 create_key free_segments msg.0 create_key_once msg.2 bid_binarydecimal.o exponents_binary32 breakpoints_binary32 multipliers1_binary32 roundbound_128 multipliers2_binary32 exponents_binary64 breakpoints_binary64 multipliers1_binary64 multipliers2_binary64 exponents_binary80 breakpoints_binary80 multipliers1_binary80 multipliers2_binary80 exponents_binary128 breakpoints_binary128 multipliers1_binary128 multipliers2_binary128 exponents_bid32 breakpoints_bid32 multipliers1_bid32 coefflimits_bid32 power_five multipliers2_bid32 exponents_bid64 breakpoints_bid64 multipliers1_bid64 coefflimits_bid64 multipliers2_bid64 innertable_sig innertable_exp
coefflimits_bid128 outertable_exp outertable_sig bid64_noncomp.o mult_factor bid128_fma.o sub256 nr_digits256 rounding_correction.constprop.0 add_and_round.constprop.0 bid128_ext_fma bid64_div.o __div_128_by_128 __div_256_by_128 get_BID64_UF.part.0.constprop.0 get_BID64.constprop.0 bid128_div.o __div_128_by_128 __div_256_by_128 handle_UF_128_rem.constprop.0.isra.0 handle_UF_128.constprop.0.isra.0 bid64_compare.o mult_factor generic-morestack-thread.o stack_split_initialize_thread segment_list_key msg.1 create_key free_segments msg.0 create_key_once msg.2 bid_binarydecimal.o exponents_binary32 breakpoints_binary32 multipliers1_binary32 roundbound_128 multipliers2_binary32 exponents_binary64 breakpoints_binary64 multipliers1_binary64 multipliers2_binary64 exponents_binary80 breakpoints_binary80 multipliers1_binary80 multipliers2_binary80 exponents_binary128 breakpoints_binary128 multipliers1_binary128 multipliers2_binary128
exponents_bid32 breakpoints_bid32 multipliers1_bid32 coefflimits_bid32 power_five multipliers2_bid32 exponents_bid64 breakpoints_bid64 multipliers1_bid64 coefflimits_bid64 multipliers2_bid64 innertable_sig innertable_exp coefflimits_bid128 outertable_exp outertable_sig bid64_noncomp.o mult_factor bid128_fma.o sub256 nr_digits256 rounding_correction.constprop.0 add_and_round.constprop.0 bid128_ext_fma bid64_div.o __div_128_by_128 __div_256_by_128 get_BID64_UF.part.0.constprop.0 get_BID64.constprop.0 bid128_div.o __div_128_by_128 __div_256_by_128 handle_UF_128_rem.constprop.0.isra.0 handle_UF_128.constprop.0.isra.0 bid64_compare.o mult_factor generic-morestack-thread.o stack_split_initialize_thread segment_list_key msg.1 create_key free_segments msg.0 create_key_once msg.2 crtstuff.c __FRAME_END__ __multf3 __negvdi2 __divdc3 __morestack_release_segments __avx_savms64_15 __avx_resms64x_13 __ffsti2 __avx_resms64x_17 __udivmodti4
__fixunstfsi __avx_savms64f_16 __sse_resms64f_14 __DTOR_LIST__ __morestack_non_split __floattitf __avx_savms64f_12 __morestack_make_guard __popcountti2 __floatuntidf __stack_split_initialize __subtf3 __sse_resms64_12 __sse_savms64_17 __trunctfsf2 __divti3 __sse_savms64_13 __fixunsxfti __pthread_atfork __wrap_pthread_create __sse_resms64fx_15 __sse_resms64x_13 __clrsbti2 __GNU_EH_FRAME_HDR __fixsfti _fini __sse_savms64f_15 __negvti2 __sse_resms64x_17 __clz_tab __clrsbdi2 __floatuntitf __avx_resms64f_15 __cmpti2 __avx_resms64fx_12 __fixdfti __CTOR_LIST__ _GLOBAL_OFFSET_TABLE_ __avx_resms64fx_16 __sse_resms64_16 __letf2 __avx_resms64_14 __morestack_set_guard __unordtf2 __avx_resms64_18 __subvdi3 __extendxftf2 __absvsi2 __sfp_handle_exceptions __powixf2 __fixunssfti __avx_savms64_16 __gttf2 __avx_resms64x_16 __avx_savms64_12 __getf2 __ucmpti2 __avx_resms64f_12 __divtc3 __avx_resms64x_12 __modti3 __morestack_block_signals
__fixunstfti __sse_resms64f_13 __divsc3 __floattixf __morestack_unblock_signals __divtf3 atexit __avx_savms64f_15 __morestack_fail __sse_savms64_16 __sse_resms64_13 __sse_savms64_12 __mulvdi3 __sse_resms64x_14 __udiv_w_sdiv __bswapdi2 __floatditf __sse_resms64fx_12 __powidf2 __bswapsi2 __sse_resms64fx_16 __cpu_model __sse_savms64f_16 __sse_resms64x_18 __morestack __multi3 __sse_savms64f_12 __floattidf __clear_cache __avx_resms64fx_13 __avx_resms64f_16 __avx_resms64fx_17 __fixunsdfti __addtf3 __generic_findstack at_quick_exit __fixunsxfdi __avx_resms64_15 __sse_resms64_17 __TMC_END__ __lttf2 __fixxfti __dso_handle __avx_savms64_17 __gcc_bcmp __avx_savms64_13 __avx_resms64x_15 __avx_resms64f_13 __mulvsi3 __trunctfdf2 __sse_resms64f_12 __sse_resms64f_16 __parityti2 __clzdi2 __subvti3 __avx_savms64f_14 __fixunsdfdi __cpu_features2 __mulxc3 __sse_savms64_15 __negti2 __floatsitf __sse_resms64_14 __paritydi2 __divmodti4
__sse_resms64x_15 __negvsi2 __lshrti3 __sse_resms64fx_13 __sse_resms64fx_17 __sse_savms64f_17 __stack_chk_fail_local __ashrti3 __mulvti3 __absvti2 pthread_atfork __floatunditf __sse_savms64f_13 __morestack_get_guard __extenddftf2 __avx_resms64fx_14 __avx_resms64f_17 __umodti3 __fixunssfdi __avx_resms64_12 __avx_resms64_16 __multc3 __sse_resms64_18 __powitf2 __morestack_load_mmap __fixunstfdi __fixtfdi __netf2 __avx_savms64_18 __avx_resms64x_14 __avx_savms64_14 __eprintf __avx_resms64f_14 __addvsi3 __addvdi3 __cpu_indicator_init __ffsdi2 __generic_releasestack __floatunsitf __mulsc3 __avx_resms64x_18 __udivti3 __sse_resms64f_15 __popcountdi2 __avx_savms64f_17 __avx_savms64f_13 __morestack_allocate_stack_space __eqtf2 __generic_morestack __sse_savms64_18 __ashlti3 __sse_savms64_14 __sse_resms64x_16 __fixtfsi __floatuntisf __negtf2 __floattisf __sse_resms64x_12 __generic_morestack_set_initial_sp __absvdi2 __powisf2
DW.ref.__gcc_personality_v0 __clzti2 __sse_resms64fx_14 __fixtfti __ctzdi2 __enable_execute_stack __sse_savms64f_14 __muldc3 __addvti3 __morestack_large_model __subvsi3 __divxc3 __floatuntixf __extendsftf2 __popcount_tab __ctzti2 __avx_resms64fx_15 _DYNAMIC _init __avx_resms64_13 __sse_resms64f_17 __sse_resms64_15 __avx_resms64_17 __trunctfxf2 signal_buffer_list_copy crypto_sign_ed25519_ref10_fe_pow22523 __bid_extendddxf ratchet_identity_key_pair_destroy signal_infos sender_key_record_get_sender_key_state_by_id __bid128_to_uint32_rninta textsecure__device_consistency_code_message__free_unpacked generalized_xeddsa_25519_sign session_state_get_local_identity_key purple_prefs_get_bool __bid_trunctdtf __bid64qq_div g_free session_record_serialize session_builder_free textsecure__session_structure__free_unpacked __bid128_sub all_fast_tests crypto_sign_ed25519_ref10_ge_sub __bid_midpoint256 sender_key_state_get_key_id
group_cipher_set_decryption_callback __bid128_quiet_greater_unordered crypto_sign_ed25519_ref10_ge_p3_to_p2 __binary128_to_bid128 signal_int_list_free __bid64_to_uint32_ceil mprotect@GLIBC_2.2.5 __bid_getd2 __bid64_signaling_not_greater purple_plugin_pref_new_with_label sqlite3_close __bid_power10_index_binexp_128 textsecure__combined_fingerprints__unpack __bid_floatditd signal_protocol_session_store_session displayable_fingerprint_create session_cipher_set_user_data crypto_sign_edwards25519sha512batch_ref10_open axc_buf_list_item_get_buf __bid_round192_39_57 sender_key_state_copy signal_type_unref session_cipher_set_decryption_callback omemo_message_is_encrypted_key_prekey purple_conversation_get_title __bid128_isCanonical axc_db_pre_key_load printf@GLIBC_2.2.5 __bid_fixunstddi __dfp_test_except labelset_validate __bid128_to_int32_rnint lurch_crypto_encrypt_msg_for_addrs __bid128_to_binary64 hkdf_create __bid_gesd2
omemo_storage_chatlist_save lurch_cmd_func signal_message_get_counter __bid128_isInf protobuf_c_message_descriptor_get_field textsecure__signed_pre_key_record_structure__unpack sqlite3_column_int purple_signal_register g_list_find __bid_addtd3 __bid128_fma __bid_extendsdxf lurch_addr_sessions_exist axc_crypto_teardown ec_public_key_list_sort_comparator axc_db_property_set ec_public_key_list_push_back __bid_unordtd2 ratchet_chain_key_get_message_keys gcry_md_open@GCRYPT_1.6 axc_db_create __gcc_personality_v0@GCC_3.3.1 memset@GLIBC_2.2.5 vpool_final session_pre_key_get_key_pair __bid64_quiet_unordered purple_plugin_pref_new_with_name_and_label axc_db_pre_key_remove signal_hmac_sha256_cleanup curve_generate_key_pair sqlite3_reset __bid_unordsd2 sender_key_distribution_message_get_id sender_key_record_add_sender_key_state fe_mont_rhs signal_message_get_body gcry_mac_write@GCRYPT_1.6 snprintf@GLIBC_2.2.5 __bid_truncddsf
signal_protocol_store_context_create omemo_bundle_get_pep_node_name __bid128qd_sub signal_context_set_locking_functions __bid_shiftright128 crypto_sign_ed25519_ref10_fe_1 g_hash_table_get_values device_consistency_signature_get_signature __bid128_quiet_less omemo_devicelist_is_empty __bid_half128 __bid_truncdddf __bid128_quiet_ordered generalized_xveddsa_fast_test __bid64_isInf __bid32_to_binary32 lurch_util_fp_get_printable lurch_id_list_print textsecure__record_structure__free_unpacked __bid64_from_int32 lurch_api_id_list_handler group_session_builder_process_session pthread_sigmask@GLIBC_2.32 scannable_fingerprint_get_remote_stable_identifier group_cipher_get_user_data __bid_truncxfdd axc_db_init_status_set signal_context_set_log_function __bid_nr_digits session_state_has_pending_key_exchange __bid_onehalf192M signal_encrypt xed25519_sign __bid_half64 __bid128_isNaN omemo_message_prepare_decryption session_state_copy
crypto_sign_ed25519_ref10_sc_muladd g_hash_table_destroy xmlnode_get_data g_str_hash __bid128qdd_fma __bid64_quiet_less_equal __bid128_to_binary32 scannable_fingerprint_serialize ceil@GLIBC_2.2.5 signal_protocol_session_load_session textsecure__signal_message__pack_to_buffer signal_log textsecure__sender_key_message__unpack abort@GLIBC_2.2.5 __splitstack_resetcontext pthread_setspecific@GLIBC_2.34 omemo_message_export_encrypted __bid64_to_bid32 fe_montx_to_edy strict_fast_test sqlite3_bind_int session_record_deserialize signal_constant_memcmp omemo_bundle_create __bid64_to_uint64_xfloor jabber_chat_find_by_conv crypto_sign_ed25519_ref10_sc_reduce session_state_get_needs_refresh axc_db_pre_key_store_list ratchet_chain_key_destroy __bid128_to_bid64 crypto_sign_ed25519_ref10_fe_mul __bid128_to_int64_xceil signal_lock device_consistency_signature_list_copy ec_public_key_destroy purple_plugin_register __bid_ltdd2 protobuf_c_service_destroy
…

But is far more convenient, no?

diff --git a/Makefile b/Makefile
index 0b8e94e..6e37a22 100644
--- a/Makefile
+++ b/Makefile
@@ -227,6 +227,15 @@ $(BDIR)/test_lurch_crypto: $(OBJECTS_W_COVERAGE) $(VENDOR_LIBS) $(BDIR)/test_lur
    -Wl,--wrap=axc_session_exists_initiated
    sh -c "set -o pipefail; $@ 2>&1 | grep -Ev ".*CRITICAL.*" | tr -s '\n'" # filter annoying and irrelevant glib output

+verify-symbols: $(BDIR)/lurch.so
+   objdump -t /usr/lib/purple-2/lurch.so |\
+       cut -f 2- |\
+       perl -pe 's/.*? {5,}//g' |\
+       tail -n +5 |\
+       head -n -2 |\
+       xargs echo |\
+       fmt -w 200
+
 test: $(OBJECTS_W_COVERAGE) $(VENDOR_LIBS) $(TEST_TARGETS)

 coverage: test
@@ -240,5 +249,5 @@ clean-all: clean
    $(MAKE) -C "$(LOMEMO_DIR)" clean
    $(MAKE) -C "$(AXC_DIR)" clean-all

-.PHONY: clean clean-all install install-home tarball test coverage
+.PHONY: clean clean-all install install-home tarball test coverage verify-symbols
gdt commented 2 years ago

packaging systems view static builds as a bug, because every time there is any update of any package that can contribute to the static object, the object must be rebuilt, and every time there is an update of the static object, anything that statically includes it must be rebuilt.

If this is "also provide and install a .a alongside the .so", that's ok, but an issue with a question in the title and no discussion is difficult to understand.

ctrlcctrlv commented 2 years ago

@gdt yeah it's just "also provide and install a .a alongside the .so".