Permalink
Browse files

Build with gyp

  • Loading branch information...
1 parent 52e1a9e commit a30a7336f0ed8bb0c0bfeb1e401dcb3903c8efab @ry ry committed Aug 3, 2011
Showing with 313 additions and 1,100 deletions.
  1. +2 −34 .gitignore
  2. +16 −111 Makefile
  3. +16 −3 README
  4. +222 −0 build/all.gyp
  5. +42 −0 build/gyp_uv
  6. +0 −67 config-mingw.mk
  7. +0 −121 config-unix.mk
  8. +14 −0 create-msvs-files.bat
  9. +1 −1 include/uv-win.h
  10. +0 −189 msvs/c-ares.vcxproj
  11. +0 −171 msvs/libuv-benchmark.vcxproj
  12. +0 −187 msvs/libuv-test.vcxproj
  13. +0 −56 msvs/libuv.sln
  14. +0 −160 msvs/libuv.vcxproj
View
@@ -7,37 +7,5 @@
*.orig
*.sdf
*.suo
-*.vcxproj.filters
-*.vcxproj.user
-ev/.deps/
-ev/.libs/
-ev/Makefile
-ev/config.h
-ev/config.log
-ev/config.status
-ev/libtool
-ev/stamp-h1
-ev/autom4te.cache
-/msvs/ipch/
-/build/
-test/run-tests
-test/run-benchmarks
-test/run-tests.exe
-test/run-benchmarks.exe
-test/run-benchmarks.dSYM/
-test/run-tests.dSYM/
-
-
-c-ares/.deps/
-c-ares/.libs/
-c-ares/Makefile
-c-ares/acountry
-c-ares/adig
-c-ares/ahost
-c-ares/ares_config.h
-c-ares/config.log
-c-ares/config.status
-c-ares/libcares.pc
-c-ares/libtool
-c-ares/stamp-h1
-c-ares/stamp-h2
+/out/
+/build/gyp
View
127 Makefile
@@ -1,119 +1,24 @@
-# Copyright Joyent, Inc. and other Node contributors. All rights reserved.
-#
-# 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.
+BUILDTYPE ?= Release
-uname_S := $(shell sh -c 'uname -s 2>/dev/null || echo not')
+all: out/Makefile
+ $(MAKE) -C out BUILDTYPE=$(BUILDTYPE)
-ifdef MSVC
-uname_S := MINGW
-endif
+out/Makefile: build/gyp
+ build/gyp_uv -f make
-CPPFLAGS += -Iinclude
+build/gyp:
+ svn co http://gyp.googlecode.com/svn/trunk@983 build/gyp
-CARES_OBJS =
-CARES_OBJS += src/ares/ares__close_sockets.o
-CARES_OBJS += src/ares/ares__get_hostent.o
-CARES_OBJS += src/ares/ares__read_line.o
-CARES_OBJS += src/ares/ares__timeval.o
-CARES_OBJS += src/ares/ares_cancel.o
-CARES_OBJS += src/ares/ares_data.o
-CARES_OBJS += src/ares/ares_destroy.o
-CARES_OBJS += src/ares/ares_expand_name.o
-CARES_OBJS += src/ares/ares_expand_string.o
-CARES_OBJS += src/ares/ares_fds.o
-CARES_OBJS += src/ares/ares_free_hostent.o
-CARES_OBJS += src/ares/ares_free_string.o
-CARES_OBJS += src/ares/ares_gethostbyaddr.o
-CARES_OBJS += src/ares/ares_gethostbyname.o
-CARES_OBJS += src/ares/ares_getnameinfo.o
-CARES_OBJS += src/ares/ares_getopt.o
-CARES_OBJS += src/ares/ares_getsock.o
-CARES_OBJS += src/ares/ares_init.o
-CARES_OBJS += src/ares/ares_library_init.o
-CARES_OBJS += src/ares/ares_llist.o
-CARES_OBJS += src/ares/ares_mkquery.o
-CARES_OBJS += src/ares/ares_nowarn.o
-CARES_OBJS += src/ares/ares_options.o
-CARES_OBJS += src/ares/ares_parse_a_reply.o
-CARES_OBJS += src/ares/ares_parse_aaaa_reply.o
-CARES_OBJS += src/ares/ares_parse_mx_reply.o
-CARES_OBJS += src/ares/ares_parse_ns_reply.o
-CARES_OBJS += src/ares/ares_parse_ptr_reply.o
-CARES_OBJS += src/ares/ares_parse_srv_reply.o
-CARES_OBJS += src/ares/ares_parse_txt_reply.o
-CARES_OBJS += src/ares/ares_process.o
-CARES_OBJS += src/ares/ares_query.o
-CARES_OBJS += src/ares/ares_search.o
-CARES_OBJS += src/ares/ares_send.o
-CARES_OBJS += src/ares/ares_strcasecmp.o
-CARES_OBJS += src/ares/ares_strdup.o
-CARES_OBJS += src/ares/ares_strerror.o
-CARES_OBJS += src/ares/ares_timeout.o
-CARES_OBJS += src/ares/ares_version.o
-CARES_OBJS += src/ares/ares_writev.o
-CARES_OBJS += src/ares/bitncmp.o
-CARES_OBJS += src/ares/inet_net_pton.o
-CARES_OBJS += src/ares/inet_ntop.o
+clean:
+ rm -rf out
-ifneq (,$(findstring MINGW,$(uname_S)))
-include config-mingw.mk
-else
-include config-unix.mk
-endif
+distclean:
+ rm -rf out
-TESTS=test/echo-server.c test/test-*.c
-BENCHMARKS=test/echo-server.c test/dns-server.c test/benchmark-*.c
+test: all
+ ./out/$(BUILDTYPE)/run-tests
-all: uv.a test/run-tests test/run-benchmarks
+bench: all
+ ./out/$(BUILDTYPE)/run-benchmarks
-$(CARES_OBJS): %.o: %.c
- $(CC) -o $*.o -c $(CFLAGS) $(CPPFLAGS) $< -DHAVE_CONFIG_H
-
-test/run-tests$(E): test/*.h test/run-tests.c $(RUNNER_SRC) test/runner-unix.c $(TESTS) uv.a
- $(CC) $(CPPFLAGS) $(RUNNER_CFLAGS) $(RUNNER_LINKFLAGS) -o test/run-tests test/run-tests.c \
- test/runner.c $(RUNNER_SRC) $(TESTS) uv.a $(RUNNER_LIBS)
-
-test/run-benchmarks$(E): test/*.h test/run-benchmarks.c test/runner.c $(RUNNER_SRC) $(BENCHMARKS) uv.a
- $(CC) $(CPPFLAGS) $(RUNNER_CFLAGS) $(RUNNER_LINKFLAGS) -o test/run-benchmarks test/run-benchmarks.c \
- test/runner.c $(RUNNER_SRC) $(BENCHMARKS) uv.a $(RUNNER_LIBS)
-
-test/echo.o: test/echo.c test/echo.h
- $(CC) $(CPPFLAGS) $(CFLAGS) -c test/echo.c -o test/echo.o
-
-
-.PHONY: clean clean-platform distclean distclean-platform test bench
-
-
-test: test/run-tests$(E)
- test/run-tests
-
-#test-%: test/run-tests$(E)
-# test/run-tests $(@:test-%=%)
-
-bench: test/run-benchmarks$(E)
- test/run-benchmarks
-
-#bench-%: test/run-benchmarks$(E)
-# test/run-benchmarks $(@:bench-%=%)
-
-clean: clean-platform
- $(RM) -f src/*.o *.a test/run-tests$(E) test/run-benchmarks$(E)
-
-distclean: distclean-platform
- $(RM) -f src/*.o *.a test/run-tests$(E) test/run-benchmarks$(E)
+.PHONY: all clean distclean test bench
View
19 README
@@ -4,12 +4,25 @@ all platform differences in this library.
http://nodejs.org/
-(This was previously called liboio)
+= Build Instructions
-Supported Platforms:
+The build system requires python and subversion.
+
+On Unix systems just type
+
+ make
+
+On Windows you can generate the MSVS solution files by running
+
+ create-msvs-files.bat
+
+Open build/all.sln afterwards.
+
+
+= Supported Platforms
Microsoft Windows operating systems since Windows XP sp2. It can be built
-with either Visual Studio or MinGW.
+with either Visual Studio.
Linux 2.6 and MacOS using the GCC toolchain.
Oops, something went wrong.

1 comment on commit a30a733

Contributor

ry commented on a30a733 Aug 6, 2011

I'm throwing this out here. If this fucks up your process feel free to revert.

Please sign in to comment.