summarylogtreecommitdiffstats
path: root/libx32-openssl.install
blob: 860d03582bca8793b3245fd40a2ca4ed2ba1e5a6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
post_install() {
    mv /usr/include/openssl/opensslconf.h /usr/include/openssl/opensslconf-64.h
    ln -s opensslconf-stub.h /usr/include/openssl/opensslconf.h
}

post_upgrade() {
    if [ ! -L /usr/include/openssl/opensslconf.h ]; then
        post_install
    elif [ ${1::-2} != ${2::-2} ]; then
        echo WARNING: libx32-openssl is upgraded before openssl,
        echo WARNING: you probably need to reinstall libx32-openssl.
    fi
}

post_remove() {
    if [ -L /usr/include/openssl/opensslconf.h ]; then
        rm /usr/include/openssl/opensslconf.h
        mv /usr/include/openssl/opensslconf-64.h /usr/include/openssl/opensslconf.h
    fi
}