LDIMPORTS is no longer needed.

This commit is contained in:
Alexandre Julliard 2003-10-10 00:52:01 +00:00
parent 7196724ad0
commit 313661d1b0
3 changed files with 21 additions and 50 deletions

View File

@ -29,7 +29,7 @@ $(MAINSPEC).c: $(MAINSPEC) $(RC_SRCS:.rc=.res) $(SYMBOLFILE) $(IMPORTLIBS) $(WIN
$(WINEBUILD) $(DEFS) $(DLLFLAGS) -o $@ --spec $(SRCDIR)/$(MAINSPEC) $(RC_SRCS:.rc=.res) $(SYMBOLFILE) $(DLLMAIN:%=--entry %) -L$(DLLDIR) $(DELAYIMPORTS:%=-d%) $(IMPORTS:%=-l%) $(WINEBUILD) $(DEFS) $(DLLFLAGS) -o $@ --spec $(SRCDIR)/$(MAINSPEC) $(RC_SRCS:.rc=.res) $(SYMBOLFILE) $(DLLMAIN:%=--entry %) -L$(DLLDIR) $(DELAYIMPORTS:%=-d%) $(IMPORTS:%=-l%)
$(MODULE).so: $(MAINSPEC).o $(ALL_OBJS) Makefile.in $(MODULE).so: $(MAINSPEC).o $(ALL_OBJS) Makefile.in
$(LDSHARED) $(LDDLLFLAGS) $(MAINSPEC).o $(ALL_OBJS) -o $@ -L$(DLLDIR) $(LDIMPORTS:%=-l%) $(ALL_LIBS) -lc $(LDSHARED) $(LDDLLFLAGS) $(MAINSPEC).o $(ALL_OBJS) -o $@ $(ALL_LIBS) -lc
$(MODULE).tmp.o: $(ALL_OBJS) Makefile.in $(MODULE).tmp.o: $(ALL_OBJS) Makefile.in
$(LDCOMBINE) $(ALL_OBJS) -o $@ $(LDCOMBINE) $(ALL_OBJS) -o $@
@ -51,7 +51,7 @@ CHECKLINK_RPATH = dlls libs/unicode libs/wine
$(WIN16_FILES:%=__checklink16__%): checklink16 $(WIN16_FILES:%=__checklink16__%): checklink16
checklink16:: $(MAINSPEC).o $(OBJS) $(MODULE).dbg.o dummy checklink16:: $(MAINSPEC).o $(OBJS) $(MODULE).dbg.o dummy
$(CC) -o checklink $(CHECKLINK_RPATH:%=-Wl,-rpath,$(TOPOBJDIR)/%) $(TOPSRCDIR)/dlls/checklink.c $(MAINSPEC).o $(OBJS) $(MODULE).dbg.o -L$(DLLDIR) $(LDIMPORTS:%=-l%) $(ALL_LIBS) && $(RM) checklink $(CC) -o checklink $(CHECKLINK_RPATH:%=-Wl,-rpath,$(TOPOBJDIR)/%) $(TOPSRCDIR)/dlls/checklink.c $(MAINSPEC).o $(OBJS) $(MODULE).dbg.o $(ALL_LIBS) && $(RM) checklink
checklink:: $(WIN16_FILES:%=__checklink16__%) checklink:: $(WIN16_FILES:%=__checklink16__%)

View File

@ -1528,19 +1528,17 @@ x11drv/x11drv.dll$(DLLEXT): x11drv
# Special targets for dlls that we need to link to # Special targets for dlls that we need to link to
LINKABLE_DLLS = ntdll.dll
libntdll.dll.$(LIBEXT): ntdll/ntdll.dll$(DLLEXT) libntdll.dll.$(LIBEXT): ntdll/ntdll.dll$(DLLEXT)
$(RM) $@ && $(LN_S) ntdll/ntdll.dll$(DLLEXT) $@ $(RM) $@ && $(LN_S) ntdll/ntdll.dll$(DLLEXT) $@
kernel kernel/__install__: libntdll.dll.$(LIBEXT) all: libntdll.dll.$(LIBEXT)
uninstall:: uninstall::
$(RM) $(LINKABLE_DLLS:%=$(libdir)/lib%.$(LIBEXT)) $(RM) $(libdir)/libntdll.dll.$(LIBEXT)
install install-lib:: $(INSTALLSUBDIRS:%=%/__install__) install install-lib:: $(INSTALLSUBDIRS:%=%/__install__)
$(RM) $(LINKABLE_DLLS:%=$(libdir)/lib%.$(LIBEXT)) cd $(libdir) && $(RM) libntdll.dll.$(LIBEXT) && \
cd $(libdir) && if [ "$(dlldir)" = "$(libdir)/wine" ]; \ if [ "$(dlldir)" = "$(libdir)/wine" ]; \
then \ then \
$(LN_S) wine/ntdll.dll$(DLLEXT) libntdll.dll.$(LIBEXT); \ $(LN_S) wine/ntdll.dll$(DLLEXT) libntdll.dll.$(LIBEXT); \
else \ else \

View File

@ -27,7 +27,6 @@ my $makefiles = `find . -name Makefile.in -print`;
my %imports = (); my %imports = ();
my %directories = (); my %directories = ();
my %altnames = (); my %altnames = ();
my %linked_dlls = ();
# list of special dlls that can be switched on or off by configure # list of special dlls that can be switched on or off by configure
my %special_dlls = my %special_dlls =
@ -76,12 +75,6 @@ foreach my $i (split(/\s/,$makefiles))
push @{$imports{$module}}, @list; push @{$imports{$module}}, @list;
next; next;
} }
if (/^LDIMPORTS\s*=\s*(.*)/)
{
my @list = map { /\./ ? $_ : $_ . ".dll"; } split(/\s/,$1);
$linked_dlls{$module} = \@list;
next;
}
} }
close MAKE; close MAKE;
push @{$imports{$module}}, "kernel32.dll" unless !defined($module) || @{$imports{$module}} || $module eq "ntdll.dll"; push @{$imports{$module}}, "kernel32.dll" unless !defined($module) || @{$imports{$module}} || $module eq "ntdll.dll";
@ -266,48 +259,28 @@ foreach my $mod (sort keys %directories)
################################################################ ################################################################
# output the linkable dlls special links # output the linkable dlls special links
my %linkable_dlls = ();
foreach my $mod (keys %imports)
{
foreach my $i (@{$linked_dlls{$mod}}) { $linkable_dlls{$i} = 1; }
}
print NEWMAKE "\n# Special targets for dlls that we need to link to\n\n";
printf NEWMAKE "LINKABLE_DLLS = %s\n\n", join( " ", keys %linkable_dlls );
foreach my $mod (keys %linkable_dlls)
{
printf NEWMAKE "lib%s.\$(LIBEXT): %s/%s\$(DLLEXT)\n", $mod, $directories{$mod}, $mod;
printf NEWMAKE "\t\$(RM) \$@ && \$(LN_S) %s/%s\$(DLLEXT) \$@\n\n", $directories{$mod}, $mod;
}
foreach my $mod (keys %imports)
{
my $deps = "";
foreach my $i (@{$linked_dlls{$mod}}) { $deps .= " lib$i.\$(LIBEXT)"; }
if ($deps) { printf NEWMAKE "%s %s/__install__:%s\n", $directories{$mod}, $directories{$mod}, $deps; }
}
print NEWMAKE <<EOF; print NEWMAKE <<EOF;
\# Special targets for dlls that we need to link to
libntdll.dll.\$(LIBEXT): ntdll/ntdll.dll\$(DLLEXT)
\$(RM) \$@ && \$(LN_S) ntdll/ntdll.dll\$(DLLEXT) \$@
all: libntdll.dll.\$(LIBEXT)
uninstall:: uninstall::
\$(RM) \$(LINKABLE_DLLS:%=\$(libdir)/lib%.\$(LIBEXT)) \$(RM) \$(libdir)/libntdll.dll.\$(LIBEXT)
install install-lib:: \$(INSTALLSUBDIRS:%=%/__install__) install install-lib:: \$(INSTALLSUBDIRS:%=%/__install__)
\$(RM) \$(LINKABLE_DLLS:%=\$(libdir)/lib%.\$(LIBEXT)) cd \$(libdir) && \$(RM) libntdll.dll.\$(LIBEXT) && \\
cd \$(libdir) && if [ "\$(dlldir)" = "\$(libdir)/wine" ]; \\ if [ "\$(dlldir)" = "\$(libdir)/wine" ]; \\
then \\ then \\
\$(LN_S) wine/ntdll.dll\$(DLLEXT) libntdll.dll.\$(LIBEXT); \\
else \\
\$(LN_S) \$(dlldir)/ntdll.dll\$(DLLEXT) libntdll.dll.\$(LIBEXT); \\
fi
EOF EOF
foreach my $mod (keys %linkable_dlls)
{
printf NEWMAKE "\t \$(LN_S) wine/%s\$(DLLEXT) lib%s.\$(LIBEXT); \\\n", $mod, $mod;
}
print NEWMAKE "\telse \\\n";
foreach my $mod (keys %linkable_dlls)
{
printf NEWMAKE "\t \$(LN_S) \$(dlldir)/%s\$(DLLEXT) lib%s.\$(LIBEXT); \\\n", $mod, $mod;
}
print NEWMAKE "\tfi\n\n";
################################################################ ################################################################
# makefile trailer # makefile trailer