|
| 1 | +# Licensed to the Apache Software Foundation (ASF) under one |
| 2 | +# or more contributor license agreements. See the NOTICE file |
| 3 | +# distributed with this work for additional information |
| 4 | +# regarding copyright ownership. The ASF licenses this file |
| 5 | +# to you under the Apache License, Version 2.0 (the |
| 6 | +# "License"); you may not use this file except in compliance |
| 7 | +# with the License. You may obtain a copy of the License at |
| 8 | +# |
| 9 | +# http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | +# |
| 11 | +# Unless required by applicable law or agreed to in writing, |
| 12 | +# software distributed under the License is distributed on an |
| 13 | +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| 14 | +# KIND, either express or implied. See the License for the |
| 15 | +# specific language governing permissions and limitations |
| 16 | +# under the License. |
| 17 | + |
| 18 | +set(ICEBERG_REST_SOURCES rest_catalog.cc) |
| 19 | + |
| 20 | +set(ICEBERG_REST_STATIC_BUILD_INTERFACE_LIBS) |
| 21 | +set(ICEBERG_REST_SHARED_BUILD_INTERFACE_LIBS) |
| 22 | +set(ICEBERG_REST_STATIC_INSTALL_INTERFACE_LIBS) |
| 23 | +set(ICEBERG_REST_SHARED_INSTALL_INTERFACE_LIBS) |
| 24 | + |
| 25 | +list(APPEND ICEBERG_REST_STATIC_BUILD_INTERFACE_LIBS |
| 26 | + "$<IF:$<TARGET_EXISTS:iceberg_static>,iceberg_static,iceberg_shared>" cpr::cpr) |
| 27 | +list(APPEND ICEBERG_REST_SHARED_BUILD_INTERFACE_LIBS |
| 28 | + "$<IF:$<TARGET_EXISTS:iceberg_shared>,iceberg_shared,iceberg_static>" cpr::cpr) |
| 29 | +list(APPEND |
| 30 | + ICEBERG_REST_STATIC_INSTALL_INTERFACE_LIBS |
| 31 | + "$<IF:$<TARGET_EXISTS:Iceberg::iceberg_static>,Iceberg::iceberg_static,Iceberg::iceberg_shared>" |
| 32 | + "$<IF:$<BOOL:${CPR_VENDORED}>,Iceberg::cpr,cpr::cpr>") |
| 33 | +list(APPEND |
| 34 | + ICEBERG_REST_SHARED_INSTALL_INTERFACE_LIBS |
| 35 | + "$<IF:$<TARGET_EXISTS:Iceberg::iceberg_shared>,Iceberg::iceberg_shared,Iceberg::iceberg_static>" |
| 36 | + "$<IF:$<BOOL:${CPR_VENDORED}>,Iceberg::cpr,cpr::cpr>") |
| 37 | + |
| 38 | +add_iceberg_lib(iceberg_rest |
| 39 | + SOURCES |
| 40 | + ${ICEBERG_REST_SOURCES} |
| 41 | + SHARED_LINK_LIBS |
| 42 | + ${ICEBERG_REST_SHARED_BUILD_INTERFACE_LIBS} |
| 43 | + STATIC_LINK_LIBS |
| 44 | + ${ICEBERG_REST_STATIC_BUILD_INTERFACE_LIBS} |
| 45 | + STATIC_INSTALL_INTERFACE_LIBS |
| 46 | + ${ICEBERG_REST_STATIC_INSTALL_INTERFACE_LIBS} |
| 47 | + SHARED_INSTALL_INTERFACE_LIBS |
| 48 | + ${ICEBERG_REST_SHARED_INSTALL_INTERFACE_LIBS}) |
| 49 | + |
| 50 | +iceberg_install_all_headers(iceberg/catalog/rest) |
0 commit comments