当前位置:首页 » 编程软件 » proj编译教程

proj编译教程

发布时间: 2022-04-15 18:41:31

A. cocos2dx proj.win32 怎么编译

1、Python的安装和设置 安装基本上就是下一步, 下一步就好了. 中间安装路径, 我选择的是"C:\Python27\", 等下要用到这个路径. 右键单击“计算机”,选择“属性”----》“高级系统设置”,在“高级”选项卡下选择“环境变量”! 在“系统变量”下选中“Path”

B. 怎么配置source insight使得可以编译C语言程序

source insight使得可以编译C语言程序配置方法:
要想编译c,需要配置Pc Lint。
1、假设source insight的安装目录在d:/pclint8,那么pclin.exe就在这个目录,
所有的*.lnt文件在d:/pclint8/lnt目录下面:
打开菜单:options->custom commands
a) 添加一个新的命令名,例如:Pc Lint
b) 在run 中填入:
d:/pclint8/lint -u -ic:/lint std env-si %f
d:/pclint8 是你的Pclint所在的目录.
c) 在path中填入:
d:/PCLint8/lnt(就是你所有*.lnt文件所在的目录)
d) 勾选下面的选项:
Iconic Window
Capture Output
Save Files First
Parse Links in Output
File, then Line
e) 在Pattern 框中填入:
^/([^ ]*/) /([0-9]+/)
2、把这个命令加入到菜单中即可.
以上配置适用于编译单个文件;要编译多个文件,可以建立一个lnt文件,具体方法如下:
假设我的工程在e:/myproj下面,源文件放在e:/myproj/source下面,头文件放在e:/myproj/include下面;假设source目录下有文件:source1.c,source2.c;include目录下面有incude.h;那么我可以建立这样一个lnt文件:
-i"e:/myproj/include" //头文件寻找路径
e:/myproj/source/source1.c //需要编译的文件1
e:/myproj/source/source2.c //需要编译的文件2
然后保存为test.lnt;把上面配置中的步骤b中的
d:/pclint8/lint -u -ic:/lint std env-si %f
改成:
d:/pclint8/lint -u -ic:/lint std test env-si
注意:
1.如果源文件引用头文件的时候使用的是相对路径或者完整的绝对路径;那么可以不用在lnt文件中加入头文件寻找路径;如果只是给出了头文件的名字,而没有给出任何路径那么加入头文件寻找路径就是必须的了.
2.无论是在si的自定义命令中输入的配置命令还是自己写的lnt文件中的命令都必需仔细;很多时候多个空格或者少个空格都会出错.

C. 把java项目变成可运行的bat文件

你把编译好的项目和bat放到同一个目录下,里面写java 你main函数的名字就好了 追问: 大哥能不能说的详细一点的 回答: bat 文件内写java 你main函数的名字 追问: 我的项目不只一个类,还有外部jar包。你讲的这样是行不通的。 回答: 首先呢,你path下配置好jdk 在cmd中可以直接操作你编译好的main文件使你的程序正常运行,之后呢在你程序的main函数的java文件下,创建一个xxx.bat 文件,里面只写一句话,就是你在cmd中运行你程序的那句 java main函数那个java文件名 补充: 编译好的项目,在WINDOWS下可以这样打包与执行: 1、工程目录设置为 $\proj 2、代码文件放到 $\proj\snake\Frame1.java/**最简单的一个frame*/package snake; import java.awt.*; import java.awt.event.*; import javax.swing.*; public class Frame1{ public static void main(String[] args) { JFrame frame = new JFrame (); frame.addWindowListener( new WindowAdapter() { public void windowClosing( WindowEvent e ) { System.exit(0);}});frame.setVisible(true);}}3、设置manifest.mf 文件,放到目录: $\proj\manifest.mf Main-Class: snake.Main 4、设置批处理文件,此处先编译,后打包,再运行,放到目录 $\proj\play.bat@echo offjavac snake\*.java java -jar snake.jar@echo on追问: 报了错,加载驱动异常。因为我用到了外部jar包。 追问: 这位大哥.。我按着你的步骤做了一下,发现打包之后Main-Class: snake.Main 在 manifest.mf 文件中这句话不见了,我把这句话自己手动加上去了,他还是说找不到这个snake包下的main方法类。能不能给我解释一下?ハ蕶ニ③ 的感言: 虽然不是你说的这样解决的,不过还是非常感谢你了。

D. 如何编译mapserver在windows环境下

编译mapserver的时候一定要选择一个根目录
推荐 C 盘
在C盘下面创建一个projects目录
将你的所以用来支持mapserver编译的支持库文件都放到该目录下面
注:由于mapserver等都是开源的软件。但是都有一定的版权。所以他们不是集成到mapserver下面的,而是有各种支持库文件通过编译说明文件链接
所有文件链接的说明文件在nmake.opt文件中。这是使用vc编译的说明文件。在编译的时候具体选择支持什么库文件都可以在这里说明。

下面是具体的编译环境
gdwin32 的bgd.lib是第一次编译后拷贝过来的运行makemsvcimport.bat
libpng 的libpng.lib,libpngd.lib是第一次编译后拷贝过来的vc6
freetype 的freetype2110_D.lib在vc7下面编译成功
zlib zlib.lib 编译成功在zlib123\contrib\vstudio\vc7用vc7
proj proj.lib 在vc7环境下编译成功
curl libcurl.lib 在vc6编译下成功 C:\projects\curl\lib
gdal gdal.lib 用submake.bat批处理文件执行编译成功
pdflib 用vc7编译成功 C:\projects\PDFlibLite
fcgi 没有成功 将fcgi_config_x86.h改为fcgi_config.h用vc6编译成功
jpeg 没有编译成功将gdal里的拷贝过来
regex 没有编译成功
编译支持库的时候比较艰难
仔细细心的查看各个支持库中的文档目录。一般都会有一个可以通过的编译。
编译的时候也要懂得使用技巧。比如他说找不到库文件或着什么头文件或源文件你都可以从其他地方拷贝一个过来。

附加nmake.opt文件的配置
#
# nmake.opt - MapServer 4.x configuration for MSVC++
#
# This VC++ configuration is used in building MAPSERVER.LIB, MAPSERV.EXE,
# and the other MapServer command-line programs.
#
# To use the makefile:
# - Open a DOS prompt window
# - Run the VCVARS32.BAT script to initialize the VC++ environment variables
# - Start the build with: nmake /f makefile.vc
#
# $Id: nmake.opt,v 1.24 2005/12/08 19:14:48 hobu Exp $
#
# Contents:
# Section I: Mapserver Options (you may want to edit)
# Section II: Support Libraries (you must edit)
# Section III: Debug Flags (no need to edit)
# Section IV: Variable Setup (should not need to edit)
# Section V: UMN GIS System Setup (should not need to edit)
# Section VI: Collect compiler flags
#
########################################################################
# Section I: Mapserver Options
########################################################################
# Uncomment the following to link mapserv.exe withh dll
DLLBUILD=1
# Set the following to point to the current directory.
MS_BASE = C:\projects\mapserver
# Optmization and related compile flags.
# Optimized, with using MSVCRT.
OPTFLAGS = /nologo /MD $(WARNING_LEVEL) $(DEBUG)
#LDFLAGS = /NODEFAULTLIB:msvcrt /NODEFAULTLIB:libcd /DEBUG
# Debug with MSVCRT
#OPTFLAGS = /nologo /Zi /MD $(WARNING_LEVEL) $(DEBUG)
# Optimized, with LIBC.
#OPTFLAGS = /nologo $(WARNING_LEVEL) $(DEBUG)
# Input raster format options:
#
# The lite version of mapserver 4.x supports only GIF, PNG and JPEG data for
# input. If you wish to support many geospatial raster formats for input
# you will need the GDAL support library from http://www.gdal.org/.
# Once built, enable the GDAL flag, and point GDAL_DIR to the directory
# where GDAL was built.
#GDAL=-DUSE_GDAL
#GDAL_DIR=c:\projects\gdal
#
# Input vector format options
#
# The lite version of Mapserver 4.x only suports ESRI shapefiles for input.
#
# The OGR library (part of GDAL) supports a variety of geospatial vector
# formats including mapinfo, Arc/Info binary coverages, S-57, SDTS,
# Microstation DGN (pre-v7), TIGER, UK .NTF. It also include support for
# treating non-spatial tablular data from ODBC, CSV, mysql, Oracle Spatial,
# and PostgreSQL as spatial table with use of the VRT (virtual) driver.
#
# NOTE: Both -DUSE_OGR and -DUSE_GDAL need to be defined if you want to
# use GDAL/OGR for both raster and vector support, but GDAL_DIR needs only
# be defined once.
#
#OGR=-DUSE_OGR
#GDAL_DIR=c:\projects\gdal
# JPEG Input:
# JPEG input for raster layers is also available through GDAL, If you wish
# to build support for JPEG without GDAL, uncomment the following flag
# and provide the full path to the jpeg support library project directory.
# See http://www.ijg.org/ for support library.
JPEG=-DUSE_JPEG
JPEG_DIR=c:/projects/libjpeg
# Output format options:
# If you wish to allow JPEG output maps, uncomment the following flag.
# If not using a GD build with an internal of libjpeg, you will
# also need to uncomment JPEG_DIR and point to it; however, with BGD.DLL
# that is not necessary.
OUTPUT_JPEG=-DUSE_GD_JPEG
JPEG_DIR=c:/projects/libjpeg
# If you wish to allow PNG output maps, uncomment the following flag.
# If not using a GD build with an internal of libpng, you will
# also need to uncomment PNG_DIR and ZLIB_DIR and point to it; however, with
# BGD.DLL that is not necessary.
# See http://www.libpng.org/pub/png/libpng.html for support library.
# See http://www.gzip.org/zlib/ for support library.
OUTPUT_PNG=-DUSE_GD_PNG
PNG_DIR=c:/projects/libpng
ZLIB_DIR=c:/projects/zlib
#flag to indicate the use of zlib library. It is used intially in SVG
#output to compressed files.
ZLIB=-DUSE_ZLIB
# If you wish to allow Windows BMP output maps, uncomment the following flag.
OUTPUT_WBMP=-DUSE_GD_WBMP
# If you wish to have FLASH output, uncomment the following flag and provide
# the full path to the MING support library project directory.
# See http://ming.sourceforge.net/ for support library.
#MING=-DUSE_MING_FLASH
#MING_DIR=c:/projects/ming-0.3beta1

# If you wish to have PDF output, uncomment the following flag and provide the
# full path to the PDF support library project directory.
# See http://www.pdflib.com/ for support library.
PDF=-DUSE_PDF
PDF_DIR=c:/projects/PDFlibLite

# Annotation fonts.
#
# If you wish to annotate your maps with true type fonts unccomment the
# following flag. Provide the full path to the FreeType 2.x external
# support library, unless it is provided within your GD build as is the
# case with BGD.DLL.
# See http://www.freetype.org for support library.
ANNOTATION_FT=-DUSE_GD_FT
FT_DIR=c:/projects/freetype

# Direct connectivity to Postgresql PostGIS.
#
# To turn on direct connectivity to Postgresql PostGIS uncomment the following
# flag and set the full path name to the project directory for the
# Postgresql native Win32 client library.
# See http://www.postgresql.org for support library.
#POSTGIS =-DUSE_POSTGIS
#POSTGIS_DIR =c:/projects/libpq
#Orcale
ORACLE_DIR = c:\Oracle\Ora81
ORACLE=-DUSE_ORACLESPATIAL
# Direct connectivity to ArcSDE.
#
# To turn on direct connectivity to ArcSDE uncomment the following
# flag and set the full path name to the project directory for ArcSDE.
# Since ESRI includes the version number in the name of their libraries
# you may need to change that number in Section III of this configuration
# file.
# See http://www.esri.com/software/arcgis/arcinfo/arcsde/index.html for
# support library
#
#
#SDE_OPT=-DUSE_SDE -DWIN32
#SDE_DIR=c:/my_path_to/arcsde
# EPPL7 Support
#
# This activates ERDAS as well. It is included in the distribution.
# Probably the best raster alternative if
# you've got EPPL7 laying around. See http://www.lmic.state.mn.us/ for
# more information.
# Uncomment out the following flag and set the full path name to the
# epplib.obj file.
#EPPL=-DUSE_EPPL
#EPPL_OBJ=c:/my_path/epplib.obj
# If you want to ignore missing datafile errors uncomment the following
# line. This is especially useful with large tiled datasets that may not
# have complete data for each tile.
IGNORE_MISSING_DATA=-DIGNORE_MISSING_DATA
# If you want to use shape Z and M parameter this option must be set.
# It's OFF by default.
#USE_POINT_Z_M=-DUSE_POINT_Z_M
USE_POINT_Z_M=
#NEED_NONBLOCKING_STDERR=-DNEED_NONBLOCKING_STDERR
ENABLE_STDERR_DEBUG=-DENABLE_STDERR_DEBUG
# If you want antialiasing (note that It requires gd2)
USE_GD_ANTIALIAS=-DUSE_GD_ANTIALIAS
# Enable if you want thread safe locking, not needed for simple CGI.
#THREADS=-DUSE_THREAD
# Use this flag to compile with WMS Server support.
# To find out more about the OpenGIS Web Map Server Specification go to
# http://www.opengis.org/
WMS=-DUSE_WMS_SVR
# Use this flag to compile with WMS Client support. WMS Client support
# allows you to pull layers from other OGIS WMS servers on the interent and
# incorporate them into your map.
# To find out more about the OpenGIS Web Map Server Specification go to
# http://www.opengis.org/
# you need the libcurl library from http://curl.haxx.se/library/c/
# Set the full path to the curl project directory.
# You may also need to the full path to the windows socket library.
#WMSCLIENT= -DUSE_WMS_LYR
CURL_DIR=c:/projects/curl
#CURL_DIR=c:/projects/curl-7.10.7
WINSOCK_LIB = "WSOCK32.LIB"
WINSOCK_LIB = "C:\Program Files\Microsoft Visual Studio\VC98\Lib\WSOCK32.LIB"
# Use -DUSE_WFS_SVR to compile with WFS server support, requires OGR and PROJ4
#WFS=-DUSE_WFS_SVR
# Use -DUSE_WFS_LYR to compile with WFS client support, requires libcurl
#WFSCLIENT= -DUSE_WFS_LYR
# Use -DUSE_WCS_SVR to compile with WCS server support, requires GDAL.
#WCS=-DUSE_WCS_SVR
#libiconv support is used for to support double bytes (see bug 911).
#uncomment the following to build with libiconv support.
#ICONV=-DUSE_ICONV
#
# Reprojecting.
# If you would like mapserver to be able to reproject data from one
# geographic projection to another, uncomment the following flag
# Proj.4 distribution (cartographic projection routines). PROJ.4 is
# also required for all OGC services (WMS, WFS, and WCS).
#
# For PROJ_DIR use full path to Proj.4 distribution
PROJ=-DUSE_PROJ -DUSE_PROJ_API_H
PROJ_DIR=c:\projects\proj
# php Mapscript.
# If you plan to build PHP mapscript uncomment the following flag and
# set the full path to the PHP project directory
#PHP=1
#PHP_DIR=c:\projects\php-4.3.4
# Apparently these aren't as commonplace. Edit the
# following line to reflect the missing functions on your platform.
#
#STRINGS=-DNEED_STRCASECMP -DNEED_STRNCASECMP -DNEED_STRDUP
STRINGS=-DNEED_STRCASECMP -DNEED_STRNCASECMP -DNEED_STRLCAT

########################################################################
# Section II: External Support Libraries
########################################################################
# You will need to set the paths to various support library projects
# that you have compiled.

E. 在avrstudio软件编译过程中,出现了unknow name type proj_char,这个问题怎么解决啊

用的wingcc吧 缺个头文件
#include <avr/pgmspace.h>

F. 如何使用C++Builder编译Delphi使用Obj文件

一直以来,Delphi 都可以用命令行 dcc32 ProjectName.dpr 对项目进行编译链接,非常方便,Delphi对项目文件的参数配置处理的很简单,便于阅读处理起来也很直观,编译的中间文件也很简单(dcu,dcp)。
而C++Builder就没那么幸运了,因为包含了C++的特征,各种编译的中间文件:lib,obj,res,map,tds。后来新版又增加了一些预编译文件:ilc,ild,ilf,...,pch,#00,...等等等等,各种搜索路径(Include Path,Library Path,Browse Path...),要是用bcc32及ilink32手工进行编译链接,命令的参数都足够写上大半天。幸好,在旧版C++Builder中,如果要用命令行编译BCB项目,只要将bpr文件转换为mak文件,再使用make命令进行编译链接也比较方便,不需要过多的处理:
[plain] view plainprint?
bpr2mak -oProject1.mak Project1.bpr
make -fProject1.mak

自从Delphi/C++Builder开始使用 MSBuild* 编译系统后(好像是RAD Studio 2006开始,具体忘记了),Delphi项目在保存为dpr的同时,也会保存一份dproj的项目文件,dpr依旧沿用旧格式,dproj 则以MSBuild规范以XML格式保存,除了可以用旧方式命令行编译dpr外,也可以用:

[plain] view plainprint?
msbuild.exe /t:Rebuild /p:Config=Debug ProjectName.dproj

进行编译,但msbuild必须设定一些环境变量,RAD Studio自带了一个命令行工具已经做好了这些,其实就是设定了以下几个环境变量($(BDS)\bin\rsvars.bat):

[plain] view plainprint?
@SET BDS=C:\Embarcadero\RAD Studio\7.0
@SET BDSCOMMONDIR=C:\Users\Public\Documents\RAD Studio\7.0
@SET FrameworkDir=C:\Windows\Microsoft.NET\Framework\v2.0.50727
@SET FrameworkVersion=v2.0.50727
@SET FrameworkSDKDir=
@SET PATH=%FrameworkDir%;%FrameworkSDKDir%;%PATH%
@SET LANGDIR=EN

C++Builder则又更杯具了一些,bpr2mak.exe工具已经没有了,所以只能采用MSBuild进行命令行编译。更加杯具的是,随着Delphi和BCB被多次转卖收购,新版本的发布似乎总会有各种各样的Bug,比如手头的RAD Studio 2009进行命令行编译,Delphi正常,BCB则报出超过100个错误,类似如下:

[plain] view plainprint?
C:\Embarcadero\RAD Studio\7.0\Bin\CodeGear.Cpp.Targets(2175,3): error : Error: Unresolved external '__fastcall Strhlpr::UnicodeFree(System::UnicodeString&)' referenced from C:\EMBARCADERO\RAD STUDIO\7.0\LIB\DEBUG\VCLE.LIB|ustring
C:\Embarcadero\RAD Studio\7.0\Bin\CodeGear.Cpp.Targets(2175,3): error : Error: Unresolved external 'Typinfo::BooleanIdents' referenced from C:\EMBARCADERO\RAD STUDIO\7.0\LIB\DEBUG\VCLE.LIB|vclinit

检查了一下发现编译过程(bcc32.exe)没有问题,只是在ilink32.exe链接过程中报错,在IDE中打开此项目进行编译,查看Message->Output窗口,比较两者的ilink32命令行参数,发现两者有两个地方有明显差异,一个是IDE生成的命令中没有类似 C:\Embarcadero\RAD Studio\7.0\lib\EN\debug 的路径(指的是EN这个目录,去除上面rsvars.bat中的@SET LANGDIR=EN 就可以避免产生这样的搜索路径) ,但是虽然这个目录不存在,也应该不至于导致出错。第二个差异是缺少了rtl.bpi和vcl.bpi的附加obj参数,解决办法是在$(BDS)\bin目录中找到 CodeGear.Cpp.Targets 文件,用记事本打开,搜索字符“memmgr.lib“,在前面加上"rtl.bpi;vcl.bpi" (用;分隔,不含引号),一共有两处要修改。或者查找 "c0w32",在后面加上 "rtl.bpi;vcl.bpi",只有一处修改 —— 因为IDE的命令行中 rtl.bpi vcl.bpi是在c0w32和memmgr.lib中间的。—— (注意:在XE2中,加在c0w32后面已经不管用了,编译会报另一个错误VCL.BPIW.OBJ不存在,Targets文件有很大变化,可能参数的位置变动过了,导致与其他参数混在一起,所以还是加到memmgr.lib处更加合理)。

一些组件包比如DevExpress的Package,没有dproj或者cproj 项目文件,只能通过IDE进行转换,但坑爹的是bpk在好几个版本以前(CRS 2007?)已经不支持bpk项目,根本打不开也谈不上转换了,但它其实是一个make文件,可惜用make命令编译还是要出错,不想去研究了。总之,BCB永远活在Delphi的阴影下。

G. 头文件和源文件有什么区别

头文件和源文件的区别表现在:后缀不同、内容不同。

1、后缀不同

后缀为.h的文件是头文件。

后缀为.c的文件是源文件,内含函数实现,变量定义等内容。

2、内容不同

头文件用来写类的声明(包括类的成员的声明和方法声明)、函数原型、#define常数等。

源文件主要写实现头文件中已经声明的那些函数的具体代码。



头文件的组成

头文件一般由四部分内容组成:

(1)头文件开头处的版权和版本声明;

(2)预处理块;

(3)inline函数的定义;

(4)函数和类结构声明等。

在头文件中,用ifndef/define/endif结构产生预处理块,用#include格式来引用库的头文件。头文件的这种结构,是利用C语言进行开发软件所通常具备的,属于公有知识。

H. android环境下cocos2dx-3.13.1,新建项目后proj.android下没有build_native.py脚本文件,如何编译项目

好像最近几个版本不能使用build_native.py来build c++内容了,你这个项目都没这个文件应该是完全取消了这个项目的生成方式。不如你试试命令行:
cocos compile -p android
如果不行,最好看一下官方怎么说的。

热点内容
安卓苹果通讯录怎么同步 发布:2025-03-17 09:58:12 浏览:172
ai缓存 发布:2025-03-17 09:48:27 浏览:920
翘嘴水滴轮什么配置 发布:2025-03-17 09:47:34 浏览:581
小蚁摄像机如何云存储 发布:2025-03-17 09:42:42 浏览:816
如何修改自己的名字和密码 发布:2025-03-17 09:32:20 浏览:787
宝马3系枪灰色轮毂是哪个配置 发布:2025-03-17 09:28:17 浏览:513
鸿蒙系统退回安卓系统怎么备份 发布:2025-03-17 09:14:33 浏览:614
数据库服务公司 发布:2025-03-17 08:56:43 浏览:495
我的世界服务器加载不了区块 发布:2025-03-17 08:56:39 浏览:817
如何给无线路由器设置密码 发布:2025-03-17 08:51:40 浏览:886