15f9996aaSopenharmony_ci#!/bin/bash 25f9996aaSopenharmony_ci# Copyright (c) 2022 Huawei Device Co., Ltd. 35f9996aaSopenharmony_ci# Licensed under the Apache License, Version 2.0 (the "License"); 45f9996aaSopenharmony_ci# you may not use this file except in compliance with the License. 55f9996aaSopenharmony_ci# You may obtain a copy of the License at 65f9996aaSopenharmony_ci# 75f9996aaSopenharmony_ci# http://www.apache.org/licenses/LICENSE-2.0 85f9996aaSopenharmony_ci# 95f9996aaSopenharmony_ci# Unless required by applicable law or agreed to in writing, software 105f9996aaSopenharmony_ci# distributed under the License is distributed on an "AS IS" BASIS, 115f9996aaSopenharmony_ci# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 125f9996aaSopenharmony_ci# See the License for the specific language governing permissions and 135f9996aaSopenharmony_ci# limitations under the License. 145f9996aaSopenharmony_ci 155f9996aaSopenharmony_ciset -e 165f9996aaSopenharmony_ci 175f9996aaSopenharmony_ciret="" 185f9996aaSopenharmony_ci 195f9996aaSopenharmony_cifor obj in "$@"; do 205f9996aaSopenharmony_ci case "${obj}" in 215f9996aaSopenharmony_ci *.a) ret="${ret} --whole_archive ${obj}" ;; 225f9996aaSopenharmony_ci *.o) ret="${ret}" ;; 235f9996aaSopenharmony_ci *) ret="${ret} ${obj}" ;; 245f9996aaSopenharmony_ci esac 255f9996aaSopenharmony_cidone 265f9996aaSopenharmony_ci 275f9996aaSopenharmony_ciecho "${ret}" 28