mirror of
https://github.com/obarthel/amiga-smbfs.git
synced 2025-12-08 14:58:35 +00:00
107 lines
3.9 KiB
Plaintext
107 lines
3.9 KiB
Plaintext
#
|
|
# :ts=4
|
|
#
|
|
# SMB file system wrapper for AmigaOS, using the AmiTCP V3 API
|
|
#
|
|
# Copyright (C) 2000-2019 by Olaf 'Olsen' Barthel <obarthel -at- gmx -dot- net>
|
|
#
|
|
# This program is free software; you can redistribute it and/or modify
|
|
# it under the terms of the GNU General Public License as published by
|
|
# the Free Software Foundation; either version 2 of the License, or
|
|
# (at your option) any later version.
|
|
#
|
|
# This program is distributed in the hope that it will be useful,
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
# GNU General Public License for more details.
|
|
#
|
|
# You should have received a copy of the GNU General Public License
|
|
# along with this program; if not, write to the Free Software
|
|
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
|
#
|
|
|
|
.c.o:
|
|
@echo "Compiling $<"
|
|
@$(CC) -c $(CFLAGS) -o $*.o $<
|
|
|
|
###########################################################################
|
|
|
|
PROJECT = smbfs
|
|
|
|
###########################################################################
|
|
|
|
CC = ppc-amigaos-gcc
|
|
|
|
###########################################################################
|
|
|
|
WARNINGS = \
|
|
-Wall -W -Wshadow -Wpointer-arith -Wsign-compare -Wmissing-prototypes \
|
|
-Wundef -Wbad-function-cast -Wmissing-declarations
|
|
|
|
OPTIMIZE = -O3
|
|
DEBUG = -ggdb
|
|
|
|
###########################################################################
|
|
|
|
# For the standard version without any debugging support whatsoever,
|
|
# use the following debug option.
|
|
DEBUG_OPTIONS = -DNDEBUG
|
|
|
|
# This enables full debugging support, which will significantly
|
|
# increase the size of the program and also make it run slower.
|
|
#DEBUG_OPTIONS = -DDEBUG=1 -DDUMP_SMB=1
|
|
|
|
###########################################################################
|
|
|
|
# This is useful only for cross-compilation. Do not set this variable
|
|
# if you build smbfs natively under AmigaOS4.
|
|
#INCLUDE_CROSS_COMPILE=-I/V/include -I/usr/local/amiga/ppc-amigaos/sys-include
|
|
|
|
###########################################################################
|
|
|
|
CFLAGS = -mcrt=clib2 -D__NO_NET_API $(WARNINGS) $(OPTIMIZE) $(DEBUG) \
|
|
$(DEBUG_OPTIONS) -I. $(INCLUDE_CROSS_COMPILE) -Iinclude -Inetinclude
|
|
LFLAGS = -nostartfiles -nostdlib -L.
|
|
|
|
###########################################################################
|
|
|
|
OBJS = \
|
|
main.o assert.o cp437.o cp850.o crypt.o dump_smb.o parse-smb-url.o \
|
|
proc.o quad_math.o smb_abstraction.o sock.o splay.o kvs.o
|
|
|
|
###########################################################################
|
|
|
|
LIBS = -lc -ldebug
|
|
|
|
###########################################################################
|
|
|
|
all: $(PROJECT)
|
|
|
|
$(PROJECT): $(OBJS)
|
|
@echo "Linking $@"
|
|
@$(CC) -o $@.debug $(CFLAGS) $(LFLAGS) $(OBJS) $(LIBS) -Wl,--cref,-M,-Map=$@.map
|
|
ppc-amigaos-strip -R.comment -o $@ $@.debug
|
|
|
|
exall-example: exall-example.c
|
|
$(CC) -o $@ -D__USE_INLINE__ exall-example.c
|
|
|
|
###########################################################################
|
|
|
|
assert.o : assert.c
|
|
cp437.o : cp437.c
|
|
cp850.o : cp850.c
|
|
crypt.o : crypt.c system_headers.h assert.h quad_math.h splay.h smbfs.h
|
|
dump_smb.o : dump_smb.c system_headers.h assert.h quad_math.h splay.h smbfs.h dump_smb.h
|
|
main.o : main.c system_headers.h assert.h quad_math.h splay.h smbfs.h smb_abstraction.h cp437.h cp850.h errors.h dump_smb.h parse-smb-url.h smbfs_rev.h
|
|
parse-smb-url.o : parse-smb-url.c system_headers.h assert.h quad_math.h splay.h smbfs.h parse-smb-url.h
|
|
proc.o : proc.c system_headers.h assert.h quad_math.h splay.h smbfs.h errors.h smbfs_rev.h
|
|
quad_math.o : quad_math.c quad_math.h
|
|
smb_abstraction.o : smb_abstraction.c system_headers.h assert.h quad_math.h splay.h smbfs.h errors.h smb_abstraction.h
|
|
sock.o : sock.c system_headers.h assert.h quad_math.h splay.h smbfs.h smb_abstraction.h dump_smb.h errors.h
|
|
splay.o : splay.c system_headers.h assert.h quad_math.h splay.h smbfs.h
|
|
|
|
###########################################################################
|
|
|
|
clean:
|
|
-rm *.o $(PROJECT) $(PROJECT).debug $(PROJECT).map exall-example
|