Disable default text=auto .gitattributes
Fix makefile.vc and *.bat EOL-s according to .gitattributes. Update .editorconfig to enforce CRLF for *.bat, makefile.vc and config.h.vc*.
This commit is contained in:
parent
67ba5c65a1
commit
4a55d767b2
|
@ -14,15 +14,27 @@ indent_style = space
|
|||
indent_size = 4
|
||||
trim_trailing_whitespace = true
|
||||
|
||||
[*.{sln,*proj,*proj.filters,rc,rc2}]
|
||||
[{*.h.vc*}]
|
||||
charset = utf-8
|
||||
end_of_line = crlf
|
||||
insert_final_newline = true
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
trim_trailing_whitespace = true
|
||||
|
||||
[*.{bat,sln,*proj,*proj.filters,rc,rc2}]
|
||||
charset = unset
|
||||
end_of_line = crlf
|
||||
insert_final_newline = unset
|
||||
indent_style = unset
|
||||
indent_size = unset
|
||||
|
||||
[{makefile.vc,nmake.opt}]
|
||||
end_of_line = crlf
|
||||
indent_style = tab
|
||||
|
||||
[{configure,configure.*,config.*,*.{sh,yml}}]
|
||||
indent_size = 2
|
||||
|
||||
[{GNUmakefile,*.{in,opt,vc}}]
|
||||
[{GNUmakefile,*.in}]
|
||||
indent_style = tab
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
# Set the default behavior, in case people don't have core.autocrlf set.
|
||||
* text=auto
|
||||
# Do NOT set the default behavior, in case people don't have core.autocrlf set.
|
||||
# This may lead to implicit modification of certain files (eg. test data) during git clone.
|
||||
#* text=auto
|
||||
|
||||
# Declare files that will always have LF line endings on checkout.
|
||||
*.m4 text eol=lf
|
|
@ -1,15 +1,15 @@
|
|||
|
||||
OBJ = dodsdataset2.obj
|
||||
|
||||
GDAL_ROOT = ..\..
|
||||
|
||||
EXTRAFLAGS = -I$(DODS_DIR) -I$(DODS_DIR)\include -I$(DODS_DIR)\include\gnu -I$(DODS_DIR)\include\xdr -I$(DODS_DIR)\include\pthreads /DWIN32 /DWIN32_LEAN_AND_MEAN -DFRMT_dods $(DODS_FLAGS) /GR
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
xcopy /D /Y *.obj ..\o
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
|
||||
|
||||
OBJ = dodsdataset2.obj
|
||||
|
||||
GDAL_ROOT = ..\..
|
||||
|
||||
EXTRAFLAGS = -I$(DODS_DIR) -I$(DODS_DIR)\include -I$(DODS_DIR)\include\gnu -I$(DODS_DIR)\include\xdr -I$(DODS_DIR)\include\pthreads /DWIN32 /DWIN32_LEAN_AND_MEAN -DFRMT_dods $(DODS_FLAGS) /GR
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
xcopy /D /Y *.obj ..\o
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
|
||||
|
|
|
@ -1,54 +1,54 @@
|
|||
GDAL_ROOT = ..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
OBJ = oci_wrapper.obj \
|
||||
georaster_dataset.obj \
|
||||
georaster_rasterband.obj \
|
||||
georaster_wrapper.obj \
|
||||
cpl_vsil_ocilob.obj
|
||||
|
||||
PLUGIN_DLL = gdal_GEOR.dll
|
||||
|
||||
!IFDEF JPEG_SUPPORTED
|
||||
!IFDEF JPEG_EXTERNAL_LIB
|
||||
JPEG_FLAGS = -I$(JPEGDIR) -DJPEG_SUPPORTED
|
||||
!ELSE
|
||||
JPEG_FLAGS = -I..\jpeg\libjpeg -DJPEG_SUPPORTED
|
||||
JPEG_LIB = ..\jpeg\libjpeg\libjpeg.lib
|
||||
!ENDIF
|
||||
!ENDIF
|
||||
|
||||
!IFDEF ZLIB_EXTERNAL_LIB
|
||||
ZLIB_FLAGS = $(ZLIB_INC)
|
||||
!ELSE
|
||||
ZLIB_FLAGS = -I..\zlib
|
||||
ZLIB_LIB = ..\zlib\*.obj
|
||||
!ENDIF
|
||||
|
||||
EXTRAFLAGS = $(OCI_INCLUDE) $(ZLIB_FLAGS) $(JPEG_FLAGS)
|
||||
|
||||
default: $(OBJ)
|
||||
xcopy /D /Y *.obj ..\o
|
||||
cd ..
|
||||
|
||||
fastread:
|
||||
cl $(OPTFLAGS) fastread.c $(OCI_INCLUDE) $(OCI_LIB)
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del *.dll
|
||||
-del *.exp
|
||||
-del *.lib
|
||||
-del *.manifest
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll $(LDEBUG) /out:$(PLUGIN_DLL) $(OBJ) $(GDALLIB) $(OCI_LIB) $(ZLIB_LIB) \
|
||||
..\jpeg\vsidataio.obj $(JPEG_LIB)
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest -outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
GDAL_ROOT = ..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
OBJ = oci_wrapper.obj \
|
||||
georaster_dataset.obj \
|
||||
georaster_rasterband.obj \
|
||||
georaster_wrapper.obj \
|
||||
cpl_vsil_ocilob.obj
|
||||
|
||||
PLUGIN_DLL = gdal_GEOR.dll
|
||||
|
||||
!IFDEF JPEG_SUPPORTED
|
||||
!IFDEF JPEG_EXTERNAL_LIB
|
||||
JPEG_FLAGS = -I$(JPEGDIR) -DJPEG_SUPPORTED
|
||||
!ELSE
|
||||
JPEG_FLAGS = -I..\jpeg\libjpeg -DJPEG_SUPPORTED
|
||||
JPEG_LIB = ..\jpeg\libjpeg\libjpeg.lib
|
||||
!ENDIF
|
||||
!ENDIF
|
||||
|
||||
!IFDEF ZLIB_EXTERNAL_LIB
|
||||
ZLIB_FLAGS = $(ZLIB_INC)
|
||||
!ELSE
|
||||
ZLIB_FLAGS = -I..\zlib
|
||||
ZLIB_LIB = ..\zlib\*.obj
|
||||
!ENDIF
|
||||
|
||||
EXTRAFLAGS = $(OCI_INCLUDE) $(ZLIB_FLAGS) $(JPEG_FLAGS)
|
||||
|
||||
default: $(OBJ)
|
||||
xcopy /D /Y *.obj ..\o
|
||||
cd ..
|
||||
|
||||
fastread:
|
||||
cl $(OPTFLAGS) fastread.c $(OCI_INCLUDE) $(OCI_LIB)
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del *.dll
|
||||
-del *.exp
|
||||
-del *.lib
|
||||
-del *.manifest
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll $(LDEBUG) /out:$(PLUGIN_DLL) $(OBJ) $(GDALLIB) $(OCI_LIB) $(ZLIB_LIB) \
|
||||
..\jpeg\vsidataio.obj $(JPEG_LIB)
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest -outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
OBJ = clock.obj degrib1.obj degrib2.obj inventory.obj metaname.obj myerror.obj filedatasource.obj memorydatasource.obj grib1tab.obj myutil.obj metaparse.obj weather.obj metaprint.obj grib2api.obj myassert.obj scan.obj tendian.obj hazard.obj
|
||||
|
||||
EXTRAFLAGS = -I ../g2clib $(SOFTWARNFLAGS)
|
||||
|
||||
GDAL_ROOT = ..\..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
xcopy /D /Y *.obj ..\..\..\o
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
OBJ = clock.obj degrib1.obj degrib2.obj inventory.obj metaname.obj myerror.obj filedatasource.obj memorydatasource.obj grib1tab.obj myutil.obj metaparse.obj weather.obj metaprint.obj grib2api.obj myassert.obj scan.obj tendian.obj hazard.obj
|
||||
|
||||
EXTRAFLAGS = -I ../g2clib $(SOFTWARNFLAGS)
|
||||
|
||||
GDAL_ROOT = ..\..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
xcopy /D /Y *.obj ..\..\..\o
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
|
|
|
@ -1,15 +1,15 @@
|
|||
OBJ = gridtemplates.obj drstemplates.obj pdstemplates.obj gbits.obj g2_free.obj g2_unpack1.obj g2_unpack2.obj g2_unpack3.obj g2_unpack4.obj g2_unpack5.obj g2_unpack6.obj g2_unpack7.obj g2_info.obj g2_getfld.obj simunpack.obj comunpack.obj pack_gp.obj reduce.obj specunpack.obj rdieee.obj mkieee.obj int_power.obj simpack.obj compack.obj cmplxpack.obj misspack.obj pngunpack.obj dec_png.obj \
|
||||
dec_jpeg2000.obj jpcunpack.obj
|
||||
|
||||
|
||||
EXTRAFLAGS = -I ../../../png/libpng -I ../../../zlib -DUSE_PNG $(SOFTWARNFLAGS)
|
||||
|
||||
GDAL_ROOT = ..\..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
xcopy /D /Y *.obj ..\..\..\o
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
OBJ = gridtemplates.obj drstemplates.obj pdstemplates.obj gbits.obj g2_free.obj g2_unpack1.obj g2_unpack2.obj g2_unpack3.obj g2_unpack4.obj g2_unpack5.obj g2_unpack6.obj g2_unpack7.obj g2_info.obj g2_getfld.obj simunpack.obj comunpack.obj pack_gp.obj reduce.obj specunpack.obj rdieee.obj mkieee.obj int_power.obj simpack.obj compack.obj cmplxpack.obj misspack.obj pngunpack.obj dec_png.obj \
|
||||
dec_jpeg2000.obj jpcunpack.obj
|
||||
|
||||
|
||||
EXTRAFLAGS = -I ../../../png/libpng -I ../../../zlib -DUSE_PNG $(SOFTWARNFLAGS)
|
||||
|
||||
GDAL_ROOT = ..\..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
xcopy /D /Y *.obj ..\..\..\o
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
GDAL_ROOT = ..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default:
|
||||
cd degrib && $(MAKE) /f makefile.vc && cd ..
|
||||
cd g2clib && $(MAKE) /f makefile.vc && cd ..
|
||||
|
||||
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default:
|
||||
cd degrib && $(MAKE) /f makefile.vc && cd ..
|
||||
cd g2clib && $(MAKE) /f makefile.vc && cd ..
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -1,37 +1,37 @@
|
|||
|
||||
OBJ = gribdataset.obj gribcreatecopy.obj
|
||||
|
||||
GDAL_ROOT = ..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
!IF DEFINED(PNG_LIB)
|
||||
LINK_PNG = $(PNG_LIB)
|
||||
!ELSE
|
||||
LINK_PNG = ..\png\libpng\*.obj
|
||||
!ENDIF
|
||||
|
||||
!IFDEF ZLIB_EXTERNAL_LIB
|
||||
LINK_ZLIB = $(ZLIB_LIB)
|
||||
!ELSE
|
||||
LINK_ZLIB = ..\zlib\*.obj
|
||||
!ENDIF
|
||||
|
||||
default: $(OBJ)
|
||||
cd degrib && $(MAKE) /f makefile.vc && cd ..
|
||||
xcopy /D /Y *.obj ..\o
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del degrib\degrib\*.obj
|
||||
-del degrib\g2clib\*.obj
|
||||
-del *.dll
|
||||
-del *.exp
|
||||
-del *.lib
|
||||
|
||||
plugin: gdal_GRIB.dll
|
||||
|
||||
gdal_GRIB.dll: default
|
||||
link /dll $(LDEBUG) /out:gdal_GRIB.dll \
|
||||
$(OBJ) degrib\degrib\*.obj degrib\g2clib\*.obj \
|
||||
$(GDAL_ROOT)/gdal_i.lib $(LINK_PNG) $(LINK_ZLIB)
|
||||
|
||||
OBJ = gribdataset.obj gribcreatecopy.obj
|
||||
|
||||
GDAL_ROOT = ..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
!IF DEFINED(PNG_LIB)
|
||||
LINK_PNG = $(PNG_LIB)
|
||||
!ELSE
|
||||
LINK_PNG = ..\png\libpng\*.obj
|
||||
!ENDIF
|
||||
|
||||
!IFDEF ZLIB_EXTERNAL_LIB
|
||||
LINK_ZLIB = $(ZLIB_LIB)
|
||||
!ELSE
|
||||
LINK_ZLIB = ..\zlib\*.obj
|
||||
!ENDIF
|
||||
|
||||
default: $(OBJ)
|
||||
cd degrib && $(MAKE) /f makefile.vc && cd ..
|
||||
xcopy /D /Y *.obj ..\o
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del degrib\degrib\*.obj
|
||||
-del degrib\g2clib\*.obj
|
||||
-del *.dll
|
||||
-del *.exp
|
||||
-del *.lib
|
||||
|
||||
plugin: gdal_GRIB.dll
|
||||
|
||||
gdal_GRIB.dll: default
|
||||
link /dll $(LDEBUG) /out:gdal_GRIB.dll \
|
||||
$(OBJ) degrib\degrib\*.obj degrib\g2clib\*.obj \
|
||||
$(GDAL_ROOT)/gdal_i.lib $(LINK_PNG) $(LINK_ZLIB)
|
||||
|
|
|
@ -1,20 +1,20 @@
|
|||
OBJ = kmlsuperoverlaydataset.obj
|
||||
|
||||
GDAL_ROOT = ..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
$(INSTALL) *.obj ..\o
|
||||
|
||||
all: default
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del *.dll
|
||||
-del *.exp
|
||||
-del *.lib
|
||||
-del *.manifest
|
||||
-del *.pdb
|
||||
-del *.ilk
|
||||
|
||||
OBJ = kmlsuperoverlaydataset.obj
|
||||
|
||||
GDAL_ROOT = ..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
$(INSTALL) *.obj ..\o
|
||||
|
||||
all: default
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del *.dll
|
||||
-del *.exp
|
||||
-del *.lib
|
||||
-del *.manifest
|
||||
-del *.pdb
|
||||
-del *.ilk
|
||||
|
||||
|
|
|
@ -1,15 +1,15 @@
|
|||
|
||||
OBJ = postgisrasterdataset.obj postgisrasterrasterband.obj postgisrasterdriver.obj postgisrastertiledataset.obj postgisrastertilerasterband.obj postgisrastertools.obj
|
||||
|
||||
EXTRAFLAGS = -I ../mem -I ../vrt -I$(PG_INC_DIR)
|
||||
|
||||
GDAL_ROOT = ..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
xcopy /D /Y *.obj ..\o
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
|
||||
|
||||
OBJ = postgisrasterdataset.obj postgisrasterrasterband.obj postgisrasterdriver.obj postgisrastertiledataset.obj postgisrastertilerasterband.obj postgisrastertools.obj
|
||||
|
||||
EXTRAFLAGS = -I ../mem -I ../vrt -I$(PG_INC_DIR)
|
||||
|
||||
GDAL_ROOT = ..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
xcopy /D /Y *.obj ..\o
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
|
||||
OBJ = sagadataset.obj
|
||||
|
||||
GDAL_ROOT = ..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
xcopy /D /Y *.obj ..\o
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
|
||||
|
||||
OBJ = sagadataset.obj
|
||||
|
||||
GDAL_ROOT = ..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
xcopy /D /Y *.obj ..\o
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
|
||||
|
|
|
@ -1,34 +1,34 @@
|
|||
|
||||
EXTRAFLAGS = -I$(SDE_INC) /D_MBCS /DWIN32 /D_WIN32
|
||||
|
||||
OBJ = sdedataset.obj sderasterband.obj sdeerror.obj
|
||||
|
||||
PLUGIN_DLL = gdal_SDE.dll
|
||||
|
||||
GDAL_ROOT = ..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
$(INSTALL) *.obj ..\o
|
||||
|
||||
all: default
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del *.dll
|
||||
-del *.exp
|
||||
-del *.lib
|
||||
-del *.manifest
|
||||
-del *.pdb
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll $(LDEBUG) /out:$(PLUGIN_DLL) $(OBJ) $(GDAL_ROOT)/gdal_i.lib $(SDE_LIB)
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest -outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
|
||||
|
||||
EXTRAFLAGS = -I$(SDE_INC) /D_MBCS /DWIN32 /D_WIN32
|
||||
|
||||
OBJ = sdedataset.obj sderasterband.obj sdeerror.obj
|
||||
|
||||
PLUGIN_DLL = gdal_SDE.dll
|
||||
|
||||
GDAL_ROOT = ..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
$(INSTALL) *.obj ..\o
|
||||
|
||||
all: default
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del *.dll
|
||||
-del *.exp
|
||||
-del *.lib
|
||||
-del *.manifest
|
||||
-del *.pdb
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll $(LDEBUG) /out:$(PLUGIN_DLL) $(OBJ) $(GDAL_ROOT)/gdal_i.lib $(SDE_LIB)
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest -outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
|
||||
|
|
|
@ -1,490 +1,490 @@
|
|||
@echo off
|
||||
|
||||
:: ****************************************************************************
|
||||
:: $Id: $
|
||||
::
|
||||
:: Name: generate_vcxproj.bat
|
||||
:: Project: GDAL
|
||||
:: Purpose: Generate MS Visual C++ => 10.0 project files
|
||||
:: Author: Ivan Lucena, [ivan lucena at outlook dot com]
|
||||
::
|
||||
:: ****************************************************************************
|
||||
:: Copyright (c) 2007, Ivan Lucena
|
||||
::
|
||||
:: Permission is hereby granted, free of charge, to any person obtaining a
|
||||
:: copy of this software and associated documentation files (the "Software"),
|
||||
:: to deal in the Software without restriction, including without limitation
|
||||
:: the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||
:: and/or sell copies of the Software, and to permit persons to whom the
|
||||
:: Software is furnished to do so, subject to the following conditions:
|
||||
::
|
||||
:: The above copyright notice and this permission notice shall be included
|
||||
:: in all copies or substantial portions of the Software.
|
||||
::
|
||||
:: THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
||||
:: OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
:: FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
|
||||
:: THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
:: LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
:: FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
:: DEALINGS IN THE SOFTWARE.
|
||||
:: ****************************************************************************
|
||||
setlocal
|
||||
|
||||
if "%1"=="" (
|
||||
goto :usage
|
||||
)
|
||||
|
||||
if "%2"=="" (
|
||||
goto :usage
|
||||
)
|
||||
|
||||
if "%3"=="" (
|
||||
goto :usage
|
||||
)
|
||||
|
||||
:: *********************
|
||||
:: Get Visual C++ version
|
||||
:: *********************
|
||||
|
||||
set _vcver_=%1
|
||||
|
||||
set _clver_=1600
|
||||
set _vstoolset_=v100
|
||||
|
||||
if "%_vcver_%"=="15.0" (
|
||||
set _clver_=1910
|
||||
set _vstoolset_=v141
|
||||
) else if "%_vcver_%"=="14.0" (
|
||||
set _clver_=1900
|
||||
set _vstoolset_=v140
|
||||
) else ( if "%_vcver_%"=="12.0" (
|
||||
set _clver_=1800
|
||||
set _vstoolset_=v120
|
||||
) else ( if "%_vcver_%"=="11.0" (
|
||||
set _clver_=1700
|
||||
set _vstoolset_=v110
|
||||
) else ( if "%_vcver_%"=="10.0" (
|
||||
set _clver_=1600
|
||||
set _vstoolset_=v100
|
||||
) else (
|
||||
echo Wrong value for parameter 1. See usage:
|
||||
goto :usage
|
||||
))))
|
||||
|
||||
:: *********************
|
||||
:: Get Platform
|
||||
:: *********************
|
||||
|
||||
set _platf_=%2
|
||||
set _buildplatf_=x86
|
||||
set _winver_=Win32
|
||||
set _nmake_opt_win64_=
|
||||
|
||||
if not "%_platf_%"=="32" (
|
||||
if not "%_platf_%"=="64" (
|
||||
echo Wrong value for parameter 2. See usage:
|
||||
goto :usage
|
||||
)
|
||||
)
|
||||
|
||||
if "%_platf_%"=="64" (
|
||||
set _winver_=x64
|
||||
set _buildplatf_=x64
|
||||
set _nmake_opt_win64_=WIN64=1
|
||||
)
|
||||
|
||||
goto :continue
|
||||
|
||||
:: *********************
|
||||
:usage
|
||||
:: *********************
|
||||
|
||||
echo Usage: generate_vcxproj ^<Visual C++ version^> [32^|64] ^<^(*^) project file name^>
|
||||
echo Parameters:
|
||||
echo 1 : Visual C++ version is not the same as Visual Studio version ^( =^> 10.0 ^)
|
||||
echo 2 : Windows platform 32 for Win32 and 64 for Win64
|
||||
echo 3 : Base file name, with no path and no extension ^(*^)
|
||||
echo Examples:
|
||||
echo generate_vcxproj 10.1 32 gdal_vs2010
|
||||
echo generate_vcxproj 11.0 64 gdal_vs2012
|
||||
echo generate_vcxproj 12.0 64 gdal_vs2013
|
||||
echo generate_vcxproj 14.0 64 gdal_vs2015
|
||||
echo generate_vcxproj 15.0 64 gdal_vs2017
|
||||
|
||||
goto :end
|
||||
|
||||
:: *********************
|
||||
:: Set Project file names
|
||||
:: *********************
|
||||
|
||||
:continue
|
||||
|
||||
set _gdaldir_=%CD%
|
||||
set _testdir_=
|
||||
FOR /F %%i IN ("%_gdaldir_%\..\autotest\cpp") DO (
|
||||
if exist "%%~fi" set _testdir_=%%~fi
|
||||
)
|
||||
|
||||
set _gdalsln_=%_gdaldir_%\%3.sln
|
||||
set _gdalproj_=%_gdaldir_%\%3.vcxproj
|
||||
set _gdaluser_=%_gdalproj_%.user
|
||||
set _gdalfltr_=%_gdalproj_%.filters
|
||||
set _testproj_=%_testdir_%\%3_test.vcxproj
|
||||
set _testuser_=%_testproj_%.user
|
||||
set _testfltr_=%_testproj_%.filters
|
||||
|
||||
:: Add quotes
|
||||
|
||||
set _gdalproj_="%_gdalproj_%"
|
||||
set _gdaluser_="%_gdaluser_%"
|
||||
set _gdalfltr_="%_gdalfltr_%"
|
||||
set _testproj_="%_testproj_%"
|
||||
set _testuser_="%_testuser_%"
|
||||
set _testfltr_="%_testfltr_%"
|
||||
|
||||
:: Progress message
|
||||
|
||||
echo Generating:
|
||||
echo %_gdalproj_%
|
||||
echo %_gdaluser_%
|
||||
echo %_gdalfltr_%
|
||||
|
||||
if defined _testdir_ (
|
||||
echo %_testproj_%
|
||||
echo %_testuser_%
|
||||
echo %_testfltr_%
|
||||
)
|
||||
:: if defined _testdir_
|
||||
|
||||
echo This might take a little while...
|
||||
|
||||
:: Delete existing files
|
||||
|
||||
if exist %_gdalproj_% (
|
||||
del %_gdalproj_%
|
||||
)
|
||||
|
||||
if exist %_gdaluser_% (
|
||||
del %_gdaluser_%
|
||||
)
|
||||
|
||||
if exist %_gdalfltr_% (
|
||||
del %_gdalfltr_%
|
||||
)
|
||||
|
||||
if exist %_testproj_% (
|
||||
del %_testproj_%
|
||||
)
|
||||
|
||||
if exist %_testuser_% (
|
||||
del %_testuser_%
|
||||
)
|
||||
|
||||
if exist %_testfltr_% (
|
||||
del %_testfltr_%
|
||||
)
|
||||
|
||||
:: **********************************************
|
||||
:: Generate project user files (.vcxproj.user)
|
||||
:: **********************************************
|
||||
|
||||
echo ^<?xml version="1.0" encoding="utf-8"?^> >> %_gdaluser_%
|
||||
echo ^<Project ToolsVersion="%_vcver_%" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"^> >> %_gdaluser_%
|
||||
echo ^<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|%_winver_%'"^> >> %_gdaluser_%
|
||||
echo ^<DebuggerFlavor^>WindowsLocalDebugger^</DebuggerFlavor^> >> %_gdaluser_%
|
||||
echo ^<LocalDebuggerDebuggerType^>Auto^</LocalDebuggerDebuggerType^> >> %_gdaluser_%
|
||||
echo ^<LocalDebuggerCommand^>%CD%\apps\gdal_translate.exe^</LocalDebuggerCommand^> >> %_gdaluser_%
|
||||
echo ^<LocalDebuggerCommandArguments^>--formats^</LocalDebuggerCommandArguments^> >> %_gdaluser_%
|
||||
echo ^<LocalDebuggerEnvironment^>CPL_DEBUG=ON >> %_gdaluser_%
|
||||
echo GDAL_DATA=%_gdaldir_%\data >> %_gdaluser_%
|
||||
echo ^</LocalDebuggerEnvironment^> >> %_gdaluser_%
|
||||
echo ^</PropertyGroup^> >> %_gdaluser_%
|
||||
echo ^</Project^> >> %_gdaluser_%
|
||||
|
||||
if defined _testdir_ (
|
||||
echo ^<?xml version="1.0" encoding="utf-8"?^> >> %_testuser_%
|
||||
echo ^<Project ToolsVersion="%_vcver_%" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"^> >> %_testuser_%
|
||||
echo ^<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|%_winver_%'"^> >> %_testuser_%
|
||||
echo ^<DebuggerFlavor^>WindowsLocalDebugger^</DebuggerFlavor^> >> %_testuser_%
|
||||
echo ^<LocalDebuggerDebuggerType^>Auto^</LocalDebuggerDebuggerType^> >> %_testuser_%
|
||||
echo ^<LocalDebuggerCommand^>%_testdir_%\gdal_unit_test.exe^</LocalDebuggerCommand^> >> %_testuser_%
|
||||
echo ^<LocalDebuggerCommandArguments^>^</LocalDebuggerCommandArguments^> >> %_testuser_%
|
||||
echo ^<LocalDebuggerEnvironment^>CPL_DEBUG=ON >> %_testuser_%
|
||||
echo GDAL_DATA=%_gdaldir_%\data >> %_testuser_%
|
||||
echo ^</LocalDebuggerEnvironment^> >> %_testuser_%
|
||||
echo ^</PropertyGroup^> >> %_testuser_%
|
||||
echo ^</Project^> >> %_testuser_%
|
||||
)
|
||||
:: if defined _testdir_
|
||||
|
||||
:: **********************************************
|
||||
:: Initialize filters files (.vcxproj.filters)
|
||||
:: **********************************************
|
||||
|
||||
echo ^<?xml version="1.0" encoding="utf-8"?^> >> %_gdalfltr_%
|
||||
echo ^<Project ToolsVersion="5.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"^> >> %_gdalfltr_%
|
||||
|
||||
:: **********************************************
|
||||
:: Main file generator (.vcxproj) and filters file (.vcxproj.filters)
|
||||
:: **********************************************
|
||||
|
||||
echo ^<?xml version="1.0" encoding="utf-8"?^> >> %_gdalproj_%
|
||||
echo ^<Project DefaultTargets="Build" ToolsVersion="%_vcver_%" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"^> >> %_gdalproj_%
|
||||
echo ^<ItemGroup Label="ProjectConfigurations"^> >> %_gdalproj_%
|
||||
echo ^<ProjectConfiguration Include="Debug|%_winver_%"^> >> %_gdalproj_%
|
||||
echo ^<Configuration^>Debug^</Configuration^> >> %_gdalproj_%
|
||||
echo ^<Platform^>%_winver_%^</Platform^> >> %_gdalproj_%
|
||||
echo ^</ProjectConfiguration^> >> %_gdalproj_%
|
||||
echo ^<ProjectConfiguration Include="Release|%_winver_%"^> >> %_gdalproj_%
|
||||
echo ^<Configuration^>Release^</Configuration^> >> %_gdalproj_%
|
||||
echo ^<Platform^>%_winver_%^</Platform^> >> %_gdalproj_%
|
||||
echo ^</ProjectConfiguration^> >> %_gdalproj_%
|
||||
echo ^</ItemGroup^> >> %_gdalproj_%
|
||||
echo ^<PropertyGroup Label="Globals"^> >> %_gdalproj_%
|
||||
echo ^<Keyword^>MakeFileProj^</Keyword^> >> %_gdalproj_%
|
||||
echo ^</PropertyGroup^> >> %_gdalproj_%
|
||||
echo ^<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /^> >> %_gdalproj_%
|
||||
echo ^<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|%_winver_%'" Label="Configuration"^> >> %_gdalproj_%
|
||||
echo ^<ConfigurationType^>Makefile^</ConfigurationType^> >> %_gdalproj_%
|
||||
echo ^<UseDebugLibraries^>true^</UseDebugLibraries^> >> %_gdalproj_%
|
||||
echo ^<PlatformToolset^>%_vstoolset_%^</PlatformToolset^> >> %_gdalproj_%
|
||||
echo ^</PropertyGroup^> >> %_gdalproj_%
|
||||
echo ^<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|%_winver_%'" Label="Configuration"^> >> %_gdalproj_%
|
||||
echo ^<ConfigurationType^>Makefile^</ConfigurationType^> >> %_gdalproj_%
|
||||
echo ^<UseDebugLibraries^>true^</UseDebugLibraries^> >> %_gdalproj_%
|
||||
echo ^<PlatformToolset^>%_vstoolset_%^</PlatformToolset^> >> %_gdalproj_%
|
||||
echo ^</PropertyGroup^> >> %_gdalproj_%
|
||||
echo ^<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /^> >> %_gdalproj_%
|
||||
echo ^<ImportGroup Label="ExtensionSettings"^> >> %_gdalproj_%
|
||||
echo ^</ImportGroup^> >> %_gdalproj_%
|
||||
echo ^<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|%_winver_%'"^> >> %_gdalproj_%
|
||||
echo ^<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /^> >> %_gdalproj_%
|
||||
echo ^</ImportGroup^> >> %_gdalproj_%
|
||||
echo ^<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|%_winver_%'"^> >> %_gdalproj_%
|
||||
echo ^<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /^> >> %_gdalproj_%
|
||||
echo ^</ImportGroup^> >> %_gdalproj_%
|
||||
echo ^<PropertyGroup Label="UserMacros" /^> >> %_gdalproj_%
|
||||
echo ^<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|%_winver_%'"^> >> %_gdalproj_%
|
||||
echo ^<NMakeBuildCommandLine^>nmake -f makefile.vc MSVC_VER=%_clver_% %_nmake_opt_win64_% DEBUG=1 WITH_PDB=1^</NMakeBuildCommandLine^> >> %_gdalproj_%
|
||||
echo ^<NMakeOutput^>^</NMakeOutput^> >> %_gdalproj_%
|
||||
echo ^<NMakeCleanCommandLine^>nmake -f makefile.vc MSVC_VER=%_clver_% %_nmake_opt_win64_% DEBUG=1 WITH_PDB=1 clean^</NMakeCleanCommandLine^> >> %_gdalproj_%
|
||||
echo ^<NMakeReBuildCommandLine^>nmake -f makefile.vc MSVC_VER=%_clver_% %_nmake_opt_win64_% DEBUG=1 WITH_PDB=1 clean ^&^& nmake -f makefile.vc MSVC_VER=%_clver_% %_nmake_opt_win64_% DEBUG=1 WITH_PDB=1^</NMakeReBuildCommandLine^> >> %_gdalproj_%
|
||||
echo ^<NMakePreprocessorDefinitions^>%_winver_%;_DEBUG;$(NMakePreprocessorDefinitions)^</NMakePreprocessorDefinitions^> >> %_gdalproj_%
|
||||
echo ^<LibraryPath^>$(VC_LibraryPath_%_buildplatf_%);$(WindowsSDK_LibraryPath_%_buildplatf_%);$(VC_SourcePath);^</LibraryPath^> >> %_gdalproj_%
|
||||
echo ^</PropertyGroup^> >> %_gdalproj_%
|
||||
echo ^<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|%_winver_%'"^> >> %_gdalproj_%
|
||||
echo ^<NMakeBuildCommandLine^>nmake -f makefile.vc MSVC_VER=%_clver_% %_nmake_opt_win64_% ^</NMakeBuildCommandLine^> >> %_gdalproj_%
|
||||
echo ^<NMakeOutput^>^</NMakeOutput^> >> %_gdalproj_%
|
||||
echo ^<NMakeCleanCommandLine^>nmake -f makefile.vc MSVC_VER=%_clver_% %_nmake_opt_win64_% clean^</NMakeCleanCommandLine^> >> %_gdalproj_%
|
||||
echo ^<NMakeReBuildCommandLine^>nmake -f makefile.vc MSVC_VER=%_clver_% %_nmake_opt_win64_% clean ^&^& nmake -f makefile.vc MSVC_VER=%_clver_%^</NMakeReBuildCommandLine^> >> %_gdalproj_%
|
||||
echo ^<NMakePreprocessorDefinitions^>%_winver_%;NDEBUG;$(NMakePreprocessorDefinitions)^</NMakePreprocessorDefinitions^> >> %_gdalproj_%
|
||||
echo ^<LibraryPath^>$(VC_LibraryPath_%_buildplatf_%);$(WindowsSDK_LibraryPath_%_buildplatf_%);$(VC_SourcePath);^</LibraryPath^> >> %_gdalproj_%
|
||||
echo ^</PropertyGroup^> >> %_gdalproj_%
|
||||
echo ^<ItemDefinitionGroup^> >> %_gdalproj_%
|
||||
echo ^</ItemDefinitionGroup^> >> %_gdalproj_%
|
||||
|
||||
:: create a root path with nmake files
|
||||
|
||||
echo ^<ItemGroup^> >> %_gdalproj_%
|
||||
echo ^<Test Include="%_gdaldir_%\nmake.local" /^> >> %_gdalproj_%
|
||||
echo ^<Test Include="%_gdaldir_%\nmake.opt" /^> >> %_gdalproj_%
|
||||
echo ^</ItemGroup^> >> %_gdalproj_%
|
||||
|
||||
echo ^<ItemGroup^> >> %_gdalfltr_%
|
||||
echo ^<Test Include="%_gdaldir_%\nmake.local" /^> >> %_gdalfltr_%
|
||||
echo ^<Test Include="%_gdaldir_%\nmake.opt" /^> >> %_gdalfltr_%
|
||||
echo ^</ItemGroup^> >> %_gdalfltr_%
|
||||
|
||||
:: Use base of main .vcxproj and .filters as template for test project
|
||||
|
||||
if defined _testdir_ (
|
||||
copy /Y %_gdalproj_% %_testproj_% >NUL
|
||||
copy /Y %_gdalfltr_% %_testfltr_% >NUL
|
||||
)
|
||||
:: if defined _testdir_
|
||||
|
||||
:: create main project filters only
|
||||
|
||||
echo ^<ItemGroup^> >> %_gdalfltr_%
|
||||
call :create_filter %_gdaldir_% "*.vc;" 1 "Make Files" "None" %_gdalproj_% %_gdalfltr_%
|
||||
call :create_filter %_gdaldir_% "*.h;*.hpp" 1 "Include Files" "ClInclude" %_gdalproj_% %_gdalfltr_%
|
||||
call :create_filter %_gdaldir_% "*.c;*.cpp" 1 "Source Files" "ClCompile" %_gdalproj_% %_gdalfltr_%
|
||||
echo ^</ItemGroup^> >> %_gdalfltr_%
|
||||
|
||||
:: create test project filters only
|
||||
|
||||
if defined _testdir_ (
|
||||
echo ^<ItemGroup^> >> %_testfltr_%
|
||||
call :create_filter %_testdir_% "*.vc;" 1 "Make Files" "None" %_testproj_% %_testfltr_%
|
||||
call :create_filter %_testdir_% "*.h;*.hpp" 1 "Include Files" "ClInclude" %_testproj_% %_testfltr_%
|
||||
call :create_filter %_testdir_% "*.c;*.cpp" 1 "Source Files" "ClCompile" %_testproj_% %_testfltr_%
|
||||
echo ^</ItemGroup^> >> %_testfltr_%
|
||||
)
|
||||
:: if defined _testdir_
|
||||
|
||||
:: create main project and links to filters
|
||||
|
||||
echo ^<ItemGroup^> >> %_gdalproj_%
|
||||
echo ^<ItemGroup^> >> %_gdalfltr_%
|
||||
call :create_filter %_gdaldir_% "*.vc" 0 "Make Files" "None" %_gdalproj_% %_gdalfltr_%
|
||||
echo ^</ItemGroup^> >> %_gdalproj_%
|
||||
echo ^</ItemGroup^> >> %_gdalfltr_%
|
||||
|
||||
echo ^<ItemGroup^> >> %_gdalproj_%
|
||||
echo ^<ItemGroup^> >> %_gdalfltr_%
|
||||
call :create_filter %_gdaldir_% "*.h;*.hpp" 0 "Include Files" "ClInclude" %_gdalproj_% %_gdalfltr_%
|
||||
echo ^</ItemGroup^> >> %_gdalproj_%
|
||||
echo ^</ItemGroup^> >> %_gdalfltr_%
|
||||
|
||||
echo ^<ItemGroup^> >> %_gdalproj_%
|
||||
echo ^<ItemGroup^> >> %_gdalfltr_%
|
||||
call :create_filter %_gdaldir_% "*.c;*.cpp" 0 "Source Files" "ClCompile" %_gdalproj_% %_gdalfltr_%
|
||||
echo ^</ItemGroup^> >> %_gdalproj_%
|
||||
echo ^</ItemGroup^> >> %_gdalfltr_%
|
||||
|
||||
:: create test project and links to filters
|
||||
|
||||
if defined _testdir_ (
|
||||
echo ^<ItemGroup^> >> %_testproj_%
|
||||
echo ^<ItemGroup^> >> %_testfltr_%
|
||||
call :create_filter %_testdir_% "*.vc" 0 "Make Files" "None" %_testproj_% %_testfltr_%
|
||||
echo ^</ItemGroup^> >> %_testproj_%
|
||||
echo ^</ItemGroup^> >> %_testfltr_%
|
||||
|
||||
echo ^<ItemGroup^> >> %_testproj_%
|
||||
echo ^<ItemGroup^> >> %_testfltr_%
|
||||
call :create_filter %_testdir_% "*.h;*.hpp" 0 "Include Files" "ClInclude" %_testproj_% %_testfltr_%
|
||||
echo ^</ItemGroup^> >> %_testproj_%
|
||||
echo ^</ItemGroup^> >> %_testfltr_%
|
||||
|
||||
echo ^<ItemGroup^> >> %_testproj_%
|
||||
echo ^<ItemGroup^> >> %_testfltr_%
|
||||
call :create_filter %_testdir_% "*.c;*.cpp" 0 "Source Files" "ClCompile" %_testproj_% %_testfltr_%
|
||||
echo ^</ItemGroup^> >> %_testproj_%
|
||||
echo ^</ItemGroup^> >> %_testfltr_%
|
||||
)
|
||||
:: if defined _testdir_
|
||||
|
||||
:: **********************************************
|
||||
:: Finalize main and test projects
|
||||
:: **********************************************
|
||||
|
||||
echo ^</Project^> >> %_gdalfltr_%
|
||||
|
||||
echo ^<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/^> >> %_gdalproj_%
|
||||
echo ^</Project^> >> %_gdalproj_%
|
||||
|
||||
if defined _testdir_ (
|
||||
echo ^</Project^> >> %_testfltr_%
|
||||
|
||||
echo ^<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/^> >> %_testproj_%
|
||||
echo ^</Project^> >> %_testproj_%
|
||||
)
|
||||
:: if defined _testdir_ (
|
||||
|
||||
:: *******************************************************
|
||||
:: Generate .sln file with main and test projects attached
|
||||
:: *******************************************************
|
||||
|
||||
echo Projects done!
|
||||
|
||||
echo Launch Visual Studio IDE
|
||||
echo * Open project %_gdalproj_%
|
||||
echo * Add project %_testproj_%
|
||||
echo * Configure Build Dependencies to build the main project before the test project.
|
||||
echo * Save solution in .sln file
|
||||
echo Done!
|
||||
|
||||
:: **********************************************
|
||||
:: The end
|
||||
:: **********************************************
|
||||
|
||||
goto :end
|
||||
|
||||
:: **********************************************
|
||||
:create_filter
|
||||
:: **********************************************
|
||||
|
||||
set _path_=%1
|
||||
set _mask_=%2
|
||||
set _fonly_=%3
|
||||
set _name_=%4
|
||||
set _item_=%5
|
||||
set _proj_=%6
|
||||
set _fltr_=%7
|
||||
|
||||
:: *********************
|
||||
:: Remove quotes
|
||||
:: *********************
|
||||
|
||||
set _name_=%_name_:"=%
|
||||
set _mask_=%_mask_:"=%
|
||||
set _fonly_=%_fonly_:"=%
|
||||
set _item_=%_item_:"=%
|
||||
|
||||
:: *********************
|
||||
:: Stop folders
|
||||
:: *********************
|
||||
|
||||
set _folder_=%~nx1
|
||||
|
||||
for %%d in (ci data debian doc html m4 pymod scripts swig) do (
|
||||
if "%_folder_%"=="%%d" (
|
||||
goto :end
|
||||
)
|
||||
)
|
||||
:: *********************
|
||||
:: Check if a folder is empty
|
||||
:: *********************
|
||||
|
||||
set _find_=1
|
||||
|
||||
for /R %%f in (%_mask_%) do (
|
||||
goto :not_empty
|
||||
)
|
||||
|
||||
set _find_=0
|
||||
|
||||
:not_empty
|
||||
|
||||
if %_find_%==0 (
|
||||
goto :end
|
||||
)
|
||||
|
||||
:: *********************
|
||||
:: Add filters
|
||||
:: *********************
|
||||
|
||||
if %_fonly_%==1 (
|
||||
echo ^<Filter Include="%_name_%"^> >> %_fltr_%
|
||||
echo ^<Extensions^>%_mask_%^</Extensions^> >> %_fltr_%
|
||||
echo ^</Filter^> >> %_fltr_%
|
||||
)
|
||||
|
||||
:: *********************
|
||||
:: Add files
|
||||
:: *********************
|
||||
|
||||
if %_fonly_%==0 (
|
||||
for %%f in (%_mask_%) do (
|
||||
echo ^<%_item_% Include="%_path_%\%%f"/^> >> %_proj_%
|
||||
echo ^<%_item_% Include="%_path_%\%%f"^> >> %_fltr_%
|
||||
echo ^<Filter^>%_name_%^</Filter^> >> %_fltr_%
|
||||
echo ^</%_item_%^> >> %_fltr_%
|
||||
)
|
||||
)
|
||||
|
||||
:: *********************
|
||||
:: Clib all the branches recursivelly
|
||||
:: *********************
|
||||
|
||||
for /D %%d in (%_path_%\*) do (
|
||||
cd %%d
|
||||
call :create_filter %%d "%_mask_%" %_fonly_% "%_name_%\%%~nxd" %_item_% %_proj_% %_fltr_%
|
||||
cd ..
|
||||
)
|
||||
|
||||
:: **********************************************
|
||||
:end
|
||||
:: **********************************************
|
||||
@echo off
|
||||
|
||||
:: ****************************************************************************
|
||||
:: $Id: $
|
||||
::
|
||||
:: Name: generate_vcxproj.bat
|
||||
:: Project: GDAL
|
||||
:: Purpose: Generate MS Visual C++ => 10.0 project files
|
||||
:: Author: Ivan Lucena, [ivan lucena at outlook dot com]
|
||||
::
|
||||
:: ****************************************************************************
|
||||
:: Copyright (c) 2007, Ivan Lucena
|
||||
::
|
||||
:: Permission is hereby granted, free of charge, to any person obtaining a
|
||||
:: copy of this software and associated documentation files (the "Software"),
|
||||
:: to deal in the Software without restriction, including without limitation
|
||||
:: the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||
:: and/or sell copies of the Software, and to permit persons to whom the
|
||||
:: Software is furnished to do so, subject to the following conditions:
|
||||
::
|
||||
:: The above copyright notice and this permission notice shall be included
|
||||
:: in all copies or substantial portions of the Software.
|
||||
::
|
||||
:: THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
||||
:: OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
:: FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
|
||||
:: THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
:: LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
:: FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
:: DEALINGS IN THE SOFTWARE.
|
||||
:: ****************************************************************************
|
||||
setlocal
|
||||
|
||||
if "%1"=="" (
|
||||
goto :usage
|
||||
)
|
||||
|
||||
if "%2"=="" (
|
||||
goto :usage
|
||||
)
|
||||
|
||||
if "%3"=="" (
|
||||
goto :usage
|
||||
)
|
||||
|
||||
:: *********************
|
||||
:: Get Visual C++ version
|
||||
:: *********************
|
||||
|
||||
set _vcver_=%1
|
||||
|
||||
set _clver_=1600
|
||||
set _vstoolset_=v100
|
||||
|
||||
if "%_vcver_%"=="15.0" (
|
||||
set _clver_=1910
|
||||
set _vstoolset_=v141
|
||||
) else if "%_vcver_%"=="14.0" (
|
||||
set _clver_=1900
|
||||
set _vstoolset_=v140
|
||||
) else ( if "%_vcver_%"=="12.0" (
|
||||
set _clver_=1800
|
||||
set _vstoolset_=v120
|
||||
) else ( if "%_vcver_%"=="11.0" (
|
||||
set _clver_=1700
|
||||
set _vstoolset_=v110
|
||||
) else ( if "%_vcver_%"=="10.0" (
|
||||
set _clver_=1600
|
||||
set _vstoolset_=v100
|
||||
) else (
|
||||
echo Wrong value for parameter 1. See usage:
|
||||
goto :usage
|
||||
))))
|
||||
|
||||
:: *********************
|
||||
:: Get Platform
|
||||
:: *********************
|
||||
|
||||
set _platf_=%2
|
||||
set _buildplatf_=x86
|
||||
set _winver_=Win32
|
||||
set _nmake_opt_win64_=
|
||||
|
||||
if not "%_platf_%"=="32" (
|
||||
if not "%_platf_%"=="64" (
|
||||
echo Wrong value for parameter 2. See usage:
|
||||
goto :usage
|
||||
)
|
||||
)
|
||||
|
||||
if "%_platf_%"=="64" (
|
||||
set _winver_=x64
|
||||
set _buildplatf_=x64
|
||||
set _nmake_opt_win64_=WIN64=1
|
||||
)
|
||||
|
||||
goto :continue
|
||||
|
||||
:: *********************
|
||||
:usage
|
||||
:: *********************
|
||||
|
||||
echo Usage: generate_vcxproj ^<Visual C++ version^> [32^|64] ^<^(*^) project file name^>
|
||||
echo Parameters:
|
||||
echo 1 : Visual C++ version is not the same as Visual Studio version ^( =^> 10.0 ^)
|
||||
echo 2 : Windows platform 32 for Win32 and 64 for Win64
|
||||
echo 3 : Base file name, with no path and no extension ^(*^)
|
||||
echo Examples:
|
||||
echo generate_vcxproj 10.1 32 gdal_vs2010
|
||||
echo generate_vcxproj 11.0 64 gdal_vs2012
|
||||
echo generate_vcxproj 12.0 64 gdal_vs2013
|
||||
echo generate_vcxproj 14.0 64 gdal_vs2015
|
||||
echo generate_vcxproj 15.0 64 gdal_vs2017
|
||||
|
||||
goto :end
|
||||
|
||||
:: *********************
|
||||
:: Set Project file names
|
||||
:: *********************
|
||||
|
||||
:continue
|
||||
|
||||
set _gdaldir_=%CD%
|
||||
set _testdir_=
|
||||
FOR /F %%i IN ("%_gdaldir_%\..\autotest\cpp") DO (
|
||||
if exist "%%~fi" set _testdir_=%%~fi
|
||||
)
|
||||
|
||||
set _gdalsln_=%_gdaldir_%\%3.sln
|
||||
set _gdalproj_=%_gdaldir_%\%3.vcxproj
|
||||
set _gdaluser_=%_gdalproj_%.user
|
||||
set _gdalfltr_=%_gdalproj_%.filters
|
||||
set _testproj_=%_testdir_%\%3_test.vcxproj
|
||||
set _testuser_=%_testproj_%.user
|
||||
set _testfltr_=%_testproj_%.filters
|
||||
|
||||
:: Add quotes
|
||||
|
||||
set _gdalproj_="%_gdalproj_%"
|
||||
set _gdaluser_="%_gdaluser_%"
|
||||
set _gdalfltr_="%_gdalfltr_%"
|
||||
set _testproj_="%_testproj_%"
|
||||
set _testuser_="%_testuser_%"
|
||||
set _testfltr_="%_testfltr_%"
|
||||
|
||||
:: Progress message
|
||||
|
||||
echo Generating:
|
||||
echo %_gdalproj_%
|
||||
echo %_gdaluser_%
|
||||
echo %_gdalfltr_%
|
||||
|
||||
if defined _testdir_ (
|
||||
echo %_testproj_%
|
||||
echo %_testuser_%
|
||||
echo %_testfltr_%
|
||||
)
|
||||
:: if defined _testdir_
|
||||
|
||||
echo This might take a little while...
|
||||
|
||||
:: Delete existing files
|
||||
|
||||
if exist %_gdalproj_% (
|
||||
del %_gdalproj_%
|
||||
)
|
||||
|
||||
if exist %_gdaluser_% (
|
||||
del %_gdaluser_%
|
||||
)
|
||||
|
||||
if exist %_gdalfltr_% (
|
||||
del %_gdalfltr_%
|
||||
)
|
||||
|
||||
if exist %_testproj_% (
|
||||
del %_testproj_%
|
||||
)
|
||||
|
||||
if exist %_testuser_% (
|
||||
del %_testuser_%
|
||||
)
|
||||
|
||||
if exist %_testfltr_% (
|
||||
del %_testfltr_%
|
||||
)
|
||||
|
||||
:: **********************************************
|
||||
:: Generate project user files (.vcxproj.user)
|
||||
:: **********************************************
|
||||
|
||||
echo ^<?xml version="1.0" encoding="utf-8"?^> >> %_gdaluser_%
|
||||
echo ^<Project ToolsVersion="%_vcver_%" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"^> >> %_gdaluser_%
|
||||
echo ^<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|%_winver_%'"^> >> %_gdaluser_%
|
||||
echo ^<DebuggerFlavor^>WindowsLocalDebugger^</DebuggerFlavor^> >> %_gdaluser_%
|
||||
echo ^<LocalDebuggerDebuggerType^>Auto^</LocalDebuggerDebuggerType^> >> %_gdaluser_%
|
||||
echo ^<LocalDebuggerCommand^>%CD%\apps\gdal_translate.exe^</LocalDebuggerCommand^> >> %_gdaluser_%
|
||||
echo ^<LocalDebuggerCommandArguments^>--formats^</LocalDebuggerCommandArguments^> >> %_gdaluser_%
|
||||
echo ^<LocalDebuggerEnvironment^>CPL_DEBUG=ON >> %_gdaluser_%
|
||||
echo GDAL_DATA=%_gdaldir_%\data >> %_gdaluser_%
|
||||
echo ^</LocalDebuggerEnvironment^> >> %_gdaluser_%
|
||||
echo ^</PropertyGroup^> >> %_gdaluser_%
|
||||
echo ^</Project^> >> %_gdaluser_%
|
||||
|
||||
if defined _testdir_ (
|
||||
echo ^<?xml version="1.0" encoding="utf-8"?^> >> %_testuser_%
|
||||
echo ^<Project ToolsVersion="%_vcver_%" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"^> >> %_testuser_%
|
||||
echo ^<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|%_winver_%'"^> >> %_testuser_%
|
||||
echo ^<DebuggerFlavor^>WindowsLocalDebugger^</DebuggerFlavor^> >> %_testuser_%
|
||||
echo ^<LocalDebuggerDebuggerType^>Auto^</LocalDebuggerDebuggerType^> >> %_testuser_%
|
||||
echo ^<LocalDebuggerCommand^>%_testdir_%\gdal_unit_test.exe^</LocalDebuggerCommand^> >> %_testuser_%
|
||||
echo ^<LocalDebuggerCommandArguments^>^</LocalDebuggerCommandArguments^> >> %_testuser_%
|
||||
echo ^<LocalDebuggerEnvironment^>CPL_DEBUG=ON >> %_testuser_%
|
||||
echo GDAL_DATA=%_gdaldir_%\data >> %_testuser_%
|
||||
echo ^</LocalDebuggerEnvironment^> >> %_testuser_%
|
||||
echo ^</PropertyGroup^> >> %_testuser_%
|
||||
echo ^</Project^> >> %_testuser_%
|
||||
)
|
||||
:: if defined _testdir_
|
||||
|
||||
:: **********************************************
|
||||
:: Initialize filters files (.vcxproj.filters)
|
||||
:: **********************************************
|
||||
|
||||
echo ^<?xml version="1.0" encoding="utf-8"?^> >> %_gdalfltr_%
|
||||
echo ^<Project ToolsVersion="5.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"^> >> %_gdalfltr_%
|
||||
|
||||
:: **********************************************
|
||||
:: Main file generator (.vcxproj) and filters file (.vcxproj.filters)
|
||||
:: **********************************************
|
||||
|
||||
echo ^<?xml version="1.0" encoding="utf-8"?^> >> %_gdalproj_%
|
||||
echo ^<Project DefaultTargets="Build" ToolsVersion="%_vcver_%" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"^> >> %_gdalproj_%
|
||||
echo ^<ItemGroup Label="ProjectConfigurations"^> >> %_gdalproj_%
|
||||
echo ^<ProjectConfiguration Include="Debug|%_winver_%"^> >> %_gdalproj_%
|
||||
echo ^<Configuration^>Debug^</Configuration^> >> %_gdalproj_%
|
||||
echo ^<Platform^>%_winver_%^</Platform^> >> %_gdalproj_%
|
||||
echo ^</ProjectConfiguration^> >> %_gdalproj_%
|
||||
echo ^<ProjectConfiguration Include="Release|%_winver_%"^> >> %_gdalproj_%
|
||||
echo ^<Configuration^>Release^</Configuration^> >> %_gdalproj_%
|
||||
echo ^<Platform^>%_winver_%^</Platform^> >> %_gdalproj_%
|
||||
echo ^</ProjectConfiguration^> >> %_gdalproj_%
|
||||
echo ^</ItemGroup^> >> %_gdalproj_%
|
||||
echo ^<PropertyGroup Label="Globals"^> >> %_gdalproj_%
|
||||
echo ^<Keyword^>MakeFileProj^</Keyword^> >> %_gdalproj_%
|
||||
echo ^</PropertyGroup^> >> %_gdalproj_%
|
||||
echo ^<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /^> >> %_gdalproj_%
|
||||
echo ^<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|%_winver_%'" Label="Configuration"^> >> %_gdalproj_%
|
||||
echo ^<ConfigurationType^>Makefile^</ConfigurationType^> >> %_gdalproj_%
|
||||
echo ^<UseDebugLibraries^>true^</UseDebugLibraries^> >> %_gdalproj_%
|
||||
echo ^<PlatformToolset^>%_vstoolset_%^</PlatformToolset^> >> %_gdalproj_%
|
||||
echo ^</PropertyGroup^> >> %_gdalproj_%
|
||||
echo ^<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|%_winver_%'" Label="Configuration"^> >> %_gdalproj_%
|
||||
echo ^<ConfigurationType^>Makefile^</ConfigurationType^> >> %_gdalproj_%
|
||||
echo ^<UseDebugLibraries^>true^</UseDebugLibraries^> >> %_gdalproj_%
|
||||
echo ^<PlatformToolset^>%_vstoolset_%^</PlatformToolset^> >> %_gdalproj_%
|
||||
echo ^</PropertyGroup^> >> %_gdalproj_%
|
||||
echo ^<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /^> >> %_gdalproj_%
|
||||
echo ^<ImportGroup Label="ExtensionSettings"^> >> %_gdalproj_%
|
||||
echo ^</ImportGroup^> >> %_gdalproj_%
|
||||
echo ^<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|%_winver_%'"^> >> %_gdalproj_%
|
||||
echo ^<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /^> >> %_gdalproj_%
|
||||
echo ^</ImportGroup^> >> %_gdalproj_%
|
||||
echo ^<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|%_winver_%'"^> >> %_gdalproj_%
|
||||
echo ^<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /^> >> %_gdalproj_%
|
||||
echo ^</ImportGroup^> >> %_gdalproj_%
|
||||
echo ^<PropertyGroup Label="UserMacros" /^> >> %_gdalproj_%
|
||||
echo ^<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|%_winver_%'"^> >> %_gdalproj_%
|
||||
echo ^<NMakeBuildCommandLine^>nmake -f makefile.vc MSVC_VER=%_clver_% %_nmake_opt_win64_% DEBUG=1 WITH_PDB=1^</NMakeBuildCommandLine^> >> %_gdalproj_%
|
||||
echo ^<NMakeOutput^>^</NMakeOutput^> >> %_gdalproj_%
|
||||
echo ^<NMakeCleanCommandLine^>nmake -f makefile.vc MSVC_VER=%_clver_% %_nmake_opt_win64_% DEBUG=1 WITH_PDB=1 clean^</NMakeCleanCommandLine^> >> %_gdalproj_%
|
||||
echo ^<NMakeReBuildCommandLine^>nmake -f makefile.vc MSVC_VER=%_clver_% %_nmake_opt_win64_% DEBUG=1 WITH_PDB=1 clean ^&^& nmake -f makefile.vc MSVC_VER=%_clver_% %_nmake_opt_win64_% DEBUG=1 WITH_PDB=1^</NMakeReBuildCommandLine^> >> %_gdalproj_%
|
||||
echo ^<NMakePreprocessorDefinitions^>%_winver_%;_DEBUG;$(NMakePreprocessorDefinitions)^</NMakePreprocessorDefinitions^> >> %_gdalproj_%
|
||||
echo ^<LibraryPath^>$(VC_LibraryPath_%_buildplatf_%);$(WindowsSDK_LibraryPath_%_buildplatf_%);$(VC_SourcePath);^</LibraryPath^> >> %_gdalproj_%
|
||||
echo ^</PropertyGroup^> >> %_gdalproj_%
|
||||
echo ^<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|%_winver_%'"^> >> %_gdalproj_%
|
||||
echo ^<NMakeBuildCommandLine^>nmake -f makefile.vc MSVC_VER=%_clver_% %_nmake_opt_win64_% ^</NMakeBuildCommandLine^> >> %_gdalproj_%
|
||||
echo ^<NMakeOutput^>^</NMakeOutput^> >> %_gdalproj_%
|
||||
echo ^<NMakeCleanCommandLine^>nmake -f makefile.vc MSVC_VER=%_clver_% %_nmake_opt_win64_% clean^</NMakeCleanCommandLine^> >> %_gdalproj_%
|
||||
echo ^<NMakeReBuildCommandLine^>nmake -f makefile.vc MSVC_VER=%_clver_% %_nmake_opt_win64_% clean ^&^& nmake -f makefile.vc MSVC_VER=%_clver_%^</NMakeReBuildCommandLine^> >> %_gdalproj_%
|
||||
echo ^<NMakePreprocessorDefinitions^>%_winver_%;NDEBUG;$(NMakePreprocessorDefinitions)^</NMakePreprocessorDefinitions^> >> %_gdalproj_%
|
||||
echo ^<LibraryPath^>$(VC_LibraryPath_%_buildplatf_%);$(WindowsSDK_LibraryPath_%_buildplatf_%);$(VC_SourcePath);^</LibraryPath^> >> %_gdalproj_%
|
||||
echo ^</PropertyGroup^> >> %_gdalproj_%
|
||||
echo ^<ItemDefinitionGroup^> >> %_gdalproj_%
|
||||
echo ^</ItemDefinitionGroup^> >> %_gdalproj_%
|
||||
|
||||
:: create a root path with nmake files
|
||||
|
||||
echo ^<ItemGroup^> >> %_gdalproj_%
|
||||
echo ^<Test Include="%_gdaldir_%\nmake.local" /^> >> %_gdalproj_%
|
||||
echo ^<Test Include="%_gdaldir_%\nmake.opt" /^> >> %_gdalproj_%
|
||||
echo ^</ItemGroup^> >> %_gdalproj_%
|
||||
|
||||
echo ^<ItemGroup^> >> %_gdalfltr_%
|
||||
echo ^<Test Include="%_gdaldir_%\nmake.local" /^> >> %_gdalfltr_%
|
||||
echo ^<Test Include="%_gdaldir_%\nmake.opt" /^> >> %_gdalfltr_%
|
||||
echo ^</ItemGroup^> >> %_gdalfltr_%
|
||||
|
||||
:: Use base of main .vcxproj and .filters as template for test project
|
||||
|
||||
if defined _testdir_ (
|
||||
copy /Y %_gdalproj_% %_testproj_% >NUL
|
||||
copy /Y %_gdalfltr_% %_testfltr_% >NUL
|
||||
)
|
||||
:: if defined _testdir_
|
||||
|
||||
:: create main project filters only
|
||||
|
||||
echo ^<ItemGroup^> >> %_gdalfltr_%
|
||||
call :create_filter %_gdaldir_% "*.vc;" 1 "Make Files" "None" %_gdalproj_% %_gdalfltr_%
|
||||
call :create_filter %_gdaldir_% "*.h;*.hpp" 1 "Include Files" "ClInclude" %_gdalproj_% %_gdalfltr_%
|
||||
call :create_filter %_gdaldir_% "*.c;*.cpp" 1 "Source Files" "ClCompile" %_gdalproj_% %_gdalfltr_%
|
||||
echo ^</ItemGroup^> >> %_gdalfltr_%
|
||||
|
||||
:: create test project filters only
|
||||
|
||||
if defined _testdir_ (
|
||||
echo ^<ItemGroup^> >> %_testfltr_%
|
||||
call :create_filter %_testdir_% "*.vc;" 1 "Make Files" "None" %_testproj_% %_testfltr_%
|
||||
call :create_filter %_testdir_% "*.h;*.hpp" 1 "Include Files" "ClInclude" %_testproj_% %_testfltr_%
|
||||
call :create_filter %_testdir_% "*.c;*.cpp" 1 "Source Files" "ClCompile" %_testproj_% %_testfltr_%
|
||||
echo ^</ItemGroup^> >> %_testfltr_%
|
||||
)
|
||||
:: if defined _testdir_
|
||||
|
||||
:: create main project and links to filters
|
||||
|
||||
echo ^<ItemGroup^> >> %_gdalproj_%
|
||||
echo ^<ItemGroup^> >> %_gdalfltr_%
|
||||
call :create_filter %_gdaldir_% "*.vc" 0 "Make Files" "None" %_gdalproj_% %_gdalfltr_%
|
||||
echo ^</ItemGroup^> >> %_gdalproj_%
|
||||
echo ^</ItemGroup^> >> %_gdalfltr_%
|
||||
|
||||
echo ^<ItemGroup^> >> %_gdalproj_%
|
||||
echo ^<ItemGroup^> >> %_gdalfltr_%
|
||||
call :create_filter %_gdaldir_% "*.h;*.hpp" 0 "Include Files" "ClInclude" %_gdalproj_% %_gdalfltr_%
|
||||
echo ^</ItemGroup^> >> %_gdalproj_%
|
||||
echo ^</ItemGroup^> >> %_gdalfltr_%
|
||||
|
||||
echo ^<ItemGroup^> >> %_gdalproj_%
|
||||
echo ^<ItemGroup^> >> %_gdalfltr_%
|
||||
call :create_filter %_gdaldir_% "*.c;*.cpp" 0 "Source Files" "ClCompile" %_gdalproj_% %_gdalfltr_%
|
||||
echo ^</ItemGroup^> >> %_gdalproj_%
|
||||
echo ^</ItemGroup^> >> %_gdalfltr_%
|
||||
|
||||
:: create test project and links to filters
|
||||
|
||||
if defined _testdir_ (
|
||||
echo ^<ItemGroup^> >> %_testproj_%
|
||||
echo ^<ItemGroup^> >> %_testfltr_%
|
||||
call :create_filter %_testdir_% "*.vc" 0 "Make Files" "None" %_testproj_% %_testfltr_%
|
||||
echo ^</ItemGroup^> >> %_testproj_%
|
||||
echo ^</ItemGroup^> >> %_testfltr_%
|
||||
|
||||
echo ^<ItemGroup^> >> %_testproj_%
|
||||
echo ^<ItemGroup^> >> %_testfltr_%
|
||||
call :create_filter %_testdir_% "*.h;*.hpp" 0 "Include Files" "ClInclude" %_testproj_% %_testfltr_%
|
||||
echo ^</ItemGroup^> >> %_testproj_%
|
||||
echo ^</ItemGroup^> >> %_testfltr_%
|
||||
|
||||
echo ^<ItemGroup^> >> %_testproj_%
|
||||
echo ^<ItemGroup^> >> %_testfltr_%
|
||||
call :create_filter %_testdir_% "*.c;*.cpp" 0 "Source Files" "ClCompile" %_testproj_% %_testfltr_%
|
||||
echo ^</ItemGroup^> >> %_testproj_%
|
||||
echo ^</ItemGroup^> >> %_testfltr_%
|
||||
)
|
||||
:: if defined _testdir_
|
||||
|
||||
:: **********************************************
|
||||
:: Finalize main and test projects
|
||||
:: **********************************************
|
||||
|
||||
echo ^</Project^> >> %_gdalfltr_%
|
||||
|
||||
echo ^<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/^> >> %_gdalproj_%
|
||||
echo ^</Project^> >> %_gdalproj_%
|
||||
|
||||
if defined _testdir_ (
|
||||
echo ^</Project^> >> %_testfltr_%
|
||||
|
||||
echo ^<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/^> >> %_testproj_%
|
||||
echo ^</Project^> >> %_testproj_%
|
||||
)
|
||||
:: if defined _testdir_ (
|
||||
|
||||
:: *******************************************************
|
||||
:: Generate .sln file with main and test projects attached
|
||||
:: *******************************************************
|
||||
|
||||
echo Projects done!
|
||||
|
||||
echo Launch Visual Studio IDE
|
||||
echo * Open project %_gdalproj_%
|
||||
echo * Add project %_testproj_%
|
||||
echo * Configure Build Dependencies to build the main project before the test project.
|
||||
echo * Save solution in .sln file
|
||||
echo Done!
|
||||
|
||||
:: **********************************************
|
||||
:: The end
|
||||
:: **********************************************
|
||||
|
||||
goto :end
|
||||
|
||||
:: **********************************************
|
||||
:create_filter
|
||||
:: **********************************************
|
||||
|
||||
set _path_=%1
|
||||
set _mask_=%2
|
||||
set _fonly_=%3
|
||||
set _name_=%4
|
||||
set _item_=%5
|
||||
set _proj_=%6
|
||||
set _fltr_=%7
|
||||
|
||||
:: *********************
|
||||
:: Remove quotes
|
||||
:: *********************
|
||||
|
||||
set _name_=%_name_:"=%
|
||||
set _mask_=%_mask_:"=%
|
||||
set _fonly_=%_fonly_:"=%
|
||||
set _item_=%_item_:"=%
|
||||
|
||||
:: *********************
|
||||
:: Stop folders
|
||||
:: *********************
|
||||
|
||||
set _folder_=%~nx1
|
||||
|
||||
for %%d in (ci data debian doc html m4 pymod scripts swig) do (
|
||||
if "%_folder_%"=="%%d" (
|
||||
goto :end
|
||||
)
|
||||
)
|
||||
:: *********************
|
||||
:: Check if a folder is empty
|
||||
:: *********************
|
||||
|
||||
set _find_=1
|
||||
|
||||
for /R %%f in (%_mask_%) do (
|
||||
goto :not_empty
|
||||
)
|
||||
|
||||
set _find_=0
|
||||
|
||||
:not_empty
|
||||
|
||||
if %_find_%==0 (
|
||||
goto :end
|
||||
)
|
||||
|
||||
:: *********************
|
||||
:: Add filters
|
||||
:: *********************
|
||||
|
||||
if %_fonly_%==1 (
|
||||
echo ^<Filter Include="%_name_%"^> >> %_fltr_%
|
||||
echo ^<Extensions^>%_mask_%^</Extensions^> >> %_fltr_%
|
||||
echo ^</Filter^> >> %_fltr_%
|
||||
)
|
||||
|
||||
:: *********************
|
||||
:: Add files
|
||||
:: *********************
|
||||
|
||||
if %_fonly_%==0 (
|
||||
for %%f in (%_mask_%) do (
|
||||
echo ^<%_item_% Include="%_path_%\%%f"/^> >> %_proj_%
|
||||
echo ^<%_item_% Include="%_path_%\%%f"^> >> %_fltr_%
|
||||
echo ^<Filter^>%_name_%^</Filter^> >> %_fltr_%
|
||||
echo ^</%_item_%^> >> %_fltr_%
|
||||
)
|
||||
)
|
||||
|
||||
:: *********************
|
||||
:: Clib all the branches recursivelly
|
||||
:: *********************
|
||||
|
||||
for /D %%d in (%_path_%\*) do (
|
||||
cd %%d
|
||||
call :create_filter %%d "%_mask_%" %_fonly_% "%_name_%\%%~nxd" %_item_% %_proj_% %_fltr_%
|
||||
cd ..
|
||||
)
|
||||
|
||||
:: **********************************************
|
||||
:end
|
||||
:: **********************************************
|
||||
|
|
|
@ -1,38 +1,38 @@
|
|||
OBJ = aodatasource.obj aodriver.obj aolayer.obj aoutils.obj
|
||||
EXTRAFLAGS = -I.. -I..\.. -I$(AO_INC)
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
PLUGIN_DLL = ogr_ao.dll
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
$(INSTALL) *.obj ..\o
|
||||
|
||||
all: default
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del *.dll
|
||||
-del *.exp
|
||||
-del *.lib
|
||||
-del *.manifest
|
||||
-del *.pdb
|
||||
-del *.tlh
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll $(LDEBUG) /out:$(PLUGIN_DLL) $(OBJ) $(GDAL_ROOT)/gdal_i.lib $(SDE_LIB)
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest -outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
|
||||
#ogr_ao.dll: $(OBJ)
|
||||
# link /dll $(LDEBUG) /out:ogr_ao.dll $(OBJ) \
|
||||
# $(GDALLIB) $(AO_LIB)
|
||||
OBJ = aodatasource.obj aodriver.obj aolayer.obj aoutils.obj
|
||||
EXTRAFLAGS = -I.. -I..\.. -I$(AO_INC)
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
PLUGIN_DLL = ogr_ao.dll
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
$(INSTALL) *.obj ..\o
|
||||
|
||||
all: default
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del *.dll
|
||||
-del *.exp
|
||||
-del *.lib
|
||||
-del *.manifest
|
||||
-del *.pdb
|
||||
-del *.tlh
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll $(LDEBUG) /out:$(PLUGIN_DLL) $(OBJ) $(GDAL_ROOT)/gdal_i.lib $(SDE_LIB)
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest -outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
|
||||
#ogr_ao.dll: $(OBJ)
|
||||
# link /dll $(LDEBUG) /out:ogr_ao.dll $(OBJ) \
|
||||
# $(GDALLIB) $(AO_LIB)
|
||||
# copy ogr_ao.* c:\warmerda\bld\bin\gdalplugins\
|
|
@ -1,14 +1,14 @@
|
|||
|
||||
|
||||
OBJ = ogrdb2cli.obj gdaldb2rasterband.obj ogrdb2datasourcemd.obj ogrdb2driver.obj ogrdb2datasource.obj ogrdb2layer.obj ogrdb2tablelayer.obj ogrdb2selectlayer.obj
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
#EXTRAFLAGS = -I.. -I..\.. -I..\..\..\frmts\mem -DDEBUG_SQL -DDEBUG_DB2
|
||||
EXTRAFLAGS = -I.. -I..\.. -I..\..\..\frmts\mem
|
||||
default: $(OBJ)
|
||||
|
||||
clean:
|
||||
-del *.obj *.pdb
|
||||
|
||||
|
||||
OBJ = ogrdb2cli.obj gdaldb2rasterband.obj ogrdb2datasourcemd.obj ogrdb2driver.obj ogrdb2datasource.obj ogrdb2layer.obj ogrdb2tablelayer.obj ogrdb2selectlayer.obj
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
#EXTRAFLAGS = -I.. -I..\.. -I..\..\..\frmts\mem -DDEBUG_SQL -DDEBUG_DB2
|
||||
EXTRAFLAGS = -I.. -I..\.. -I..\..\..\frmts\mem
|
||||
default: $(OBJ)
|
||||
|
||||
clean:
|
||||
-del *.obj *.pdb
|
||||
|
|
|
@ -1,14 +1,14 @@
|
|||
|
||||
OBJ = ogrdodsdriver.obj ogrdodsdatasource.obj ogrdodslayer.obj ogrdodssequencelayer.obj ogrdodsfielddefn.obj ogrdodsgrid.obj
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
EXTRAFLAGS = -I.. -I$(DODS_DIR) -I$(DODS_DIR)\include -I$(DODS_DIR)\include\gnu -I$(DODS_DIR)\include\pthreads -I$(DODS_DIR)\include\xdr /DWIN32 /DWIN32_LEAN_AND_MEAN -DFRMT_dods $(DODS_FLAGS) /GR
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
|
||||
|
||||
OBJ = ogrdodsdriver.obj ogrdodsdatasource.obj ogrdodslayer.obj ogrdodssequencelayer.obj ogrdodsfielddefn.obj ogrdodsgrid.obj
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
EXTRAFLAGS = -I.. -I$(DODS_DIR) -I$(DODS_DIR)\include -I$(DODS_DIR)\include\gnu -I$(DODS_DIR)\include\pthreads -I$(DODS_DIR)\include\xdr /DWIN32 /DWIN32_LEAN_AND_MEAN -DFRMT_dods $(DODS_FLAGS) /GR
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
|
||||
|
|
|
@ -1,47 +1,47 @@
|
|||
|
||||
OBJ = \
|
||||
ogrdwgdriver.obj \
|
||||
ogrdwgdatasource.obj \
|
||||
ogrdwglayer.obj \
|
||||
ogrdwgblockslayer.obj \
|
||||
ogrdwg_blockmap.obj \
|
||||
ogrdwg_dimension.obj \
|
||||
ogrdwg_hatch.obj \
|
||||
ogrdgnv8driver.obj \
|
||||
ogrdgnv8datasource.obj \
|
||||
ogrdgnv8layer.obj \
|
||||
ogrteigha.obj
|
||||
|
||||
DXF_OBJ = ..\dxf\intronurbs.obj ..\dxf\ogrdxf_polyline_smooth.obj ..\dxf\ogr_autocad_services.obj
|
||||
|
||||
PLUGIN_DLL = ogr_DWG_DGNV8.dll
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
EXTRAFLAGS = -I.. -I..\.. $(TD_FLAGS) $(TD_INCLUDE) -I..\dxf
|
||||
|
||||
default: $(OBJ)
|
||||
|
||||
clean:
|
||||
-del *.lib
|
||||
-del *.obj *.pdb
|
||||
-del *.dll
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll $(LDEBUG) /out:$(PLUGIN_DLL) $(OBJ) $(DXF_OBJ) \
|
||||
$(GDAL_ROOT)/gdal_i.lib $(TD_LIBS)
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest \
|
||||
-outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
|
||||
createdgnv8testfile.exe: createdgnv8testfile.obj
|
||||
cl /Zi createdgnv8testfile.obj $(TD_LIBS)
|
||||
|
||||
|
||||
|
||||
OBJ = \
|
||||
ogrdwgdriver.obj \
|
||||
ogrdwgdatasource.obj \
|
||||
ogrdwglayer.obj \
|
||||
ogrdwgblockslayer.obj \
|
||||
ogrdwg_blockmap.obj \
|
||||
ogrdwg_dimension.obj \
|
||||
ogrdwg_hatch.obj \
|
||||
ogrdgnv8driver.obj \
|
||||
ogrdgnv8datasource.obj \
|
||||
ogrdgnv8layer.obj \
|
||||
ogrteigha.obj
|
||||
|
||||
DXF_OBJ = ..\dxf\intronurbs.obj ..\dxf\ogrdxf_polyline_smooth.obj ..\dxf\ogr_autocad_services.obj
|
||||
|
||||
PLUGIN_DLL = ogr_DWG_DGNV8.dll
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
EXTRAFLAGS = -I.. -I..\.. $(TD_FLAGS) $(TD_INCLUDE) -I..\dxf
|
||||
|
||||
default: $(OBJ)
|
||||
|
||||
clean:
|
||||
-del *.lib
|
||||
-del *.obj *.pdb
|
||||
-del *.dll
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll $(LDEBUG) /out:$(PLUGIN_DLL) $(OBJ) $(DXF_OBJ) \
|
||||
$(GDAL_ROOT)/gdal_i.lib $(TD_LIBS)
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest \
|
||||
-outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
|
||||
createdgnv8testfile.exe: createdgnv8testfile.obj
|
||||
cl /Zi createdgnv8testfile.obj $(TD_LIBS)
|
||||
|
||||
|
||||
|
|
|
@ -1,39 +1,39 @@
|
|||
OBJ = FGdbDriver.obj FGdbDatasource.obj FGdbLayer.obj FGdbUtils.obj FGdbResultLayer.obj
|
||||
EXTRAFLAGS = -I.. -I..\generic -I..\.. -I$(FGDB_INC)
|
||||
|
||||
!IFDEF FGDB_VERSION
|
||||
EXTRAFLAGS = $(EXTRAFLAGS) -DFGDB_VERSION=$(FGDB_VERSION)
|
||||
!ELSE
|
||||
EXTRAFLAGS = $(EXTRAFLAGS) -DFGDB_VERSION=010300
|
||||
!ENDIF
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
PLUGIN_DLL = ogr_FileGDB.dll
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
$(INSTALL) *.obj ..\o
|
||||
|
||||
all: default
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del *.dll
|
||||
-del *.exp
|
||||
-del *.lib
|
||||
-del *.manifest
|
||||
-del *.pdb
|
||||
-del *.tlh
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll $(LDEBUG) /out:$(PLUGIN_DLL) $(OBJ) $(GDAL_ROOT)/gdal_i.lib $(FGDB_LIB)
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest -outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
OBJ = FGdbDriver.obj FGdbDatasource.obj FGdbLayer.obj FGdbUtils.obj FGdbResultLayer.obj
|
||||
EXTRAFLAGS = -I.. -I..\generic -I..\.. -I$(FGDB_INC)
|
||||
|
||||
!IFDEF FGDB_VERSION
|
||||
EXTRAFLAGS = $(EXTRAFLAGS) -DFGDB_VERSION=$(FGDB_VERSION)
|
||||
!ELSE
|
||||
EXTRAFLAGS = $(EXTRAFLAGS) -DFGDB_VERSION=010300
|
||||
!ENDIF
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
PLUGIN_DLL = ogr_FileGDB.dll
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
$(INSTALL) *.obj ..\o
|
||||
|
||||
all: default
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del *.dll
|
||||
-del *.exp
|
||||
-del *.lib
|
||||
-del *.manifest
|
||||
-del *.pdb
|
||||
-del *.tlh
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll $(LDEBUG) /out:$(PLUGIN_DLL) $(OBJ) $(GDAL_ROOT)/gdal_i.lib $(FGDB_LIB)
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest -outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
|
|
|
@ -1,28 +1,28 @@
|
|||
# $Id$
|
||||
#
|
||||
# Makefile building json-c library (http://oss.metaparadigm.com/json-c/)
|
||||
#
|
||||
|
||||
OBJ = \
|
||||
arraylist.obj \
|
||||
debug.obj \
|
||||
json_object.obj \
|
||||
json_tokener.obj \
|
||||
json_util.obj \
|
||||
linkhash.obj \
|
||||
printbuf.obj \
|
||||
json_object_iterator.obj \
|
||||
json_c_version.obj
|
||||
|
||||
GDAL_ROOT = ..\..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
# disable warning C4306: 'type cast' : conversion from 'int' to 'void *' of greater size
|
||||
EXTRAFLAGS = -I.. -I..\.. -I..\..\.. $(SOFTWARNFLAGS) /wd4306
|
||||
|
||||
default: $(OBJ)
|
||||
|
||||
clean:
|
||||
-del *.lib
|
||||
-del *.obj *.pdb
|
||||
# $Id$
|
||||
#
|
||||
# Makefile building json-c library (http://oss.metaparadigm.com/json-c/)
|
||||
#
|
||||
|
||||
OBJ = \
|
||||
arraylist.obj \
|
||||
debug.obj \
|
||||
json_object.obj \
|
||||
json_tokener.obj \
|
||||
json_util.obj \
|
||||
linkhash.obj \
|
||||
printbuf.obj \
|
||||
json_object_iterator.obj \
|
||||
json_c_version.obj
|
||||
|
||||
GDAL_ROOT = ..\..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
# disable warning C4306: 'type cast' : conversion from 'int' to 'void *' of greater size
|
||||
EXTRAFLAGS = -I.. -I..\.. -I..\..\.. $(SOFTWARNFLAGS) /wd4306
|
||||
|
||||
default: $(OBJ)
|
||||
|
||||
clean:
|
||||
-del *.lib
|
||||
-del *.obj *.pdb
|
||||
|
|
|
@ -1,31 +1,31 @@
|
|||
|
||||
OBJ = ogringresdriver.obj ogringresdatasource.obj ogringreslayer.obj \
|
||||
ogringrestablelayer.obj ogringresresultlayer.obj \
|
||||
ogringresstatement.obj
|
||||
|
||||
PLUGIN_DLL = ogr_Ingres.dll
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
EXTRAFLAGS = -I.. -I..\.. -I$(INGRES_INC_DIR)
|
||||
|
||||
default: $(OBJ)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll /out:$(PLUGIN_DLL) $(OBJ) $(GDALLIB) $(INGRES_LIB)
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest -outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
|
||||
clean:
|
||||
-del *.lib
|
||||
-del *.obj *.pdb *.exp
|
||||
-del *.exe
|
||||
-del *.dll
|
||||
-del *.manifest
|
||||
|
||||
OBJ = ogringresdriver.obj ogringresdatasource.obj ogringreslayer.obj \
|
||||
ogringrestablelayer.obj ogringresresultlayer.obj \
|
||||
ogringresstatement.obj
|
||||
|
||||
PLUGIN_DLL = ogr_Ingres.dll
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
EXTRAFLAGS = -I.. -I..\.. -I$(INGRES_INC_DIR)
|
||||
|
||||
default: $(OBJ)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll /out:$(PLUGIN_DLL) $(OBJ) $(GDALLIB) $(INGRES_LIB)
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest -outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
|
||||
clean:
|
||||
-del *.lib
|
||||
-del *.obj *.pdb *.exp
|
||||
-del *.exe
|
||||
-del *.dll
|
||||
-del *.manifest
|
||||
|
|
|
@ -1,37 +1,37 @@
|
|||
GDAL_ROOT = ..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
CORE_OBJ = ogrlibkmlgeometry.obj \
|
||||
ogrlibkmlfield.obj \
|
||||
ogrlibkmlfeature.obj \
|
||||
ogrlibkmlfeaturestyle.obj \
|
||||
ogrlibkmlstyle.obj
|
||||
|
||||
PLUGIN_DLL = ogr_LIBKML.dll
|
||||
|
||||
OGR_OBJ = ogrlibkmldriver.obj \
|
||||
ogrlibkmldatasource.obj \
|
||||
ogrlibkmllayer.obj
|
||||
|
||||
OBJ = $(CORE_OBJ) $(OGR_OBJ)
|
||||
|
||||
EXTRAFLAGS = -I.. -I..\.. $(LIBKML_INCLUDE)
|
||||
|
||||
default: $(OBJ)
|
||||
|
||||
clean:
|
||||
-del *.lib
|
||||
-del *.obj *.pdb
|
||||
-del *.dll
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll $(LDEBUG) /out:$(PLUGIN_DLL) $(OBJ) /LTCG \
|
||||
$(GDAL_ROOT)/gdal_i.lib $(LIBKML_LIBS)
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
CORE_OBJ = ogrlibkmlgeometry.obj \
|
||||
ogrlibkmlfield.obj \
|
||||
ogrlibkmlfeature.obj \
|
||||
ogrlibkmlfeaturestyle.obj \
|
||||
ogrlibkmlstyle.obj
|
||||
|
||||
PLUGIN_DLL = ogr_LIBKML.dll
|
||||
|
||||
OGR_OBJ = ogrlibkmldriver.obj \
|
||||
ogrlibkmldatasource.obj \
|
||||
ogrlibkmllayer.obj
|
||||
|
||||
OBJ = $(CORE_OBJ) $(OGR_OBJ)
|
||||
|
||||
EXTRAFLAGS = -I.. -I..\.. $(LIBKML_INCLUDE)
|
||||
|
||||
default: $(OBJ)
|
||||
|
||||
clean:
|
||||
-del *.lib
|
||||
-del *.obj *.pdb
|
||||
-del *.dll
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll $(LDEBUG) /out:$(PLUGIN_DLL) $(OBJ) /LTCG \
|
||||
$(GDAL_ROOT)/gdal_i.lib $(LIBKML_LIBS)
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
|
||||
|
|
|
@ -1,32 +1,32 @@
|
|||
OBJ = ogrmongodbdriver.obj
|
||||
EXTRAFLAGS = -I.. -I..\generic -I..\.. -I$(MONGODB_INC) -I$(BOOST_INC) $(MONGODB_CFLAGS)
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
PLUGIN_DLL = ogr_MongoDB.dll
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
|
||||
all: default
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del *.dll
|
||||
-del *.exp
|
||||
-del *.lib
|
||||
-del *.manifest
|
||||
-del *.pdb
|
||||
-del *.tlh
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll $(LDEBUG) /out:$(PLUGIN_DLL) $(OBJ) $(GDAL_ROOT)/gdal_i.lib $(MONGODB_LIBS) wsock32.lib
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest -outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
OBJ = ogrmongodbdriver.obj
|
||||
EXTRAFLAGS = -I.. -I..\generic -I..\.. -I$(MONGODB_INC) -I$(BOOST_INC) $(MONGODB_CFLAGS)
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
PLUGIN_DLL = ogr_MongoDB.dll
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
default: $(OBJ)
|
||||
|
||||
all: default
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del *.dll
|
||||
-del *.exp
|
||||
-del *.lib
|
||||
-del *.manifest
|
||||
-del *.pdb
|
||||
-del *.tlh
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(OBJ)
|
||||
link /dll $(LDEBUG) /out:$(PLUGIN_DLL) $(OBJ) $(GDAL_ROOT)/gdal_i.lib $(MONGODB_LIBS) wsock32.lib
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest -outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
|
|
|
@ -1,43 +1,43 @@
|
|||
OBJ = \
|
||||
.\ogrmssqlgeometryparser.obj \
|
||||
.\ogrmssqlgeometryvalidator.obj \
|
||||
.\ogrmssqlgeometrywriter.obj \
|
||||
.\ogrmssqlspatialdatasource.obj \
|
||||
.\ogrmssqlspatialdriver.obj \
|
||||
.\ogrmssqlspatiallayer.obj \
|
||||
.\ogrmssqlspatialselectlayer.obj \
|
||||
.\ogrmssqlspatialtablelayer.obj
|
||||
|
||||
PLUGINOBJ = $(OBJ:.\=plugin\)
|
||||
|
||||
PLUGIN_DLL = ogr_MSSQLSpatial.dll
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
EXTRAFLAGS = -I.. -I..\.. $(SQLNCLI_INCLUDE)
|
||||
|
||||
default: $(OBJ)
|
||||
|
||||
{.}.cpp{plugin\}.obj:
|
||||
-mkdir plugin
|
||||
$(CPP) $(CPPFLAGS) /DMSSQL_BCP_SUPPORTED=1 /Fo$@ /c $<
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(PLUGINOBJ)
|
||||
link /dll /out:$(PLUGIN_DLL) $(PLUGINOBJ) $(GDALLIB) $(ODBCLIB) $(SQLNCLI_LIB) $(LDEBUG)
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest -outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
clean:
|
||||
-del *.lib
|
||||
-del *.obj *.pdb *.exp
|
||||
-del *.exe
|
||||
-del *.dll
|
||||
-del *.manifest
|
||||
-del plugin\*.obj
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
OBJ = \
|
||||
.\ogrmssqlgeometryparser.obj \
|
||||
.\ogrmssqlgeometryvalidator.obj \
|
||||
.\ogrmssqlgeometrywriter.obj \
|
||||
.\ogrmssqlspatialdatasource.obj \
|
||||
.\ogrmssqlspatialdriver.obj \
|
||||
.\ogrmssqlspatiallayer.obj \
|
||||
.\ogrmssqlspatialselectlayer.obj \
|
||||
.\ogrmssqlspatialtablelayer.obj
|
||||
|
||||
PLUGINOBJ = $(OBJ:.\=plugin\)
|
||||
|
||||
PLUGIN_DLL = ogr_MSSQLSpatial.dll
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
|
||||
EXTRAFLAGS = -I.. -I..\.. $(SQLNCLI_INCLUDE)
|
||||
|
||||
default: $(OBJ)
|
||||
|
||||
{.}.cpp{plugin\}.obj:
|
||||
-mkdir plugin
|
||||
$(CPP) $(CPPFLAGS) /DMSSQL_BCP_SUPPORTED=1 /Fo$@ /c $<
|
||||
|
||||
plugin: $(PLUGIN_DLL)
|
||||
|
||||
$(PLUGIN_DLL): $(PLUGINOBJ)
|
||||
link /dll /out:$(PLUGIN_DLL) $(PLUGINOBJ) $(GDALLIB) $(ODBCLIB) $(SQLNCLI_LIB) $(LDEBUG)
|
||||
if exist $(PLUGIN_DLL).manifest mt -manifest $(PLUGIN_DLL).manifest -outputresource:$(PLUGIN_DLL);2
|
||||
|
||||
clean:
|
||||
-del *.lib
|
||||
-del *.obj *.pdb *.exp
|
||||
-del *.exe
|
||||
-del *.dll
|
||||
-del *.manifest
|
||||
-del plugin\*.obj
|
||||
|
||||
plugin-install:
|
||||
-mkdir $(PLUGINDIR)
|
||||
$(INSTALL) $(PLUGIN_DLL) $(PLUGINDIR)
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
@echo off
|
||||
cd %1
|
||||
nmake /NOLOGO /f makefile.vc %2
|
||||
if ERRORLEVEL 1 exit 1
|
||||
cd ..
|
||||
@echo off
|
||||
cd %1
|
||||
nmake /NOLOGO /f makefile.vc %2
|
||||
if ERRORLEVEL 1 exit 1
|
||||
cd ..
|
||||
|
|
|
@ -1,17 +1,17 @@
|
|||
OBJ = gnm_wrap.obj
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
CFLAGS=$(CFLAGS) -DSWIG_NOARRAYS # needed for Swig 2.0.4 and earlier
|
||||
|
||||
default: $(OBJ)
|
||||
xcopy /D /Y *.obj ..
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del *.cs
|
||||
-del *.cpp
|
||||
|
||||
.cpp.obj:
|
||||
$(CC) $(CFLAGS) $(JAVA_INCLUDE) /c $*.cpp
|
||||
OBJ = gnm_wrap.obj
|
||||
|
||||
GDAL_ROOT = ..\..\..
|
||||
|
||||
!INCLUDE $(GDAL_ROOT)\nmake.opt
|
||||
CFLAGS=$(CFLAGS) -DSWIG_NOARRAYS # needed for Swig 2.0.4 and earlier
|
||||
|
||||
default: $(OBJ)
|
||||
xcopy /D /Y *.obj ..
|
||||
|
||||
clean:
|
||||
-del *.obj
|
||||
-del *.cs
|
||||
-del *.cpp
|
||||
|
||||
.cpp.obj:
|
||||
$(CC) $(CFLAGS) $(JAVA_INCLUDE) /c $*.cpp
|
||||
|
|
Loading…
Reference in New Issue