当前位置: 首页 > news >正文

数据录入网站开发物联网工程专业

数据录入网站开发,物联网工程专业,宁波网站建设公司哪家口碑好,怎么建设音乐试听网站BUILD.gn文件怎么写#xff0c;Gn Ninja编译一个Hello world程序的例子Demo 作者将狼才鲸创建日期2024-03-11 Ninja安装流程见#xff1a;一个能直接运行的Ninja例子#xff0c;build.ninja文件怎么写#xff1f;Gn安装流程见#xff1a;Ubuntu18.04下安装Gn软件 这是一…BUILD.gn文件怎么写Gn Ninja编译一个Hello world程序的例子Demo 作者将狼才鲸创建日期2024-03-11 Ninja安装流程见一个能直接运行的Ninja例子build.ninja文件怎么写Gn安装流程见Ubuntu18.04下安装Gn软件 这是一个简单的BUILD.gn配置文件 jimubuntu:~/0_Git/third_party_gn/examples/simple_build$ cat BUILD.gn # Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file.executable(hello) {sources [ hello.cc ]deps [:hello_shared,:hello_static,] }shared_library(hello_shared) {sources [hello_shared.cc,hello_shared.h,]defines [ HELLO_SHARED_IMPLEMENTATION ] }static_library(hello_static) {sources [hello_static.cc,hello_static.h,] }这是Gn官方的例子在Gn的源码里面 使用Ubuntu系统安装Git、Ninja、Gn、Clang软件git clone gitgitee.com:openharmony/third_party_gn.git 拉取源码或者https://gitee.com/openharmony/third_party_gn/repository/archive/master.zip 下载源码 cd examples/simple_build/ 下载源码后进入其中的子目录 ls 先看看里面的文件 jimubuntu:~/0_Git/third_party_gn/examples/simple_build$ ls build BUILD.gn hello.cc hello_shared.cc hello_shared.h hello_static.cc hello_static.h README.md tutorialjimubuntu:~/0_Git/third_party_gn/examples/simple_build$ cat hello.cc // Copyright 2014 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file.#include stdio.h#include hello_shared.h #include hello_static.hint main(int argc, char* argv[]) {printf(%s, %s\n, GetStaticText(), GetSharedText());return 0; }gn gen -C out 按Gn规则文件生成Ninja配置文件 jimubuntu:~/0_Git/third_party_gn/examples/simple_build$ gn gen -C out Done. Made 3 targets from 4 files in 45mscd out/ 进入输出目录看看生成的什么内容 jimubuntu:~/0_Git/third_party_gn/examples/simple_build$ tree out/ out/ ├── args.gn ├── build.ninja ├── build.ninja.d ├── obj │ ├── hello.ninja │ ├── hello_shared.ninja │ └── hello_static.ninja └── toolchain.ninja1 directory, 7 filesjimubuntu:~/0_Git/third_party_gn/examples/simple_build$ cat out/build.ninja ninja_required_version 1.7.2rule gncommand ../../../../../../../usr/bin/gn --root./.. -q --C --regeneration gen .pool consoledescription Regenerating ninja filesbuild build.ninja: gngenerator 1depfile build.ninja.dsubninja toolchain.ninjabuild hello_shared: phony ./libhello_shared.so build hello_static: phony obj/libhello_static.a build $:hello: phony hello build $:hello_shared: phony ./libhello_shared.so build $:hello_static: phony obj/libhello_static.abuild all: phony $hello $./libhello_shared.so $obj/libhello_static.adefault allninja 开始编译和make命令类似 jimubuntu:~/0_Git/third_party_gn/examples/simple_build/out$ ninja [6/6] LINK hellojimubuntu:~/0_Git/third_party_gn/examples/simple_build/out$ tree . ├── args.gn ├── build.ninja ├── build.ninja.d ├── hello ├── libhello_shared.so ├── obj │ ├── hello.hello.o │ ├── hello.ninja │ ├── hello_shared.ninja │ ├── hello_static.ninja │ ├── libhello_shared.hello_shared.o │ ├── libhello_static.a │ └── libhello_static.hello_static.o └── toolchain.ninja1 directory, 13 files./hello 运行编译后的可执行文件 jimubuntu:~/0_Git/third_party_gn/examples/simple_build/out$ ./hello Hello, world参考网址 GN环境搭建
http://www.w-s-a.com/news/979307/

相关文章:

  • 门户网站制作费用暴雪公司最新消息
  • 深圳专业建网站公司济南公司做网站的价格
  • 怎么运行自己做的网站网上申请平台怎么申请
  • 旅游公司网站 优帮云新闻近期大事件
  • 电商网站后台报价营销软文小短文
  • 网站建设项目售后服务承诺公司名称邮箱大全
  • 湖南网站建设哪里好做ppt的网站叫什么名字
  • 容城县建设银行网站电子商务网站建设子项目
  • 网站管理助手3.0做淘宝网站用什么软件做
  • 贵阳做网站的公司wordpress趣味插件
  • 自己设置免费网站设计平台南京哪里有做公司网站的
  • 建设公司内网网站的意义自助建站网站的宣传手册
  • 手机建设中网站建立个人网站服务器
  • 网站开发工程师岗位概要网站怎么制作教程
  • 城乡建设主管部门官方网站公司简介模板ppt范文
  • 网站认证必须做么cc0图片素材网站
  • net域名 著名网站国外设计案例网站
  • 淘宝客网站哪里可以做app地推网
  • 宜昌建设厅网站中国最新时事新闻
  • 微网站怎么开发wordpress 发表评论
  • 山东网站建设是什么一页网站首页图如何做
  • 游戏开发与网站开发哪个难万网影
  • 做网站编程语言建筑施工特种证书查询
  • 找人做网站内容自己编辑吗修改wordpress登陆界面
  • 登陆建设银行wap网站湖南网站建设磐石网络答疑
  • 58网站怎么做浏览度才高论坛网站怎么做排名
  • wordpress 手机网站支付京东网站建设的经费预算
  • 自己怎么样做游戏网站做海外贸易网站
  • 建立什么样的网站好制作网页网站代码
  • 岳麓区专业的建设网站公司尚一网常德论坛