LA_3902 - Network

本文介绍了一种解决树状网络服务覆盖问题的算法。该算法通过将无向树转换为有向树,并从最深的叶节点开始计算放置服务节点来最小化所需的服务器数量。文中还提供了详细的代码实现。
題意:
一個樹狀網絡,指定一個服務器s,一個距離k,與服務器相距爲k的節點都能被服務到,問服務整個網絡最少要增加多少臺服務器
分析:
這個網絡是無向的,轉成有向的比較好處理,題目給定了一個服務器,可以以這個點爲Root,把這個樹狀網絡變爲有向,然而比較優先的策略是從深度最深的葉子節點開始算距離爲k的位置放置一個服務器,然後更新覆蓋點,這裏只需要處理葉子節點,爲什麼? 因爲,如果葉子節點能被覆蓋的話,那麼非葉子節點要麼是服務器要麼已經被覆蓋了
Code:

#include <cstdio>
#include <cstring>
#include <vector>
#include <algorithm>
using namespace std;

#define MAXN    1000 + 10

int parent[MAXN], visit[MAXN];
vector<int> vertex[MAXN], depth[MAXN];

void conversion(int u, int p, int dep)
{
        visit[u] = 1;
        parent[u] = p;
        
        //is leaf
        if( 1 == vertex[u].size() && p == vertex[u][0] ) {
                depth[dep].push_back(u);
        }
        for(int i = 0; i < vertex[u].size(); i ++) {
                int v = vertex[u][i];
                if( visit[v] ) {
                        continue;
                }
                conversion(v, u, dep+1);
        }
}

inline void dfs(int u, int p, int k)
{
        visit[u] = 1;
        if( !k ) {
                return;
        }
        for(int i = 0; i < vertex[u].size(); i ++) {
                int v = vertex[u][i];
                if( p == v ) {
                        continue;
                }
                dfs(v, u, k-1);
        }
}

int cal(int n, int k, int s)
{
        int sum = 0;
        memset(visit, 0, sizeof(int)*(n+1));
        for(int d = n-1; d > k; d --)  {        //already have a server.
                for(int i = 0; i < depth[d].size(); i ++) {
                        int u = depth[d][i];
                        if( visit[u] ) {
                                continue;
                        }
                        int pu = u;
                        for(int j = 1; j <= k; j ++) {
                                pu = parent[pu];
                        }
                        dfs(pu, -1, k);
                        sum += 1;
                }
        }
        return sum;
}

int main(int argc, char **argv)
{
#ifndef ONLINE_JUDGE
        freopen("test.in", "r", stdin);
#endif
        int n, s, u, v, k, cas;
        scanf("%d", &cas);
        for( ; cas; cas --) {
                scanf("%d %d %d", &n, &s, &k);
                
                // init
                for(int i = 1; i <= n; i ++) {
                        visit[i] = 0;
                        depth[i].erase(depth[i].begin(), depth[i].end());
                        vertex[i].erase(vertex[i].begin(), vertex[i].end());
                }
                
                for(int i = 1; i < n; i ++) {
                        scanf("%d %d", &u, &v);
                        vertex[u].push_back(v);
                        vertex[v].push_back(u);
                }
               
                
                //conversion undirect tree to direct tree
                conversion(s, -1, 0);
                
                printf("%d\n", cal(n, k, s));
                
        }
        return 0;
}

make[10]: Leaving directory '/mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/include/curl' make[9]: Leaving directory '/mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/include/curl' make[9]: Entering directory '/mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/include' make[10]: Entering directory '/mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/include' make[10]: Nothing to be done for 'install-exec-am'. make[10]: Nothing to be done for 'install-data-am'. make[10]: Leaving directory '/mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/include' make[9]: Leaving directory '/mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/include' make[8]: Leaving directory '/mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/include' make[7]: Leaving directory '/mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1' make[6]: Leaving directory '/mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1' make[5]: Leaving directory '/mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1' make[4]: Leaving directory '/mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1' touch /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/.built mkdir -p /mydisk/omada_gateway/bin/mediatek-er706wp-4g_un_v1/packages /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/libcurl/CONTROL /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/pkginfo install -d -m0755 /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/libcurl/usr/lib cp -fpR /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-install/usr/lib/libcurl.so.* /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/libcurl/usr/lib/ find /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/libcurl -name 'CVS' -o -name '.svn' -o -name '.#*' -o -name '*~'| xargs -r rm -rf export CROSS="aarch64-openwrt-linux-musl-" NO_RENAME=1 ; NM="aarch64-openwrt-linux-musl-nm" STRIP="aarch64-openwrt-linux-musl-strip --strip-all" STRIP_KMOD="/mydisk/omada_gateway/scripts/strip-kmod.sh" /mydisk/omada_gateway/scripts/rstrip.sh /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/libcurl rstrip.sh: /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/libcurl/usr/lib/libcurl.so.4.8.0:shared object ( echo "Package: libcurl"; echo "Version: 7.83.1"; DEPENDS=''; for depend in libc libopenssl ca-bundle librt; do DEPENDS=${DEPENDS:+$DEPENDS, }${depend##+}; done; [ -z "$DEPENDS" ] || echo "Depends: $DEPENDS"; echo "Source: package/network/utils/curl"; echo "License: MIT"; echo "LicenseFiles: COPYING"; echo "Section: libs"; echo "Maintainer: Stan Grishin <stangri@melmac.ca>"; echo "Architecture: aarch64_cortex-a53"; echo "Installed-Size: 0"; echo -n "Description: "; . /mydisk/omada_gateway/include/shell.sh; getvar V_Package_libcurl_description | sed -e 's,^[[:space:]]*, ,g'; ) > /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/libcurl/CONTROL/control chmod 644 /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/libcurl/CONTROL/control . /mydisk/omada_gateway/include/shell.sh; (cd /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/libcurl/CONTROL; ) install -d -m0755 /mydisk/omada_gateway/bin/mediatek-er706wp-4g_un_v1/packages ipkg-build -c -o 0 -g 0 /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/libcurl /mydisk/omada_gateway/bin/mediatek-er706wp-4g_un_v1/packages Packaged contents of /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/libcurl into /mydisk/omada_gateway/bin/mediatek-er706wp-4g_un_v1/packages/libcurl_7.83.1_aarch64_cortex-a53.ipk rm -rf /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/tmp-libcurl mkdir -p /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/stamp /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/tmp-libcurl install -d -m0755 /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/tmp-libcurl/usr/lib cp -fpR /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-install/usr/lib/libcurl.so.* /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/tmp-libcurl/usr/lib/ SHELL= /mydisk/omada_gateway/staging_dir/host/bin/flock /mydisk/omada_gateway/tmp/.root-copy.flock -c 'cp -fpR /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/tmp-libcurl/. /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/' rm -rf /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/tmp-libcurl touch /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/stamp/.libcurl_installed echo '4' | cmp -s - /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/pkginfo/libcurl.version || echo '4' > /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/pkginfo/libcurl.version if [ -f /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/pkginfo/curl.default.install.clean ]; then rm -f /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/pkginfo/curl.default.install /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/pkginfo/curl.default.install.clean; fi; echo "libcurl" >> /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/pkginfo/curl.default.install make V=ss -j1 clean-staging make[4]: Entering directory '/mydisk/omada_gateway/package/network/utils/curl' rm -f /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/stamp/.curl_installed make[4]: Leaving directory '/mydisk/omada_gateway/package/network/utils/curl' rm -rf /mydisk/omada_gateway/tmp/stage-curl mkdir -p /mydisk/omada_gateway/tmp/stage-curl/host /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/packages /mydisk/omada_gateway/staging_dir/host/packages install -d -m0755 /mydisk/omada_gateway/tmp/stage-curl/host/bin /mydisk/omada_gateway/tmp/stage-curl/usr/bin /mydisk/omada_gateway/tmp/stage-curl/usr/include /mydisk/omada_gateway/tmp/stage-curl/usr/lib /mydisk/omada_gateway/tmp/stage-curl/usr/lib/pkgconfig install -m0755 /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-install/usr/bin/curl-config /mydisk/omada_gateway/tmp/stage-curl/usr/bin/ cp -fpR /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-install/usr/include/curl /mydisk/omada_gateway/tmp/stage-curl/usr/include/ cp -fpR /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-install/usr/lib/libcurl.{a,so*} /mydisk/omada_gateway/tmp/stage-curl/usr/lib/ cp -fpR /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/libcurl.pc /mydisk/omada_gateway/tmp/stage-curl/usr/lib/pkgconfig/ /mydisk/omada_gateway/staging_dir/host/bin/sed -i -e 's,^\(prefix\|exec_prefix\)=.*,\1=/mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/usr,g' /mydisk/omada_gateway/tmp/stage-curl/usr/bin/curl-config [ -n "-L/mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/usr/lib -L/mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/lib -L/mydisk/omada_gateway/staging_dir/toolchain-aarch64_cortex-a53_gcc-8.4.0_musl-1.2.4/usr/lib -L/mydisk/omada_gateway/staging_dir/toolchain-aarch64_cortex-a53_gcc-8.4.0_musl-1.2.4/lib -Wl,--gc-sections" ] && /mydisk/omada_gateway/staging_dir/host/bin/sed -i -e 's#-L/mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/usr/lib -L/mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/lib -L/mydisk/omada_gateway/staging_dir/toolchain-aarch64_cortex-a53_gcc-8.4.0_musl-1.2.4/usr/lib -L/mydisk/omada_gateway/staging_dir/toolchain-aarch64_cortex-a53_gcc-8.4.0_musl-1.2.4/lib -Wl,--gc-sections##g' /mydisk/omada_gateway/tmp/stage-curl/usr/lib/pkgconfig/libcurl.pc || true ln -sf /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/usr/bin/curl-config /mydisk/omada_gateway/tmp/stage-curl/host/bin/ find /mydisk/omada_gateway/tmp/stage-curl -name '*.la' | xargs -r rm -f; if [ -f /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/packages/curl.list ]; then /mydisk/omada_gateway/scripts/clean-package.sh "/mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/packages/curl.list" "/mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1"; fi if [ -d /mydisk/omada_gateway/tmp/stage-curl ]; then (cd /mydisk/omada_gateway/tmp/stage-curl; find ./ > /mydisk/omada_gateway/tmp/stage-curl.files); SHELL= /mydisk/omada_gateway/staging_dir/host/bin/flock /mydisk/omada_gateway/tmp/.staging-dir.flock -c ' mv /mydisk/omada_gateway/tmp/stage-curl.files /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/packages/curl.list && cp -fpR /mydisk/omada_gateway/tmp/stage-curl/* /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/; '; fi rm -rf /mydisk/omada_gateway/tmp/stage-curl touch /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/stamp/.curl_installed mkdir -p /mydisk/omada_gateway/bin/mediatek-er706wp-4g_un_v1/packages /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/curl/CONTROL /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/pkginfo install -d -m0755 /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/curl/usr/bin install -m0755 /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-install/usr/bin/curl /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/curl/usr/bin/ find /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/curl -name 'CVS' -o -name '.svn' -o -name '.#*' -o -name '*~'| xargs -r rm -rf export CROSS="aarch64-openwrt-linux-musl-" NO_RENAME=1 ; NM="aarch64-openwrt-linux-musl-nm" STRIP="aarch64-openwrt-linux-musl-strip --strip-all" STRIP_KMOD="/mydisk/omada_gateway/scripts/strip-kmod.sh" /mydisk/omada_gateway/scripts/rstrip.sh /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/curl rstrip.sh: /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/curl/usr/bin/curl:executable ( echo "Package: curl"; echo "Version: 7.83.1"; DEPENDS=''; for depend in libc libcurl; do DEPENDS=${DEPENDS:+$DEPENDS, }${depend##+}; done; [ -z "$DEPENDS" ] || echo "Depends: $DEPENDS"; echo "Source: package/network/utils/curl"; echo "License: MIT"; echo "LicenseFiles: COPYING"; echo "Section: net"; echo "Maintainer: Stan Grishin <stangri@melmac.ca>"; echo "Architecture: aarch64_cortex-a53"; echo "Installed-Size: 0"; echo -n "Description: "; . /mydisk/omada_gateway/include/shell.sh; getvar V_Package_curl_description | sed -e 's,^[[:space:]]*, ,g'; ) > /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/curl/CONTROL/control chmod 644 /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/curl/CONTROL/control . /mydisk/omada_gateway/include/shell.sh; (cd /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/curl/CONTROL; ) install -d -m0755 /mydisk/omada_gateway/bin/mediatek-er706wp-4g_un_v1/packages ipkg-build -c -o 0 -g 0 /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/curl /mydisk/omada_gateway/bin/mediatek-er706wp-4g_un_v1/packages Packaged contents of /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-aarch64_cortex-a53/curl into /mydisk/omada_gateway/bin/mediatek-er706wp-4g_un_v1/packages/curl_7.83.1_aarch64_cortex-a53.ipk rm -rf /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/tmp-curl mkdir -p /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/stamp /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/tmp-curl install -d -m0755 /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/tmp-curl/usr/bin install -m0755 /mydisk/omada_gateway/build_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/curl-7.83.1/ipkg-install/usr/bin/curl /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/tmp-curl/usr/bin/ SHELL= /mydisk/omada_gateway/staging_dir/host/bin/flock /mydisk/omada_gateway/tmp/.root-copy.flock -c 'cp -fpR /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/tmp-curl/. /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/' rm -rf /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/tmp-curl touch /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/root-mediatek/stamp/.curl_installed if [ -f /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/pkginfo/curl.default.install.clean ]; then rm -f /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/pkginfo/curl.default.install /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/pkginfo/curl.default.install.clean; fi; echo "curl" >> /mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/pkginfo/curl.default.install make[3]: Leaving directory '/mydisk/omada_gateway/package/network/utils/curl' make[2]: Leaving directory '/mydisk/omada_gateway' package/Makefile:202: recipe for target '/mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/stamp/.package_compile' failed make[1]: *** [/mydisk/omada_gateway/staging_dir/target-aarch64_cortex-a53_musl-1.2.4-er706wp-4g_un_v1/stamp/.package_compile] Error 2 make[1]: Leaving directory '/mydisk/omada_gateway' /mydisk/omada_gateway/include/toplevel.mk:171: recipe for target 'world' failed make: *** [world] Error 2
最新发布
11-18
make[6]: Entering directory '/home/wuyilun/Desktop/CAMEOS/platform/build_dir/target-arm-sigmastar-linux-uclibcgnueabihf/udsd/modules/migrate' ccache_cc -O2 -fno-caller-saves -Wno-implicit-fallthrough -Wno-format-truncation -DAI_ENHANCE -DAI_MAX_DEV=6 -D_GNU_SOURCE -DHARDDISK_STORAGE -DUSR_DEF_AUDIO -I/home/wuyilun/Desktop/CAMEOS/platform/staging_dir/target-arm-sigmastar-linux-uclibcgnueabihf/usr/include -I/home/wuyilun/Desktop/CAMEOS/platform/staging_dir/target-arm-sigmastar-linux-uclibcgnueabihf/include -I/home/wuyilun/Desktop/CAMEOS/platform/../toolchain/ssd920_sdk/arm-sigmastar-linux-uclibcgnueabihf-9.1.0/arm-sigmastar-linux-uclibcgnueabihf/sysroot/usr/include -I/home/wuyilun/Desktop/CAMEOS/platform/../toolchain/ssd920_sdk/arm-sigmastar-linux-uclibcgnueabihf-9.1.0/arm-sigmastar-linux-uclibcgnueabihf/include -g -Wall -Werror -I./ -I./client/ -I/home/wuyilun/Desktop/CAMEOS/platform/staging_dir/target-arm-sigmastar-linux-uclibcgnueabihf/usr/include/libtpsocket -I/home/wuyilun/Desktop/CAMEOS/platform/staging_dir/target-arm-sigmastar-linux-uclibcgnueabihf/usr/include/libtpcom -DTAPO_HUB -DMAX_CAM_DEVICE_NUM=16 -DMAX_24H_RECORD_NUMBER=4 -DINDEPENDENT_WIFI_BOARD -DPROTOCOL_SECURE -DDIAGNOSE_LOG_OPTIMIZE -I../../ -DGZIP_SUPPORT -DBASE64_SUPPORT -DNETWORK_SUPPORT -I./modules/network/ -DBLOCKZONE_SUPPORT -I./modules/blockzone/ -DAUDIO_SUPPORT -I./modules/audio_config/ -DCET_SUPPORT -I./modules/cet/ -DDEVICE_INFO_SUPPORT -I./modules/device_info/ -DHARDDISK_MANAGE_SUPPORT -I./modules/harddisk_manage/ -DMIRRORSCREEN_SUPPORT -I./modules/MirrorScreen/ -DIMAGE_SUPPORT -I./modules/image/ -DSYSTEM_SUPPORT -I./modules/system/ -DLED_SUPPORT -I./modules/led/ -DLENS_MASK_SUPPORT -I./modules/lens_mask/ -DMOTION_DETECTION_SUPPORT -I./modules/motion_detection/ -DTAMPER_DETECTION_SUPPORT -I./modules/tamper_detection/ -DMSG_ALARM_SUPPORT -I./modules/msg_alarm/ -DMSG_ALARM_PLAN_SUPPORT -I./modules/msg_alarm_plan/ -DMSG_PUSH_SUPPORT -I./modules/msg_push/ -DMSG_PUSH_PLAN_SUPPORT -I./modules/msg_push_plan/ -DOSD_SUPPORT -I./modules/OSD/ -DPLAYBACK_SUPPORT -I./modules/playback/ -DHUB_PLAYBACK_SUPPORT -I./modules/hubPlayback/ -DRECORD_PLAN_SUPPORT -I./modules/record_plan/ -DTIMING_REBOOT_SUPPORT -I./modules/timing_reboot/ -DVIDEO_SUPPORT -I./modules/video/ -DCLOUD_SUPPORT -I./modules/cloud_config/ -DUSER_MANAGEMENT_SUPPORT -I./modules/user_management/ -DP2P_SUPPORT -I./modules/p2p/ -DRELAY_SUPPORT -I./modules/relay/ -DAPP_COMPONENT_SUPPORT -I./modules/app_component/ -I./modules/onboarding/ -DTAPO_SIREN_SUPPORT -I./modules/siren/ -DAUDIO_CODEC_SUPPORT_EN -DTAPO_CHILD_CONTROL_SUPPORT -I./modules/child_control/ -DTAPO_DEVICE_LOAD_SUPPORT -I./modules/device_load/ -DTAPO_DEVICE_LOAD_SUPPORT -I./modules/sub1g_stack_test/ -DTAPO_AUTO_UPGRADE_SUPPORT -I./modules/auto_upgrade/ -DTAPO_CHILD_CONTROL_SUPPORT -I./modules/pre_wakeup/ -DTAPO_CHILD_CONTROL_SUPPORT -I./modules/data_download/ -DUSBSHARE_MANAGE_SUPPORT -I./modules/usbshare_manage/ -I./modules/usr_def_audio/ -DAIENHANCE_SUPPORT -I./modules/AIEnhance/ -DTAPO_CHIME_SUPPORT -I./modules/chime/ -DGENERAL_CAMERA_MANAGE_SUPPORT -I./modules/general_camera_manage/ -DCHILD_MIGRATE_EN -I./modules/migrate/ -DUPNP_SUPPORT -I./modules/upnp/ -Wall -Werror -c -o migrate.o migrate.c make[6]: Leaving directory '/home/wuyilun/Desktop/CAMEOS/platform/build_dir/target-arm-sigmastar-linux-uclibcgnueabihf/udsd/modules/migrate' make -C modules/upnp/ MOD_CFLAGS="-DGZIP_SUPPORT -DBASE64_SUPPORT -DNETWORK_SUPPORT -I./modules/network/ -DBLOCKZONE_SUPPORT -I./modules/blockzone/ -DAUDIO_SUPPORT -I./modules/audio_config/ -DCET_SUPPORT -I./modules/cet/ -DDEVICE_INFO_SUPPORT -I./modules/device_info/ -DHARDDISK_MANAGE_SUPPORT -I./modules/harddisk_manage/ -DMIRRORSCREEN_SUPPORT -I./modules/MirrorScreen/ -DIMAGE_SUPPORT -I./modules/image/ -DSYSTEM_SUPPORT -I./modules/system/ -DLED_SUPPORT -I./modules/led/ -DLENS_MASK_SUPPORT -I./modules/lens_mask/ -DMOTION_DETECTION_SUPPORT -I./modules/motion_detection/ -DTAMPER_DETECTION_SUPPORT -I./modules/tamper_detection/ -DMSG_ALARM_SUPPORT -I./modules/msg_alarm/ -DMSG_ALARM_PLAN_SUPPORT -I./modules/msg_alarm_plan/ -DMSG_PUSH_SUPPORT -I./modules/msg_push/ -DMSG_PUSH_PLAN_SUPPORT -I./modules/msg_push_plan/ -DOSD_SUPPORT -I./modules/OSD/ -DPLAYBACK_SUPPORT -I./modules/playback/ -DHUB_PLAYBACK_SUPPORT -I./modules/hubPlayback/ -DRECORD_PLAN_SUPPORT -I./modules/record_plan/ -DTIMING_REBOOT_SUPPORT -I./modules/timing_reboot/ -DVIDEO_SUPPORT -I./modules/video/ -DCLOUD_SUPPORT -I./modules/cloud_config/ -DUSER_MANAGEMENT_SUPPORT -I./modules/user_management/ -DP2P_SUPPORT -I./modules/p2p/ -DRELAY_SUPPORT -I./modules/relay/ -DAPP_COMPONENT_SUPPORT -I./modules/app_component/ -I./modules/onboarding/ -DTAPO_SIREN_SUPPORT -I./modules/siren/ -DAUDIO_CODEC_SUPPORT_EN -DTAPO_CHILD_CONTROL_SUPPORT -I./modules/child_control/ -DTAPO_DEVICE_LOAD_SUPPORT -I./modules/device_load/ -DTAPO_DEVICE_LOAD_SUPPORT -I./modules/sub1g_stack_test/ -DTAPO_AUTO_UPGRADE_SUPPORT -I./modules/auto_upgrade/ -DTAPO_CHILD_CONTROL_SUPPORT -I./modules/pre_wakeup/ -DTAPO_CHILD_CONTROL_SUPPORT -I./modules/data_download/ -DUSBSHARE_MANAGE_SUPPORT -I./modules/usbshare_manage/ -I./modules/usr_def_audio/ -DAIENHANCE_SUPPORT -I./modules/AIEnhance/ -DTAPO_CHIME_SUPPORT -I./modules/chime/ -DGENERAL_CAMERA_MANAGE_SUPPORT -I./modules/general_camera_manage/ -DCHILD_MIGRATE_EN -I./modules/migrate/ -DUPNP_SUPPORT -I./modules/upnp/ -Wall -Werror" make[6]: Entering directory '/home/wuyilun/Desktop/CAMEOS/platform/build_dir/target-arm-sigmastar-linux-uclibcgnueabihf/udsd' make[6]: *** modules/upnp/: No such file or directory. Stop. make[6]: Leaving directory '/home/wuyilun/Desktop/CAMEOS/platform/build_dir/target-arm-sigmastar-linux-uclibcgnueabihf/udsd' make[5]: *** [Makefile:455: modules/upnp/upnp.o] Error 2 make[5]: Leaving directory '/home/wuyilun/Desktop/CAMEOS/platform/build_dir/target-arm-sigmastar-linux-uclibcgnueabihf/udsd' make[4]: *** [Makefile:488: /home/wuyilun/Desktop/CAMEOS/platform/build_dir/target-arm-sigmastar-linux-uclibcgnueabihf/udsd/.built] Error 2 make[4]: Leaving directory '/home/wuyilun/Desktop/CAMEOS/platform/iplatform/private/udsd' make[3]: *** [package/Makefile:228: package/feeds/iplatform/udsd/compile] Error 2 make[3]: Leaving directory '/home/wuyilun/Desktop/CAMEOS/platform' make[2]: *** [package/Makefile:224: /home/wuyilun/Desktop/CAMEOS/platform/staging_dir/target-arm-sigmastar-linux-uclibcgnueabihf/stamp/.package_compile] Error 2 make[2]: Leaving directory '/home/wuyilun/Desktop/CAMEOS/platform' make[1]: *** [/home/wuyilun/Desktop/CAMEOS/platform/include/toplevel.mk:184: world] Error 2 make[1]: Leaving directory '/home/wuyilun/Desktop/CAMEOS/platform' make: *** [Makefile:104: iplatform_world] Error 2
10-28
[root@yfw ~]# cd /opt/openfire/plugins/pade/classes/docs/dist [root@yfw dist]# cd /opt/openfire/plugins/pade/classes/docs/dist/locales [root@yfw locales]# ls -la 总用量 1908 drwxr-xr-x 3 openfire openfire 4096 10月 30 23:41 . drwxr-xr-x 6 openfire openfire 4096 10月 30 23:41 .. -rw-r--r-- 1 openfire openfire 48302 10月 30 23:41 af-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 36466 10月 30 23:40 ar-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 27345 10月 30 23:41 be-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 67775 10月 30 23:40 bg-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 49287 10月 30 23:40 ca-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 30594 10月 30 23:40 cs-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 25551 10月 30 23:40 da-LC_MESSAGES-converse-po.js drwxr-xr-x 2 openfire openfire 12288 10月 30 23:41 dayjs -rw-r--r-- 1 openfire openfire 50529 10月 30 23:41 de-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 44879 10月 30 23:40 el-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 27855 10月 30 23:40 eo-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 45141 10月 30 23:40 es-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 40735 10月 30 23:40 eu-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 28597 10月 30 23:40 fa-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 35547 10月 30 23:40 fi-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 50533 10月 30 23:41 fr-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 49260 10月 30 23:41 gl-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 34554 10月 30 23:40 he-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 23380 10月 30 23:40 hi-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 39898 10月 30 23:40 hu-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 37433 10月 30 23:41 id-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 44376 10月 30 23:40 it-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 47881 10月 30 23:40 ja-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 38543 10月 30 23:40 ko-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 40142 10月 30 23:40 lt-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 26310 10月 30 23:40 mr-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 26391 10月 30 23:41 nb-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 40451 10月 30 23:40 nl_BE-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 30968 10月 30 23:40 nl-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 33513 10月 30 23:40 oc-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 40088 10月 30 23:41 pl-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 40972 10月 30 23:40 pt_BR-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 42459 10月 30 23:40 pt-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 28364 10月 30 23:40 ro-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 67493 10月 30 23:40 ru-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 26347 10月 30 23:40 si-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 26347 10月 30 23:40 sq-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 41184 10月 30 23:40 sv-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 91278 10月 30 23:41 ta-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 30604 10月 30 23:40 th-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 42338 10月 30 23:41 tr-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 63643 10月 30 23:40 ug-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 67511 10月 30 23:40 uk-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 28951 10月 30 23:40 vi-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 44051 10月 30 23:40 zh_CN-LC_MESSAGES-converse-po.js -rw-r--r-- 1 openfire openfire 38537 10月 30 23:40 zh_TW-LC_MESSAGES-converse-po.js [root@yfw locales]#
11-01
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值