Commit Graph

7458 Commits

Author SHA1 Message Date
Corinna Vinschen 54155bc37b * dlfcn.cc (get_full_path_of_dll): Just return a bool value. Drop
local path_conv in favor of getting it as parameter.  Add local string
	buffer instead of getting it as parameter.
	(dlopen): Accommodate get_full_path_of_dll change.  Fetch WCHAR Windows
	path from path_conv variable and call LoadLibraryW.
2009-04-16 16:17:58 +00:00
Corinna Vinschen 03897d8dda * ntdll.h (STATUS_LOCK_NOT_GRANTED): Define.
* syscalls.cc (unlink_nt): Handle STATUS_LOCK_NOT_GRANTED same as
	STATUS_SHARING_VIOLATION.  Add lengthy comment to explain why.
2009-04-16 12:16:35 +00:00
Corinna Vinschen 8c3a79bb97 * cygpath.cc (do_pathconv): Only skip \\?\ prefix if it's really
given.  Do backslash to slash conversion for mixed paths after
	handling \\?\ prefix.
2009-04-15 10:00:40 +00:00
Corinna Vinschen ca027229d5 * path.cc (path_conv::get_wide_win32_path): Allow relative paths.
(cygwin_conv_path): In case of CCP_POSIX_TO_WIN_W, convert relative
	paths to absolute paths if the relative pathname length exceeds
	MAX_PATH.
2009-04-15 09:58:41 +00:00
Corinna Vinschen d370bb56c8 * libc/bsdlib.cc: Align copyright with upstream.
* libc/fnmatch.c: Ditto.
	* libc/fts.c: Ditto.
	* libc/inet_addr.c: Ditto.
	* libc/inet_network.c: Ditto.
	* libc/rcmd.cc: Ditto.
	* libc/rexec.cc: Ditto.
2009-04-15 08:20:47 +00:00
Christopher Faylor fcea4c1c3d * speclib: Really revert to using tempdir. 2009-04-14 15:10:28 +00:00
Christopher Faylor d295466636 * speclib: Revert to using tempdir. 2009-04-14 14:28:34 +00:00
Corinna Vinschen 51291d61e2 * localtime.cc (tzload): Implement setting __tzrule's offset member
using newlib's __gettzinfo () interface also when tzload returns
	successfully.
2009-04-14 12:08:07 +00:00
Dave Korn 03d59fb47d * include/stdint.h (intptr_t): Remove long from type.
(uintptr_t):  Likewise.
	(INTPTR_MIN):  Remove 'L' suffix.
	(INTPTR_MAX, UINTPTR_MAX):  Likewise.
2009-04-13 22:55:00 +00:00
Dave Korn 228f0b11fd * Makefile.in (dumper.exe): Add -lz to ALL_LDFLAGS. 2009-04-13 22:51:02 +00:00
Christopher Faylor 73bd57524a * speclib: Initial stab at cleaning up temp files. More work needed.
* mkimport: Ditto.
2009-04-12 05:11:08 +00:00
Christopher Faylor d129941aef * Makefile.in (clean): Clean globals.h.
(LIBCOS): Depend on globals.h.
2009-04-12 04:14:31 +00:00
Christopher Faylor edd090a270 * mkimport: New script to perform all operations necessary to create
libcygwin.a.
* rmsym: Delete.
* newsym: Delete.
* Makefile.in (toolopts): New variable which holds options relating to
binutils/gcc tools.
(speclib): Use toolopts.  Add symbols to avoid copying to special libraries.
(OBSOLETE_FUNCTIONS): Delete.
(NEW_FUNCTIONS): Change to represent an argument to new mkimport script.
(libcygwin.a): Use only new mkimport script to create libcygwin.a.  Only rely
on ${LIBCOS}.
(*/lib*.a): Simplify speclib dependencies.
(speclib): Accept toolchain options.  Convert every argument to absolute path.
Simplify parsing of nm output.  Accommodate new exclude option.
2009-04-12 03:19:52 +00:00
Chris Sutcliffe 370a1171d8 2009-04-11 Danny Smith <dannsymith@users.sourceforge.net>
* include/stdint.h (int_fast8_t): Specify as signed char.
        (INT8_C, UINT8_C, INT16_C, UINT16_C): Simplify: just allow promotion to int.
        (INT32_C, UINT32_C): Remove 'L' type specifier on constant.
2009-04-11 12:41:09 +00:00
Corinna Vinschen 1b98373a40 * include/stdint.h (INTPTR_MIN, INTPTR_MAX): Add 'L' suffix.
(WINT_MAX):  Add 'U' suffix.
2009-04-11 08:07:30 +00:00
Christopher Faylor 1318037e44 * speclib: Use a more robust method to derive full file path. 2009-04-10 04:29:25 +00:00
Christopher Faylor 59328e28c4 * speclib: Semi-revert to previous version but don't try to generate
well-formed import library.  Instead, just extract appropriate symbols and let
later libcygwin.a on link line fill in the rest of the import stuff.
* gendef: Hopefully no-op modification to allow easier post-processing on
symbol values.
2009-04-09 21:02:53 +00:00
Corinna Vinschen 0c4023011d * syscalls.cc (try_to_bin): Use tmp_pathbuf buffer to allocate infobuf
rather than using the stack.
2009-04-09 17:55:01 +00:00
Corinna Vinschen 214a0e67fd * syscalls.cc (try_to_bin): Fix alignment of infobuf. 2009-04-09 17:00:35 +00:00
Corinna Vinschen 2d647173bb * fhandler_disk_file.cc (fhandler_disk_file::fchown): Catch an
error when changing the user account on a standalone Samba server.
	Explain why.
	* sec_acl.cc (setacl): Accommodate additional parameter to set_file_sd.
	* sec_helper.cc (SECURITY_SAMBA_UNIX_AUTHORITY): Define.
	(well_known_samba_unix_user_fake_sid): Define.
	* security.cc (set_file_sd): Take additional parameter if ownership
	should be changed.  Restrict requested permissions accordingly.
	(set_file_attribute): Accommodate additional parameter to set_file_sd.
	* security.h (well_known_samba_unix_user_fake_sid): Declare.
	(set_file_sd): Align declaration to above change.
2009-04-09 09:19:03 +00:00
Corinna Vinschen 8dc102b20b * include/stdint.h (int_least32_t): Define as int.
(uint_least32_t): Ditto, unsigned.
	(int_fast16_t): Define as int.
	(int_fast32_t): Ditto.
	(uint_fast16_t): Ditto, unsigned.
	(uint_fast32_t): Ditto.
	(UINT32_MAX): Remove `L' long marker.
	(UINT_LEAST32_MAX): Ditto.
	(UINT_FAST16_MAX): Ditto.
	(UINT_FAST32_MAX): Ditto.
	(INT32_C): Ditto.
	(UINT32_C): Ditto.
2009-04-07 17:23:20 +00:00
Corinna Vinschen 18ac7638b9 * path.cc (readlink): Accommodate new UTF-16 symlinks. 2009-04-07 16:24:50 +00:00
Corinna Vinschen 21c7d001dc * strfuncs.cc: Change WCHAR to wchar_t in multibyte<->widechar
conversion functions throughout.
	* wchar.h: Ditto in declarations.  Guard them __INSIDE_CYGWIN__.
2009-04-07 16:22:55 +00:00
Corinna Vinschen 3d69426491 * setup2.sgml (setup-locale-console): New section to explain
console character set setting.
	* faq: Throughout, change references to User's Guide to references
	to 1.7 User's Guide temporarily.
	* faq-setup.html (faq.using.unicode): Rephrase slightly.
	(faq.using.weirdchars): New FAQ entry for console charset problems.
2009-04-07 13:04:43 +00:00
Corinna Vinschen 62755474e5 * fhandler.h (class dev_console): Add members con_mbtowc, con_wctomb,
and con_charset.
	(dev_console::str_to_con): Take mbtowc function pointer and charset
	as additional parameters.
	* fhandler_console.cc (fhandler_console::get_tty_stuff): Initialize
	aforementioned new members.  Explain why.
	(dev_console::con_to_str): Remove useless comment.  Call new
	sys_cp_wcstombs function rather than sys_wcstombs.
	(dev_console::str_to_con): Take mbtowc function pointer and charset
	as additional parameters.  Call sys_cp_mbstowcs accordingly.
	(fhandler_console::write_normal): Only initialize f_mbtowc and charset
	once.  Accommodate changed str_to_con.
	* strfuncs.cc (sys_cp_wcstombs): Renamed from sys_wcstombs.  Take
	wctomb function pointer and charset as parameters.  Use throughout.
	(sys_cp_mbstowcs): Take wctomb function pointer and charset as
	parameters instead of codepage.  Remove matching local variables and
	their initialization.
	* wchar.h (ENCODING_LEN): Define as in newlib.
	(__mbtowc): Use mbtowc_p typedef for declaration.
	(wctomb_f): New type.
	(wctomb_p): New type.
	(__wctomb): Declare.
	(__utf8_wctomb): Use wctomb_f typedef for declaration.
	(sys_cp_wcstombs): Move declaration from winsup.h here.
	(sys_wcstombs): Ditto.
	(sys_wcstombs_alloc): Ditto.
	(sys_cp_mbstowcs): Ditto.
	(sys_mbstowcs): Ditto.
	(sys_mbstowcs_alloc): Ditto.
	* winsup.h: Move declaration of sys_FOO functions to wchar.h.  Include
	wchar.h instead.
2009-04-07 12:13:37 +00:00
Corinna Vinschen 6af3d60df9 * libc/rexec.cc (ruserpass): Use fstat64 instead of fstat. 2009-04-06 20:44:55 +00:00
Corinna Vinschen 2f9ee8fc90 * strfuncs.cc: Add comment to explain why we can't support JIS
for now.
	(__db_wctomb): Alwaus use WC_NO_BEST_FIT_CHARS.
	(__jis_wctomb): Just call __ascii_wctomb from here.
	(__eucjp_wctomb): Convert to standalone implementation to fix up the
	difference between eucJP and CP 20932 affecting JIS-X-0212 characters.
	Explain.
	(__kr_wctomb): Use codepage 949.
	(__db_mbtowc): Reorder code slightly.  Always use MB_ERR_INVALID_CHARS
	in call to MultiByteToWideChar.  Fix a problem with singlebyte
	sequences.  Fix a bug in '\0' handling.  Reset state->__count on
	successful return from non-zero state.
	(__jis_mbtowc): Just call __ascii_mbtowc from here.
	(__eucjp_mbtowc): Convert to standalone implementation to fix up the
	difference between eucJP and CP 20932 affecting JIS-X-0212 characters.
	(__kr_mbtowc): Use codepage 949.
	(__set_charset_from_codepage): Handle codepage 20932 as eucJP.
2009-04-06 10:50:11 +00:00
Corinna Vinschen 115655f1f3 * new-features.sgml (ov-new1.7-posix): Remove JIS from supported
charsets.
	* setup2.sgml (setup-locale-charsetlist): Ditto.
2009-04-06 10:30:02 +00:00
Corinna Vinschen 738c26083a * setup2.sgml (setup-locale-problems): Change title to be more clear
when referencing this section.
2009-04-06 10:25:28 +00:00
Christopher Faylor 50b2715c77 * Makefile.in: Use all compile options when calculating magic values.
* shared_info.h (CURR_SHARED_MAGIC): Revert erroneous value.
* child_info.h (CURR_CHILD_INFO_MAGIC): Update.
* fhandler.h (acquire_output_mutex): Remove unneeded ';'.
(release_output_mutex): Ditto.
2009-04-05 16:49:15 +00:00
Christopher Faylor 66eaf280ac * net.cc: Undefine NOERROR and DELETE to avoid compiler warnings.
* shared_info.h (CURR_SHARED_MAGIC): Update.
* spawn.cc (spawn_guts): Avoid copying one line command line argument if it
hasn't been filled out.
2009-04-05 04:23:50 +00:00
Corinna Vinschen 4fedce119c * include/asm/byteorder.h (__ntohl): Prototype before define to avoid
a warning with -Wmissing-prototypes.  Use _ELIDABLE_INLINE macro from
	_ansi.h.
	(__ntohs): Ditto.
2009-04-04 15:49:05 +00:00
Corinna Vinschen f5e097fa4b * Various syntactical and semantical fixes throughout. 2009-04-03 11:51:31 +00:00
Corinna Vinschen d10a1e5154 * utils.sgml: Various syntactical and semantical fixes.
* cygcheck.cc (usage): Fix --find-package explanation.
2009-04-03 11:50:26 +00:00
Corinna Vinschen eab96f6b22 * environ.cc (build_env): Fix length calculation of resulting
wide char environment string.
2009-04-02 17:44:01 +00:00
Corinna Vinschen be37a55086 * include/netdb.h: #include <inttypes.h>, <netinet/in.h>,
and <sys/socket.h> per SUSv3.
2009-04-02 08:48:03 +00:00
Corinna Vinschen cf7fdc0672 * faq-using.xml (faq.using.symlinkstoppedworking): Rename.
(faq.using.ipv6): New IPv6 FAQ.
	* gdb.sgml: Remove incorrect statement about Insight.
2009-04-01 16:56:08 +00:00
Corinna Vinschen b4bf8c7064 * strfuncs.cc (sys_cp_mbstowcs): Check if ASCII SO is followed by at
least two chars and the next byte is a valid UTF-8 start byte before
	trying to convert the followup bytes as UTF-8 sequence.
2009-04-01 09:49:25 +00:00
Corinna Vinschen 1e4e6ee8f4 * shm.cc (struct shm_attached_list): Convert access type to ULONG.
(fixup_shms_after_fork): Fix comment.  Use NtMapViewOfSection rather
	than MapViewOfFileEx to recreate shared memory regions.  Add function
	name to api_fatal output.
	(shmat): Use NtMapViewOfSection to create shared memory region
	top-down.
2009-03-31 14:58:14 +00:00
Corinna Vinschen 83fb2c849c * setup2.sgml (setup-locale-problems): Fix an incomplete sentence. 2009-03-31 11:17:08 +00:00
Corinna Vinschen 7ccfe2c70e * faq-using.xml (faq.using.unicode): Modernize.
(faq.api.symlinkstoppedworking): Move here from faq-api.xml.
2009-03-31 10:54:28 +00:00
Corinna Vinschen a33fa76fed * ctype.cc: Remove implementation of ctype functions in favor of
pointer-based newlib implementation.
	(_ctype_b): Declare.
	(__ctype_cp): Move to newlib. Declare.
	(__ctype_iso): Ditto.
	(__set_ctype): Implement changing __ctype_ptr__.  Only copy character
	class data in applications built under older Cygwin.
	* cygwin.din (__ctype_ptr__): Export.
	* include/ctype.h: Remove in favor of newlib implementation.
	* include/cygwin/config.h (__EXPORT): Define alongside __IMPORT.
	* include/cygwin/version.h (CYGWIN_VERSION_CHECK_FOR_OLD_CTYPE):
	Define check for old vs. new ctype implementation.
	Bump API minor number.
2009-03-31 09:42:58 +00:00
Dave Korn 24bd1f86c2 * faq-using.xml (faq.using.bloda): Update with new entries. 2009-03-30 09:23:13 +00:00
Christopher Faylor 0390592140 * Makefile.in: Perform some minor cleanup. Revamp speclib handling.
* speclib: Rewrite to create libraries with dlltool rather than attempting
surgery on libcygwin.a.
2009-03-28 04:55:36 +00:00
Corinna Vinschen 6f0c3cc88a * net.cc (inet_ntop6): Convert to lowercase hex digits on the fly. 2009-03-27 15:20:27 +00:00
Corinna Vinschen e5d5e036fd * net.cc (cygwin_getaddrinfo): Check hints for non-NULL before
checking its content.
2009-03-27 15:10:18 +00:00
Corinna Vinschen 52e26dc2ab * fhandler.h (class fhandler_fifo): Rename read/write methods to
raw_read/raw_write.
	* fhandler_fifo.cc: Ditto.
2009-03-27 15:04:42 +00:00
Corinna Vinschen 7a9f309bcd * syscalls.cc (pathconf): Fix memory leak. 2009-03-27 11:29:56 +00:00
Corinna Vinschen d6e045e614 * README: Remove "How to use" section, as CYGWIN="server" is
no longer required.
2009-03-27 10:17:48 +00:00
Corinna Vinschen 12ddd5e5b7 * utils.sgml (passwd -R): Remove references to CYGWIN="server". 2009-03-27 10:16:13 +00:00