diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 0b01830e23d39d6dbeb472f892f6d31adcd4e4e1..504fc5948e4f6fbe5032304355f4a4ae1f00b4c8 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -28,7 +28,6 @@ before_script:
   - cd ..
 
 # compile pyswiftsim
-  - cat swiftsim/Makefile
   - python3 setup.py install --with-swift $LHOME/swiftsim --user
 
 # compile the docs
diff --git a/setup.py b/setup.py
index 756f77eb87db98c0014f9d047240c5aaf9e995ca..b5a8d0b5c6accea2cf791fec22e84e648b675c79 100644
--- a/setup.py
+++ b/setup.py
@@ -82,7 +82,9 @@ if swift_path:
     # hdf5
     if "bin" in hdf5_root:
         hdf5_root = hdf5_root.split("bin")[0]
-    include.append(hdf5_root + "/include")
+
+    if "/usr/lib" in hdf5_root:
+        include.append("/usr/include/hdf5/serial")
 
     # grackle
     if parseCmdLine("--with-grackle", store=True):