Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
mongoose
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
esp
mongoose
Commits
53bedd1e
Commit
53bedd1e
authored
Aug 16, 2013
by
Sergey Lyubka
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
made separate targets for each example
parent
a0b43ae8
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
47 additions
and
19 deletions
+47
-19
Makefile
examples/Makefile
+47
-19
No files found.
examples/Makefile
View file @
53bedd1e
CFLAGS
=
-W
-Wall
-I
..
-pthread
-g
CFLAGS
=
-W
-Wall
-I
..
-pthread
-g
-pipe
$(COPT)
DLL_FLAGS
=
-DLUA_COMPAT_ALL
-I
../lua-5.2.1/src
all
:
ifeq
($(OS),Windows_NT)
OS
=
`
uname
`
;
\
else
test
"
$$
OS"
=
Linux
&&
LIBS
=
"-ldl"
;
\
UNAME_S
:=
$(
shell
uname
-s
)
$(CC)
$(CFLAGS)
hello.c ../mongoose.c
$$
LIBS
$(ADD)
-o
hello
;
DLL_FLAGS
+=
-shared
$(CC)
$(CFLAGS)
upload.c ../mongoose.c
$$
LIBS
$(ADD)
-o
upload
;
$(CC)
$(CFLAGS)
post.c ../mongoose.c
$$
LIBS
$(ADD)
-o
post
;
$(CC)
$(CFLAGS)
-DUSE_WEBSOCKET
websocket.c ../mongoose.c
$$
LIBS
$(ADD)
-o
websocket
;
$(CC)
$(CFLAGS)
chat.c ../mongoose.c
$$
LIBS
$(ADD)
-o
chat
ifeq
($(UNAME_S),Linux)
CFLAGS
+=
-ldl
endif
MSVC
=
e:/vc6
ifeq
($(UNAME_S),Darwin)
# DLL_FLAGS += -bundle -undefined dynamic_lookup -dynamiclib
DLL_FLAGS
+=
-flat_namespace
-undefined
suppress
-dynamiclib
endif
endif
all
:
hello upload post websocket chat lua_dll
hello
:
$(CC)
$(CFLAGS)
hello.c ../mongoose.c
-o
$@
upload
:
$(CC)
$(CFLAGS)
upload.c ../mongoose.c
-o
$@
post
:
$(CC)
$(CFLAGS)
post.c ../mongoose.c
-o
$@
websocket
:
$(CC)
$(CFLAGS)
-DUSE_WEBSOCKET
websocket.c ../mongoose.c
-o
$@
chat
:
$(CC)
$(CFLAGS)
chat.c ../mongoose.c
-o
$@
lua_dll
:
$(CC)
$(CFLAGS)
$(DLL_FLAGS)
lua_dll.c
-o
$@
.so
MSVC
=
../../vc6
CL
=
$(MSVC)
/bin/cl
CL
=
$(MSVC)
/bin/cl
CLFLAGS
=
/MD /TC /nologo
$(DBG)
/W3 /DNO_SSL
\
CLFLAGS
=
/MD /TC /nologo
$(DBG)
/W3 /DNO_SSL
\
/I
$(MSVC)
/include /I.. /Dsnprintf
=
_snprintf
\
/I
$(MSVC)
/include /I.. /Dsnprintf
=
_snprintf
/link /incremental:no /libpath:
$(MSVC)
/lib /machine:IX86
LFLAGS
=
/link /incremental:no /libpath:
$(MSVC)
/lib /machine:IX86
windows
:
windows
:
$(CL)
upload.c ../mongoose.c
$(CLFLAGS)
$(CL)
upload.c ../mongoose.c
$(CLFLAGS)
$(LFLAGS)
$(CL)
hello.c ../mongoose.c
$(CLFLAGS)
$(CL)
hello.c ../mongoose.c
$(CLFLAGS)
$(LFLAGS)
$(CL)
upload.c ../mongoose.c
$(CLFLAGS)
$(CL)
upload.c ../mongoose.c
$(CLFLAGS)
$(LFLAGS)
$(CL)
post.c ../mongoose.c
$(CLFLAGS)
$(CL)
post.c ../mongoose.c
$(CLFLAGS)
$(LFLAGS)
$(CL)
post.c ../mongoose.c
$(CLFLAGS)
$(CL)
post.c ../mongoose.c
$(CLFLAGS)
$(LFLAGS)
$(CL)
/DUSE_WEBSOCKET websocket.c ../mongoose.c
$(CLFLAGS)
$(CL)
/DUSE_WEBSOCKET websocket.c ../mongoose.c
$(CLFLAGS)
$(LFLAGS)
#$(CL) lua_dll.c $(CLFLAGS) $(DLL_FLAGS) /DLL $(LFLAGS) /SUBSYSTEM:WINDOWS /ENTRY:luaopen_lua_dll /EXPORT:luaopen_lua_dll /out:lua_dll.dll
clean
:
clean
:
rm
-rf
hello upload post websocket chat
*
.exe
*
.dSYM
*
.obj
rm
-rf
hello upload post websocket chat
*
.exe
*
.dSYM
*
.obj
.
*
o
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment