Skip to content

Commit

Permalink
Windows makefiles.
Browse files Browse the repository at this point in the history
Submitted by:	Scott

SVN-Revision: 29
  • Loading branch information
kientzle committed May 5, 2008
1 parent 4beb020 commit e1ab3b3
Show file tree
Hide file tree
Showing 3 changed files with 225 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
.git* export-ignore

*.nt -crlf
*.sh crlf=input
117 changes: 117 additions & 0 deletions windows/mvcpp.nt
Original file line number Diff line number Diff line change
@@ -0,0 +1,117 @@
#/* FILE: mvcpp.nt
# *
# * Copyright (c) 2008
# * TouchNet Information Systems, Inc.
# * All Rights Reserved
# *
# * This program is an unpublished copyright work of TouchNet Information
# * Systems, Inc. of Lenexa, KS. The program, all information disclosed
# * and the matter shown and described hereon or herewith are confidential
# * and proprietary to TouchNet Information Systems, Inc.
# *
# ******************************************************************************
# *
# * $LastChangedBy$
# * $Locker: $
# * $ProjectName: $
# * $ProjectRevision: $
# * $LastChangedRevision$
# * $LastChangedDate$
# * $State: $
# * $RCSfile: $
# * $Source: $
# *
# * Change Log:
# * $Log: $
# *
# */

.SUFFIXES : .c .cpp .obm

ZLIB_INCL=\3rdParty\ZLib\Current\Include

EXTRA_DEFINES=/DLIBARCHIVE_STATIC=1

!ifdef DEBUG
DEST_PATH=.\lib\mvcpp\debug
OBJ_DIR=obj\debug
COMPILE_FLAG=/MTd /DDEBUG=1 $(EXTRA_DEFINES) /Zi /Fd$(OBJ_DIR)\libarchive.pdb
!else
DEST_PATH=.\lib\mvcpp
OBJ_DIR=obj
COMPILE_FLAG=/MT $(EXTRA_DEFINES) /Fd$(OBJ_DIR)\libarchive.pdb
!endif

INCLUDE=.;$(MSDEVDIR)\INCLUDE;$(ZLIB_INCL);
INCLUDE_OPTS=

NT_CPP=cl
NT_C=cl
NT_LIBRARIAN=lib

###
NT_C_OPTS=$(COMPILE_FLAG) /GX /Zl /Zp1 /nologo /c /G5 /Oi /Ot /TC /DVC_EXTRANLEAN /DWIN32_LEAN_AND_MEAN $(INCLUDE_OPTS)
NT_CPP_OPTS=$(COMPILE_FLAG) /GX /Zl /Zp1 /nologo /c /G5 /Oi /Ot /TP /DVC_EXTRANLEAN /DWIN32_LEAN_AND_MEAN $(INCLUDE_OPTS)
NT_LIB_OPTS=

.cpp{$(OBJ_DIR)}.obm:
-md $(OBJ_DIR) > nul 2>nul
$(NT_CPP) $(NT_CPP_OPTS) -Fo$*.obm $<

.c{$(OBJ_DIR)}.obm:
-md $(OBJ_DIR) > nul 2>nul
$(NT_C) $(NT_C_OPTS) -Fo$*.obm $<


OBJS=\
$(OBJ_DIR)\archive_check_magic.obm $(OBJ_DIR)\archive_entry.obm \
$(OBJ_DIR)\archive_entry_copy_stat.obm $(OBJ_DIR)\archive_entry_link_resolver.obm \
$(OBJ_DIR)\archive_entry_stat.obm $(OBJ_DIR)\archive_entry_strmode.obm \
$(OBJ_DIR)\archive_read.obm $(OBJ_DIR)\archive_read_data_into_fd.obm \
$(OBJ_DIR)\archive_read_extract.obm $(OBJ_DIR)\archive_read_open_fd.obm \
$(OBJ_DIR)\archive_read_open_file.obm $(OBJ_DIR)\archive_read_open_filename.obm \
$(OBJ_DIR)\archive_read_open_memory.obm $(OBJ_DIR)\archive_read_support_compression_all.obm \
$(OBJ_DIR)\archive_read_support_compression_bzip2.obm \
$(OBJ_DIR)\archive_read_support_compression_compress.obm \
$(OBJ_DIR)\archive_read_support_compression_gzip.obm \
$(OBJ_DIR)\archive_read_support_compression_none.obm \
$(OBJ_DIR)\archive_read_support_compression_program.obm \
$(OBJ_DIR)\archive_read_support_format_all.obm \
$(OBJ_DIR)\archive_read_support_format_ar.obm \
$(OBJ_DIR)\archive_read_support_format_cpio.obm \
$(OBJ_DIR)\archive_read_support_format_empty.obm \
$(OBJ_DIR)\archive_read_support_format_iso9660.obm \
$(OBJ_DIR)\archive_read_support_format_mtree.obm \
$(OBJ_DIR)\archive_read_support_format_tar.obm \
$(OBJ_DIR)\archive_read_support_format_zip.obm \
$(OBJ_DIR)\archive_string.obm $(OBJ_DIR)\archive_string_sprintf.obm \
$(OBJ_DIR)\archive_util.obm $(OBJ_DIR)\archive_virtual.obm \
$(OBJ_DIR)\archive_write.obm $(OBJ_DIR)\archive_write_disk.obm \
$(OBJ_DIR)\archive_write_disk_set_standard_lookup.obm \
$(OBJ_DIR)\archive_write_open_fd.obm $(OBJ_DIR)\archive_write_open_file.obm \
$(OBJ_DIR)\archive_write_open_filename.obm $(OBJ_DIR)\archive_write_open_memory.obm \
$(OBJ_DIR)\archive_write_set_compression_bzip2.obm $(OBJ_DIR)\archive_write_set_compression_compress.obm \
$(OBJ_DIR)\archive_write_set_compression_gzip.obm $(OBJ_DIR)\archive_write_set_compression_none.obm \
$(OBJ_DIR)\archive_write_set_compression_program.obm $(OBJ_DIR)\archive_write_set_format.obm \
$(OBJ_DIR)\archive_write_set_format_ar.obm $(OBJ_DIR)\archive_write_set_format_by_name.obm \
$(OBJ_DIR)\archive_write_set_format_cpio.obm $(OBJ_DIR)\archive_write_set_format_cpio_newc.obm \
$(OBJ_DIR)\archive_write_set_format_pax.obm $(OBJ_DIR)\archive_write_set_format_shar.obm \
$(OBJ_DIR)\archive_write_set_format_ustar.obm $(OBJ_DIR)\filter_fork.obm \
$(OBJ_DIR)\libarchive-nonposix.obm

all: CLEAN $(DEST_PATH)\libarchive.lib

$(DEST_PATH)\libarchive.lib :: $(OBJS) $(DEST_PATH)

$(DEST_PATH)\libarchive.lib ::
$(NT_LIBRARIAN) $(NT_LIB_OPTS) /OUT:$(DEST_PATH)\libarchive.lib $(OBJS)

$(DEST_PATH):
-md $(DEST_PATH) > nul 2>nul

CLEAN:
!ifdef CLEAN
-del $(OBJ_DIR)\*.pd? > nul 2>nul
-ren $(OBJ_DIR)\*.pdb *.pd1 > nul 2>nul
-ren $(OBJ_DIR)\*.pdb *.pd2 > nul 2>nul
!endif
107 changes: 107 additions & 0 deletions windows/wccpp.nt
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@
#/* FILE: wccpp.nt
# *
# * Copyright (c) 2008
# * TouchNet Information Systems, Inc.
# * All Rights Reserved
# *
# * This program is an unpublished copyright work of TouchNet Information
# * Systems, Inc. of Lenexa, KS. The program, all information disclosed
# * and the matter shown and described hereon or herewith are confidential
# * and proprietary to TouchNet Information Systems, Inc.
# *
# ******************************************************************************
# *
# * $LastChangedBy$
# * $Locker: $
# * $ProjectName: $
# * $ProjectRevision: $
# * $LastChangedRevision$
# * $LastChangedDate$
# * $State: $
# * $RCSfile: $
# * $Source: $
# *
# * Change Log:
# * $Log: $
# *
# */

.EXTENSIONS:
.EXTENSIONS: .obn .cpp .c

ZLIB_INCL=\3rdParty\ZLib\Current\Include

!ifdef DEBUG
DEST_PATH=.\lib\wccpp\debug
OBJ_DIR=obj\debug
EXT_COMPILE_FLAG=-d2 -DLIBARCHIVE_STATIC=1
!else
DEST_PATH=.\lib\wccpp
OBJ_DIR=obj
EXT_COMPILE_FLAG=-DLIBARCHIVE_STATIC=1
!endif

# ----- NT compiler options -----------------------------------------------
NT_CPP=wpp386
NT_C=wcc386
NT_LIBRARIAN=wlib


###
INCLUDE_OPTS=/I.;$(%watcom)\h;$(%watcom)\h\nt;$(ZLIB_INCL);
NT_CPP_OPTS=-ei -wx -xs -xss -xst -od -of+ -zp1 -5 -bt=nt -bm $(EXT_COMPILE_FLAG) $(INCLUDE_OPTS) -DWIN32_LEAN_AND_MEAN
NT_C_OPTS=-ei -wx -od -of+ -zp1 -5 -bt=nt -bm $(EXT_COMPILE_FLAG) $(INCLUDE_OPTS) -DWIN32_LEAN_AND_MEAN
NT_LIB_OPTS=

.cpp{$(OBJ_DIR)}.obn:
-md $(OBJ_DIR) > nul 2>nul
$(NT_CPP) $(NT_CPP_OPTS) -zp1 -fo=$*.obn $<

.c{$(OBJ_DIR)}.obn:
-md $(OBJ_DIR) > nul 2>nul
$(NT_C) $(NT_C_OPTS) -zp1 -fo=$*.obn $<

OBJS = &
$(OBJ_DIR)\archive_check_magic.obn $(OBJ_DIR)\archive_entry.obn &
$(OBJ_DIR)\archive_entry_copy_stat.obn $(OBJ_DIR)\archive_entry_link_resolver.obn &
$(OBJ_DIR)\archive_entry_stat.obn $(OBJ_DIR)\archive_entry_strmode.obn &
$(OBJ_DIR)\archive_read.obn $(OBJ_DIR)\archive_read_data_into_fd.obn &
$(OBJ_DIR)\archive_read_extract.obn $(OBJ_DIR)\archive_read_open_fd.obn &
$(OBJ_DIR)\archive_read_open_file.obn $(OBJ_DIR)\archive_read_open_filename.obn &
$(OBJ_DIR)\archive_read_open_memory.obn $(OBJ_DIR)\archive_read_support_compression_all.obn &
$(OBJ_DIR)\archive_read_support_compression_bzip2.obn &
$(OBJ_DIR)\archive_read_support_compression_compress.obn &
$(OBJ_DIR)\archive_read_support_compression_gzip.obn &
$(OBJ_DIR)\archive_read_support_compression_none.obn &
$(OBJ_DIR)\archive_read_support_compression_program.obn &
$(OBJ_DIR)\archive_read_support_format_all.obn &
$(OBJ_DIR)\archive_read_support_format_ar.obn &
$(OBJ_DIR)\archive_read_support_format_cpio.obn &
$(OBJ_DIR)\archive_read_support_format_empty.obn &
$(OBJ_DIR)\archive_read_support_format_iso9660.obn &
$(OBJ_DIR)\archive_read_support_format_mtree.obn &
$(OBJ_DIR)\archive_read_support_format_tar.obn &
$(OBJ_DIR)\archive_read_support_format_zip.obn &
$(OBJ_DIR)\archive_string.obn $(OBJ_DIR)\archive_string_sprintf.obn &
$(OBJ_DIR)\archive_util.obn $(OBJ_DIR)\archive_virtual.obn &
$(OBJ_DIR)\archive_write.obn $(OBJ_DIR)\archive_write_disk.obn &
$(OBJ_DIR)\archive_write_disk_set_standard_lookup.obn &
$(OBJ_DIR)\archive_write_open_fd.obn $(OBJ_DIR)\archive_write_open_file.obn &
$(OBJ_DIR)\archive_write_open_filename.obn $(OBJ_DIR)\archive_write_open_memory.obn &
$(OBJ_DIR)\archive_write_set_compression_bzip2.obn $(OBJ_DIR)\archive_write_set_compression_compress.obn &
$(OBJ_DIR)\archive_write_set_compression_gzip.obn $(OBJ_DIR)\archive_write_set_compression_none.obn &
$(OBJ_DIR)\archive_write_set_compression_program.obn $(OBJ_DIR)\archive_write_set_format.obn &
$(OBJ_DIR)\archive_write_set_format_ar.obn $(OBJ_DIR)\archive_write_set_format_by_name.obn &
$(OBJ_DIR)\archive_write_set_format_cpio.obn $(OBJ_DIR)\archive_write_set_format_cpio_newc.obn &
$(OBJ_DIR)\archive_write_set_format_pax.obn $(OBJ_DIR)\archive_write_set_format_shar.obn &
$(OBJ_DIR)\archive_write_set_format_ustar.obn $(OBJ_DIR)\filter_fork.obn &
$(OBJ_DIR)\libarchive-nonposix.obn

$(DEST_PATH)\LibArchive.lib :: $(OBJS) $(DEST_PATH)

$(DEST_PATH)\LibArchive.lib ::
-md $(DEST_PATH) > nul 2>nul
$(NT_LIBRARIAN) $@ -+ $(OBJS)

$(DEST_PATH):
-md $(DEST_PATH) > nul 2>nul

0 comments on commit e1ab3b3

Please sign in to comment.