diff mbox

Add test for linking against most static libraries

Message ID 6f47760b-11fd-8555-0330-e49feb04b6ac@redhat.com
State New
Headers show

Commit Message

Carlos O'Donell Oct. 28, 2016, 8:15 p.m. UTC
On 10/28/2016 02:30 PM, Carlos O'Donell wrote:
> On 10/28/2016 01:33 PM, Joseph Myers wrote:
>> On Fri, 28 Oct 2016, Carlos O'Donell wrote:
>>
>>> I'm kinda baffled by this. We don't set it in config-sysdirs.
>>>
>>> I expect you have a local patch that hid this.
>>
>> I expect he happened to have a compiler that searched a system include 
>> directory with crypt.h.
>>
>>> I'm going to commit the following immediate fix:
>>>
>>> 2016-10-28  Carlos O'Donell  <carlos@redhat.com>
>>>
>>> 	* elf/Makefile (CFALGS-tst-linkall-static): Define.
>>
>> That's not the right fix.  The right way to address such issues is a 
>> wrapper header in include/.
>  
> OK, I'll fix it that way right now.

Given that crypt.h is the only installed header in crypt/ that should
fix all such issues.

No regressions on x86.

OK?

2016-10-28  Carlos O'Donell  <carlos@redhat.com>

        * elf/Makefile (CFALGS-tst-linkall-static): Remove.
        * include/crypt.h: New file.

---

Comments

Joseph Myers Oct. 28, 2016, 8:21 p.m. UTC | #1
On Fri, 28 Oct 2016, Carlos O'Donell wrote:

> Given that crypt.h is the only installed header in crypt/ that should
> fix all such issues.
> 
> No regressions on x86.
> 
> OK?

OK.
Carlos O'Donell Oct. 29, 2016, 2:41 a.m. UTC | #2
On 10/28/2016 04:21 PM, Joseph Myers wrote:
> On Fri, 28 Oct 2016, Carlos O'Donell wrote:
> 
>> Given that crypt.h is the only installed header in crypt/ that should
>> fix all such issues.
>>
>> No regressions on x86.
>>
>> OK?
> 
> OK.
> 

Fixed.
diff mbox

Patch

diff --git a/elf/Makefile b/elf/Makefile
index 057a19f..82c7e05 100644
--- a/elf/Makefile
+++ b/elf/Makefile
@@ -1280,7 +1280,6 @@  $(objpfx)tst-ldconfig-X.out : tst-ldconfig-X.sh $(objpfx)ldconfig
 
 $(objpfx)tst-dlsym-error: $(libdl)
 
-CFLAGS-tst-linkall-static.c = -I../crypt
 $(objpfx)tst-linkall-static: \
   $(common-objpfx)math/libm.a \
   $(common-objpfx)crypt/libcrypt.a \
diff --git a/include/crypt.h b/include/crypt.h
new file mode 100644
index 0000000..544551d
--- /dev/null
+++ b/include/crypt.h
@@ -0,0 +1,3 @@ 
+#ifndef _CRYPT_H
+# include <crypt/crypt.h>
+#endif /* _CRYPT_H */