Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
cbf94a7b
Commit
cbf94a7b
authored
Oct 14, 2021
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
configure: Add a __WINE_PE_BUILD define for files that are built as PE.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
c53736d1
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
27 additions
and
31 deletions
+27
-31
configure
configure
+6
-5
configure.ac
configure.ac
+5
-7
crt_dllmain.c
dlls/winecrt0/crt_dllmain.c
+1
-1
crt_fltused.c
dlls/winecrt0/crt_fltused.c
+1
-1
debug.c
dlls/winecrt0/debug.c
+2
-2
delay_load.c
dlls/winecrt0/delay_load.c
+3
-3
unix_lib.c
dlls/winecrt0/unix_lib.c
+2
-2
config.h.in
include/config.h.in
+0
-3
asm.h
include/wine/asm.h
+7
-7
No files found.
configure
View file @
cbf94a7b
...
@@ -630,7 +630,6 @@ LDAP_CFLAGS
...
@@ -630,7 +630,6 @@ LDAP_CFLAGS
RT_LIBS
RT_LIBS
TOOLSEXT
TOOLSEXT
MSVCRTFLAGS
MSVCRTFLAGS
EXTRACFLAGS
VKD3D_SHADER_LIBS
VKD3D_SHADER_LIBS
VKD3D_SHADER_CFLAGS
VKD3D_SHADER_CFLAGS
VKD3D_LIBS
VKD3D_LIBS
...
@@ -751,6 +750,7 @@ TOP_INSTALL_DEV
...
@@ -751,6 +750,7 @@ TOP_INSTALL_DEV
TOP_INSTALL_LIB
TOP_INSTALL_LIB
UNIXLDFLAGS
UNIXLDFLAGS
UNIXDLLFLAGS
UNIXDLLFLAGS
EXTRACFLAGS
LDEXECFLAGS
LDEXECFLAGS
LDDLLFLAGS
LDDLLFLAGS
DLLFLAGS
DLLFLAGS
...
@@ -7935,6 +7935,8 @@ LDDLLFLAGS=""
...
@@ -7935,6 +7935,8 @@ LDDLLFLAGS=""
LDEXECFLAGS
=
""
LDEXECFLAGS
=
""
EXTRACFLAGS
=
""
UNIXDLLFLAGS
=
"-fPIC"
UNIXDLLFLAGS
=
"-fPIC"
UNIXLDFLAGS
=
"-shared -Wl,-Bsymbolic -Wl,-soname,
\$
(UNIXLIB)"
UNIXLDFLAGS
=
"-shared -Wl,-Bsymbolic -Wl,-soname,
\$
(UNIXLIB)"
...
@@ -8311,6 +8313,7 @@ else
...
@@ -8311,6 +8313,7 @@ else
fi
fi
LIBEXT
=
"dll"
LIBEXT
=
"dll"
EXTRACFLAGS
=
"-D__WINE_PE_BUILD"
case
$host_cpu
in
case
$host_cpu
in
*
i[3456]86
*
)
{
$as_echo
"
$as_me
:
${
as_lineno
-
$LINENO
}
: checking whether the compiler supports -Wl,--disable-stdcall-fixup"
>
&5
*
i[3456]86
*
)
{
$as_echo
"
$as_me
:
${
as_lineno
-
$LINENO
}
: checking whether the compiler supports -Wl,--disable-stdcall-fixup"
>
&5
$as_echo_n
"checking whether the compiler supports -Wl,--disable-stdcall-fixup... "
>
&6
;
}
$as_echo_n
"checking whether the compiler supports -Wl,--disable-stdcall-fixup... "
>
&6
;
}
...
@@ -9628,7 +9631,7 @@ test -n "$CROSSCC" || CROSSCC="false"
...
@@ -9628,7 +9631,7 @@ test -n "$CROSSCC" || CROSSCC="false"
saved_LDFLAGS
=
$LDFLAGS
saved_LDFLAGS
=
$LDFLAGS
CROSSCFLAGS
=
${
CROSSCFLAGS
:-
"-g -O2"
}
CROSSCFLAGS
=
${
CROSSCFLAGS
:-
"-g -O2"
}
EXTRACROSSCFLAGS
=
"-D
WINE_CROSS_PE
-Wall"
EXTRACROSSCFLAGS
=
"-D
__WINE_PE_BUILD
-Wall"
...
@@ -16871,11 +16874,9 @@ fi
...
@@ -16871,11 +16874,9 @@ fi
test
"x
$ac_cv_lib_soname_vkd3d
"
!=
"x"
||
enable_d3d12
=
${
enable_d3d12
:-
no
}
test
"x
$ac_cv_lib_soname_vkd3d
"
!=
"x"
||
enable_d3d12
=
${
enable_d3d12
:-
no
}
EXTRACFLAGS
=
""
if
test
"x
${
GCC
}
"
=
"xyes"
if
test
"x
${
GCC
}
"
=
"xyes"
then
then
EXTRACFLAGS
=
"-Wall -pipe"
EXTRACFLAGS
=
"
$EXTRACFLAGS
-Wall -pipe"
saved_CFLAGS
=
$CFLAGS
saved_CFLAGS
=
$CFLAGS
{
$as_echo
"
$as_me
:
${
as_lineno
-
$LINENO
}
: checking whether the compiler supports -Werror=unknown-warning-option"
>
&5
{
$as_echo
"
$as_me
:
${
as_lineno
-
$LINENO
}
: checking whether the compiler supports -Werror=unknown-warning-option"
>
&5
...
...
configure.ac
View file @
cbf94a7b
...
@@ -696,6 +696,7 @@ dnl **** Check for working dll ****
...
@@ -696,6 +696,7 @@ dnl **** Check for working dll ****
AC_SUBST(DLLFLAGS,"")
AC_SUBST(DLLFLAGS,"")
AC_SUBST(LDDLLFLAGS,"")
AC_SUBST(LDDLLFLAGS,"")
AC_SUBST(LDEXECFLAGS,"")
AC_SUBST(LDEXECFLAGS,"")
AC_SUBST(EXTRACFLAGS,"")
AC_SUBST(UNIXDLLFLAGS,"-fPIC")
AC_SUBST(UNIXDLLFLAGS,"-fPIC")
AC_SUBST(UNIXLDFLAGS,["-shared -Wl,-Bsymbolic -Wl,-soname,\$(UNIXLIB)"])
AC_SUBST(UNIXLDFLAGS,["-shared -Wl,-Bsymbolic -Wl,-soname,\$(UNIXLIB)"])
AC_SUBST(TOP_INSTALL_LIB,"")
AC_SUBST(TOP_INSTALL_LIB,"")
...
@@ -715,6 +716,7 @@ case $host_os in
...
@@ -715,6 +716,7 @@ case $host_os in
cygwin*|mingw32*)
cygwin*|mingw32*)
AC_CHECK_TOOL(DLLTOOL,dlltool,false)
AC_CHECK_TOOL(DLLTOOL,dlltool,false)
LIBEXT="dll"
LIBEXT="dll"
EXTRACFLAGS="-D__WINE_PE_BUILD"
dnl Disable stdcall fixups to catch prototype mismatches
dnl Disable stdcall fixups to catch prototype mismatches
case $host_cpu in
case $host_cpu in
*i[[3456]]86*) WINE_TRY_CFLAGS([-Wl,--disable-stdcall-fixup],
*i[[3456]]86*) WINE_TRY_CFLAGS([-Wl,--disable-stdcall-fixup],
...
@@ -953,7 +955,7 @@ then
...
@@ -953,7 +955,7 @@ then
saved_CFLAGS=$CFLAGS
saved_CFLAGS=$CFLAGS
saved_LDFLAGS=$LDFLAGS
saved_LDFLAGS=$LDFLAGS
AC_SUBST(CROSSCFLAGS,${CROSSCFLAGS:-"-g -O2"})
AC_SUBST(CROSSCFLAGS,${CROSSCFLAGS:-"-g -O2"})
AC_SUBST(EXTRACROSSCFLAGS,"-D
WINE_CROSS_PE
-Wall")
AC_SUBST(EXTRACROSSCFLAGS,"-D
__WINE_PE_BUILD
-Wall")
AC_SUBST(CROSSLDFLAGS)
AC_SUBST(CROSSLDFLAGS)
CC="$CROSSCC"
CC="$CROSSCC"
...
@@ -1955,10 +1957,9 @@ test "x$ac_cv_lib_soname_vkd3d" != "x" || enable_d3d12=${enable_d3d12:-no}
...
@@ -1955,10 +1957,9 @@ test "x$ac_cv_lib_soname_vkd3d" != "x" || enable_d3d12=${enable_d3d12:-no}
dnl **** Check for gcc specific options ****
dnl **** Check for gcc specific options ****
AC_SUBST(EXTRACFLAGS,"")
if test "x${GCC}" = "xyes"
if test "x${GCC}" = "xyes"
then
then
EXTRACFLAGS="-Wall -pipe"
EXTRACFLAGS="
$EXTRACFLAGS
-Wall -pipe"
dnl Check for some compiler flags
dnl Check for some compiler flags
dnl clang needs to be told to fail on unknown options
dnl clang needs to be told to fail on unknown options
...
@@ -2584,10 +2585,7 @@ esac
...
@@ -2584,10 +2585,7 @@ esac
dnl **** Generate output files ****
dnl **** Generate output files ****
AH_TOP([#ifndef __WINE_CONFIG_H
AH_TOP([#ifndef __WINE_CONFIG_H
#define __WINE_CONFIG_H
#define __WINE_CONFIG_H])
#ifdef WINE_CROSS_PE
#error config.h should not be used when cross-compiling
#endif])
AH_BOTTOM([#endif /* __WINE_CONFIG_H */])
AH_BOTTOM([#endif /* __WINE_CONFIG_H */])
AC_CONFIG_COMMANDS([include/stamp-h], [echo timestamp > include/stamp-h])
AC_CONFIG_COMMANDS([include/stamp-h], [echo timestamp > include/stamp-h])
...
...
dlls/winecrt0/crt_dllmain.c
View file @
cbf94a7b
...
@@ -18,7 +18,7 @@
...
@@ -18,7 +18,7 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#ifdef _
WIN32
#ifdef _
_WINE_PE_BUILD
#include <stdarg.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdio.h>
...
...
dlls/winecrt0/crt_fltused.c
View file @
cbf94a7b
...
@@ -16,7 +16,7 @@
...
@@ -16,7 +16,7 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#ifdef _
WIN32
#ifdef _
_WINE_PE_BUILD
/* referenced by MSVC to pull crt support for floating points. we don't use it. */
/* referenced by MSVC to pull crt support for floating points. we don't use it. */
int
_fltused
=
0
;
int
_fltused
=
0
;
...
...
dlls/winecrt0/debug.c
View file @
cbf94a7b
...
@@ -18,7 +18,7 @@
...
@@ -18,7 +18,7 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#ifdef _
WIN32
#ifdef _
_WINE_PE_BUILD
#include <stdio.h>
#include <stdio.h>
#include <stdarg.h>
#include <stdarg.h>
...
@@ -249,4 +249,4 @@ int __cdecl __wine_dbg_header( enum __wine_debug_class cls, struct __wine_debug_
...
@@ -249,4 +249,4 @@ int __cdecl __wine_dbg_header( enum __wine_debug_class cls, struct __wine_debug_
return
p__wine_dbg_header
(
cls
,
channel
,
function
);
return
p__wine_dbg_header
(
cls
,
channel
,
function
);
}
}
#endif
/* _
WIN32
*/
#endif
/* _
_WINE_PE_BUILD
*/
dlls/winecrt0/delay_load.c
View file @
cbf94a7b
...
@@ -25,7 +25,7 @@
...
@@ -25,7 +25,7 @@
WINBASEAPI
void
*
WINAPI
DelayLoadFailureHook
(
LPCSTR
name
,
LPCSTR
function
);
WINBASEAPI
void
*
WINAPI
DelayLoadFailureHook
(
LPCSTR
name
,
LPCSTR
function
);
#ifdef _
WIN32
#ifdef _
_WINE_PE_BUILD
extern
IMAGE_DOS_HEADER
__ImageBase
;
extern
IMAGE_DOS_HEADER
__ImageBase
;
...
@@ -39,7 +39,7 @@ FARPROC WINAPI __delayLoadHelper2( const IMAGE_DELAYLOAD_DESCRIPTOR *descr, IMAG
...
@@ -39,7 +39,7 @@ FARPROC WINAPI __delayLoadHelper2( const IMAGE_DELAYLOAD_DESCRIPTOR *descr, IMAG
return
ResolveDelayLoadedAPI
(
&
__ImageBase
,
descr
,
NULL
,
DelayLoadFailureHook
,
addr
,
0
);
return
ResolveDelayLoadedAPI
(
&
__ImageBase
,
descr
,
NULL
,
DelayLoadFailureHook
,
addr
,
0
);
}
}
#else
/* _
WIN32
*/
#else
/* _
_WINE_PE_BUILD
*/
struct
ImgDelayDescr
struct
ImgDelayDescr
{
{
...
@@ -79,4 +79,4 @@ static void free_delay_imports(void)
...
@@ -79,4 +79,4 @@ static void free_delay_imports(void)
}
}
#endif
#endif
#endif
/* _
WIN32
*/
#endif
/* _
_WINE_PE_BUILD
*/
dlls/winecrt0/unix_lib.c
View file @
cbf94a7b
...
@@ -18,7 +18,7 @@
...
@@ -18,7 +18,7 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
*/
#ifdef _
WIN32
#ifdef _
_WINE_PE_BUILD
#include <stdarg.h>
#include <stdarg.h>
...
@@ -65,4 +65,4 @@ NTSTATUS WINAPI __wine_unix_call( unixlib_handle_t handle, unsigned int code, vo
...
@@ -65,4 +65,4 @@ NTSTATUS WINAPI __wine_unix_call( unixlib_handle_t handle, unsigned int code, vo
return
p__wine_unix_call
(
handle
,
code
,
args
);
return
p__wine_unix_call
(
handle
,
code
,
args
);
}
}
#endif
/* _
WIN32
*/
#endif
/* _
_WINE_PE_BUILD
*/
include/config.h.in
View file @
cbf94a7b
...
@@ -2,9 +2,6 @@
...
@@ -2,9 +2,6 @@
#ifndef __WINE_CONFIG_H
#ifndef __WINE_CONFIG_H
#define __WINE_CONFIG_H
#define __WINE_CONFIG_H
#ifdef WINE_CROSS_PE
#error config.h should not be used when cross-compiling
#endif
/* Define to the file extension for executables. */
/* Define to the file extension for executables. */
#undef EXEEXT
#undef EXEEXT
...
...
include/wine/asm.h
View file @
cbf94a7b
...
@@ -21,13 +21,13 @@
...
@@ -21,13 +21,13 @@
#ifndef __WINE_WINE_ASM_H
#ifndef __WINE_WINE_ASM_H
#define __WINE_WINE_ASM_H
#define __WINE_WINE_ASM_H
#if defined(__APPLE__) || (defined(_
WIN32
) && defined(__i386__))
#if defined(__APPLE__) || (defined(_
_WINE_PE_BUILD
) && defined(__i386__))
# define __ASM_NAME(name) "_" name
# define __ASM_NAME(name) "_" name
#else
#else
# define __ASM_NAME(name) name
# define __ASM_NAME(name) name
#endif
#endif
#if defined(_
WIN32
) && defined(__i386__)
#if defined(_
_WINE_PE_BUILD
) && defined(__i386__)
# define __ASM_STDCALL(name,args) "_" name "@" #args
# define __ASM_STDCALL(name,args) "_" name "@" #args
# define __ASM_FASTCALL(name,args) "@" name "@" #args
# define __ASM_FASTCALL(name,args) "@" name "@" #args
#else
#else
...
@@ -55,7 +55,7 @@
...
@@ -55,7 +55,7 @@
# define __ASM_SEH(str)
# define __ASM_SEH(str)
#endif
#endif
#ifdef _
WIN32
#ifdef _
_WINE_PE_BUILD
# define __ASM_FUNC_TYPE(name) ".def " name "\n\t.scl 2\n\t.type 32\n\t.endef"
# define __ASM_FUNC_TYPE(name) ".def " name "\n\t.scl 2\n\t.type 32\n\t.endef"
#elif defined(__APPLE__)
#elif defined(__APPLE__)
# define __ASM_FUNC_TYPE(name) ""
# define __ASM_FUNC_TYPE(name) ""
...
@@ -67,7 +67,7 @@
...
@@ -67,7 +67,7 @@
# define __ASM_FUNC_TYPE(name) ".type " name ",@function"
# define __ASM_FUNC_TYPE(name) ".type " name ",@function"
#endif
#endif
#ifdef _
WIN32
#ifdef _
_WINE_PE_BUILD
# define __ASM_FUNC_SIZE(name) ""
# define __ASM_FUNC_SIZE(name) ""
#elif defined(__APPLE__)
#elif defined(__APPLE__)
# define __ASM_FUNC_SIZE(name) ""
# define __ASM_FUNC_SIZE(name) ""
...
@@ -107,7 +107,7 @@
...
@@ -107,7 +107,7 @@
__ASM_BLOCK_END
__ASM_BLOCK_END
#endif
#endif
#ifdef _
WIN32
#ifdef _
_WINE_PE_BUILD
#define __ASM_GLOBAL_IMPORT(name) __ASM_DEFINE_IMPORT(__ASM_NAME(#name))
#define __ASM_GLOBAL_IMPORT(name) __ASM_DEFINE_IMPORT(__ASM_NAME(#name))
#define __ASM_STDCALL_IMPORT(name,args) __ASM_DEFINE_IMPORT(__ASM_STDCALL(#name,args))
#define __ASM_STDCALL_IMPORT(name,args) __ASM_DEFINE_IMPORT(__ASM_STDCALL(#name,args))
#else
#else
...
@@ -117,7 +117,7 @@
...
@@ -117,7 +117,7 @@
/* fastcall support */
/* fastcall support */
#if defined(__i386__) && !defined(_
WIN32
)
#if defined(__i386__) && !defined(_
_WINE_PE_BUILD
)
# define __ASM_USE_FASTCALL_WRAPPER
# define __ASM_USE_FASTCALL_WRAPPER
# define DEFINE_FASTCALL1_WRAPPER(func) \
# define DEFINE_FASTCALL1_WRAPPER(func) \
...
@@ -176,7 +176,7 @@
...
@@ -176,7 +176,7 @@
#endif
/* __i386__ */
#endif
/* __i386__ */
#if defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__)) && !defined(_
WIN32
) && !defined(__APPLE__) && !defined(__ANDROID__)
#if defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__)) && !defined(_
_WINE_PE_BUILD
) && !defined(__APPLE__) && !defined(__ANDROID__)
#define __ASM_OBSOLETE(func) __asm__( ".symver " #func "_obsolete," #func "@WINE_1.0" )
#define __ASM_OBSOLETE(func) __asm__( ".symver " #func "_obsolete," #func "@WINE_1.0" )
#else
#else
#undef __ASM_OBSOLETE
#undef __ASM_OBSOLETE
...
...
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