CMakeLists.txt revision 3ff30b27
1229fce07SDmitri Tikhonov# Copyright (c) 2017 - 2019 LiteSpeed Technologies Inc.  See LICENSE.
250aadb33SDmitri TikhonovSET(lsquic_STAT_SRCS
35392f7a3SLiteSpeed Tech    ls-qpack/lsqpack.c
450aadb33SDmitri Tikhonov    lsquic_alarmset.c
55392f7a3SLiteSpeed Tech    lsquic_arr.c
65392f7a3SLiteSpeed Tech    lsquic_attq.c
75392f7a3SLiteSpeed Tech    lsquic_bbr.c
85392f7a3SLiteSpeed Tech    lsquic_buf.c
95392f7a3SLiteSpeed Tech    lsquic_bw_sampler.c
105392f7a3SLiteSpeed Tech    lsquic_cfcw.c
1150aadb33SDmitri Tikhonov    lsquic_chsk_stream.c
125392f7a3SLiteSpeed Tech    lsquic_conn.c
135392f7a3SLiteSpeed Tech    lsquic_crt_compress.c
1450aadb33SDmitri Tikhonov    lsquic_crypto.c
155392f7a3SLiteSpeed Tech    lsquic_cubic.c
165392f7a3SLiteSpeed Tech    lsquic_di_error.c
175392f7a3SLiteSpeed Tech    lsquic_di_hash.c
185392f7a3SLiteSpeed Tech    lsquic_di_nocopy.c
195392f7a3SLiteSpeed Tech    lsquic_enc_sess_common.c
205392f7a3SLiteSpeed Tech    lsquic_enc_sess_ietf.c
215392f7a3SLiteSpeed Tech    lsquic_eng_hist.c
225392f7a3SLiteSpeed Tech    lsquic_engine.c
235392f7a3SLiteSpeed Tech    lsquic_ev_log.c
245392f7a3SLiteSpeed Tech    lsquic_frab_list.c
255392f7a3SLiteSpeed Tech    lsquic_frame_common.c
265392f7a3SLiteSpeed Tech    lsquic_frame_reader.c
275392f7a3SLiteSpeed Tech    lsquic_frame_writer.c
285392f7a3SLiteSpeed Tech    lsquic_full_conn.c
295392f7a3SLiteSpeed Tech    lsquic_full_conn_ietf.c
305392f7a3SLiteSpeed Tech    lsquic_global.c
3150aadb33SDmitri Tikhonov    lsquic_handshake.c
325392f7a3SLiteSpeed Tech    lsquic_hash.c
335392f7a3SLiteSpeed Tech    lsquic_hcsi_reader.c
345392f7a3SLiteSpeed Tech    lsquic_hcso_writer.c
355392f7a3SLiteSpeed Tech    lsquic_headers_stream.c
365392f7a3SLiteSpeed Tech    lsquic_hkdf.c
375392f7a3SLiteSpeed Tech    lsquic_hspack_valid.c
385392f7a3SLiteSpeed Tech    lsquic_http1x_if.c
3950aadb33SDmitri Tikhonov    lsquic_logger.c
4050aadb33SDmitri Tikhonov    lsquic_malo.c
415392f7a3SLiteSpeed Tech    lsquic_min_heap.c
425392f7a3SLiteSpeed Tech    lsquic_mini_conn.c
435392f7a3SLiteSpeed Tech    lsquic_mini_conn_ietf.c
445392f7a3SLiteSpeed Tech    lsquic_minmax.c
4550aadb33SDmitri Tikhonov    lsquic_mm.c
465392f7a3SLiteSpeed Tech    lsquic_pacer.c
475392f7a3SLiteSpeed Tech    lsquic_packet_common.c
485392f7a3SLiteSpeed Tech    lsquic_packet_gquic.c
495392f7a3SLiteSpeed Tech    lsquic_packet_in.c
505392f7a3SLiteSpeed Tech    lsquic_packet_out.c
515392f7a3SLiteSpeed Tech    lsquic_packints.c
525392f7a3SLiteSpeed Tech    lsquic_parse_Q046.c
535392f7a3SLiteSpeed Tech    lsquic_parse_common.c
545392f7a3SLiteSpeed Tech    lsquic_parse_gquic_be.c
555392f7a3SLiteSpeed Tech    lsquic_parse_gquic_common.c
565392f7a3SLiteSpeed Tech    lsquic_parse_ietf_v1.c
575392f7a3SLiteSpeed Tech    lsquic_parse_iquic_common.c
585392f7a3SLiteSpeed Tech    lsquic_pr_queue.c
595392f7a3SLiteSpeed Tech    lsquic_purga.c
605392f7a3SLiteSpeed Tech    lsquic_qdec_hdl.c
615392f7a3SLiteSpeed Tech    lsquic_qenc_hdl.c
625392f7a3SLiteSpeed Tech    lsquic_qlog.c
6350aadb33SDmitri Tikhonov    lsquic_rechist.c
6450aadb33SDmitri Tikhonov    lsquic_rtt.c
6550aadb33SDmitri Tikhonov    lsquic_send_ctl.c
6650aadb33SDmitri Tikhonov    lsquic_senhist.c
675392f7a3SLiteSpeed Tech    lsquic_set.c
6850aadb33SDmitri Tikhonov    lsquic_sfcw.c
695392f7a3SLiteSpeed Tech    lsquic_shsk_stream.c
705392f7a3SLiteSpeed Tech    lsquic_spi.c
715392f7a3SLiteSpeed Tech    lsquic_stock_shi.c
725392f7a3SLiteSpeed Tech    lsquic_str.c
7350aadb33SDmitri Tikhonov    lsquic_stream.c
745392f7a3SLiteSpeed Tech    lsquic_tokgen.c
755392f7a3SLiteSpeed Tech    lsquic_trans_params.c
7650aadb33SDmitri Tikhonov    lsquic_util.c
775392f7a3SLiteSpeed Tech    lsquic_varint.c
7850aadb33SDmitri Tikhonov    lsquic_version.c
795392f7a3SLiteSpeed Tech)
805392f7a3SLiteSpeed Tech
815392f7a3SLiteSpeed Techset_source_files_properties(ls-qpack/lsqpack.c PROPERTIES COMPILE_FLAGS -Wno-uninitialized)
8250aadb33SDmitri Tikhonov
835392f7a3SLiteSpeed Techinclude_directories(ls-qpack)
845392f7a3SLiteSpeed Tech
855392f7a3SLiteSpeed TechIF(PROJECT_NAME STREQUAL "openlitespeed")
865392f7a3SLiteSpeed Tech    INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/spdy)
875392f7a3SLiteSpeed TechELSE()
885392f7a3SLiteSpeed Tech    SET(lsquic_STAT_SRCS ${lsquic_STAT_SRCS}
895392f7a3SLiteSpeed Tech        lsquic_xxhash.c
905392f7a3SLiteSpeed Tech        ../lshpack/lshpack.c
915392f7a3SLiteSpeed Tech    )
925392f7a3SLiteSpeed TechENDIF()
9350aadb33SDmitri Tikhonov
945392f7a3SLiteSpeed TechADD_CUSTOM_COMMAND(
953ff30b27SDmitri Tikhonov    OUTPUT ${CMAKE_CURRENT_SOURCE_DIR}/lsquic_versions_to_string.c
963ff30b27SDmitri Tikhonov    COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/gen-verstrs
973ff30b27SDmitri Tikhonov    ARGS ${CMAKE_CURRENT_SOURCE_DIR}/../../include/lsquic.h ${CMAKE_CURRENT_SOURCE_DIR}/lsquic_versions_to_string.c
983ff30b27SDmitri Tikhonov    DEPENDS ./gen-verstrs ${CMAKE_CURRENT_SOURCE_DIR}/../../include/lsquic.h
995392f7a3SLiteSpeed Tech)
1005392f7a3SLiteSpeed TechSET(lsquic_STAT_SRCS ${lsquic_STAT_SRCS} lsquic_versions_to_string.c)
10150aadb33SDmitri Tikhonov
102bea64822SDmitri TikhonovSET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DXXH_HEADER_NAME=\\\"lsquic_xxhash.h\\\"")
1035392f7a3SLiteSpeed TechSET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DLSQPACK_ENC_LOGGER_HEADER=\\\"lsquic_qpack_enc_logger.h\\\"")
1045392f7a3SLiteSpeed TechSET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DLSQPACK_DEC_LOGGER_HEADER=\\\"lsquic_qpack_dec_logger.h\\\"")
10550aadb33SDmitri Tikhonov
10650aadb33SDmitri Tikhonovadd_library(lsquic STATIC ${lsquic_STAT_SRCS} )
10750aadb33SDmitri Tikhonov
108